Skip to content

Commit 2ceb8e7

Browse files
committed
Add a clarification for a corner case involving generics
1 parent a826357 commit 2ceb8e7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

text/0000-unnamed-fields.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,10 @@ This syntax would also support an obvious translation of inline-declared
213213
structures with names, by moving the declaration out-of-line; a macro could
214214
easily perform such a translation.
215215

216+
Note that the intermediate type name in the declaration must resolve to a
217+
concrete type, and cannot involve a generic type parameter of the containing
218+
structure.
219+
216220
## Mental model
217221

218222
In the memory layout of a structure, the alternating uses of `struct { ... }`

0 commit comments

Comments
 (0)