On Thu, 10 Nov 2022, Joseph Myers wrote: > On Thu, 10 Nov 2022, Alejandro Colomar via Gcc wrote: > > > I've shown the three kinds of prototypes that have been changed: > > > > - Normal VLA; nothing fancy except for the '.'. > > - Complex size expressions. > > - 'void *' VLAs (assuming GNU conventions: sizeof(void *)==1). > > That doesn't cover any of the tricky issues with such proposals, such as > the choice of which entity is referred to by the parameter name when there > are multiple nested parameter lists that use the same parameter name, or > when the identifier is visible from an outer scope (including in > particular the case where it's declared as a typedef name in an outer > scope). In fact I can't tell from these examples whether you mean for a '.' token after '[' to have special semantics, or whether you mean to have a special '. identifier' form of expression valid in certain context (each of which introduces its own complications; for the former, typedef names from outer scopes are problematic; for the latter, it's designated initializers where you get complications, for example). Designing new syntax that doesn't cause ambiguity is generally tricky, and this sort of language extension is the kind of thing where you'd expect to so through at least five iterations of a WG14 paper before you have something like a sound specification. -- Joseph S. Myers joseph@xxxxxxxxxxxxxxxx