Skip to content

Commit

Permalink
[Flang] Update Extensions.md for supported BIND(C) LOGICAL kind. (#88159
Browse files Browse the repository at this point in the history
)

Flang also supports non-scalar logical dummy argument with a different
KIND from C_BOOL to a bind(c) routine as well as a component in a
bind(c) derived type. Update the document.

```
subroutine sub(arg)
logical(4) :: arg(4)
end
```

```
type dt
logical(4) :: comp
end type
end
```
  • Loading branch information
DanielCChen committed Apr 9, 2024
1 parent 7599d47 commit e248f0d
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions flang/docs/Extensions.md
Original file line number Diff line number Diff line change
Expand Up @@ -308,9 +308,10 @@ end
enforce it and the constraint is not necessary for a correct
implementation.
* A label may follow a semicolon in fixed form source.
* A scalar logical dummy argument to a `BIND(C)` procedure does
not have to have `KIND=C_BOOL` since it can be converted to/from
`_Bool` without loss of information.
* A logical dummy argument to a `BIND(C)` procedure, or a logical
component to a `BIND(C)` derived type does not have to have
`KIND=C_BOOL` since it can be converted to/from `_Bool` without
loss of information.
* The character length of the `SOURCE=` or `MOLD=` in `ALLOCATE`
may be distinct from the constant character length, if any,
of an allocated object.
Expand Down

0 comments on commit e248f0d

Please sign in to comment.