diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2022-05-20 07:10:51 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2022-05-20 07:10:51 -0700 |
commit | bdbcc050c7c2c50d33da2bc14ba861f74ec111f0 (patch) | |
tree | acfd6c60c99c1211439986f18c5b445b708c045d /txr.1 | |
parent | 92b915b8623fbc7cad56d46293d1416ab8f0a44a (diff) | |
download | txr-bdbcc050c7c2c50d33da2bc14ba861f74ec111f0.tar.gz txr-bdbcc050c7c2c50d33da2bc14ba861f74ec111f0.tar.bz2 txr-bdbcc050c7c2c50d33da2bc14ba861f74ec111f0.zip |
doc: undimensioned arrays may be flexible array members.
* txr.1: The documentation for array and zarray wrongly states
that if the dimension is omitted, the type may not be used
as a structure member. In fact, it may be used as the last
member of a flexible structure.
Diffstat (limited to 'txr.1')
-rw-r--r-- | txr.1 | 13 |
1 files changed, 9 insertions, 4 deletions
@@ -80304,8 +80304,11 @@ element, it denotes a variable length array. It corresponds to the concept of an incomplete array in the C language, except that no implicit array-to-pointer conversion concept is implemented in the FFI type system. This type may not -be used as an array element or structure member. It also may not +be used as an array element or structure member, other than as the +last structure member. It also may not be passed or returned by value, only by pointer. +If the last member of a structure has this type, then it is a flexible +array member; see the Flexible Structures section below. Since the type has unknown length, it has a trivial get operation which returns .codn nil . @@ -80419,9 +80422,11 @@ syntax which omits the .meta dim argument specifies a null-terminated variant of the variable-length array. Like that type, it corresponds to the concept of an incomplete -array in the C language. It may not be used as an array element -or structure member, and cannot be passed as an argument or returned -as a value. +array in the C language. It may not be used as an array element, +and may not be used as a structure member other than the last member. +It cannot be passed as an argument or returned as a value. +If the last member of a structure has this type, then it is a flexible +array member; see the Flexible Structures section below. Unlike the ordinary variable-length .codn array , |