https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91285

--- Comment #4 from joseph at codesourcery dot com <joseph at codesourcery dot 
com> ---
Note that all the standard C pragmas are even more restricted than GCC's 
statement-like pragmas - the standard pragmas (which aren't implemented in 
GCC) are defined by the C standard to be allowed only "either outside 
external declarations or preceding all explicit declarations and 
statements inside a compound statement".

The wider the range of contexts in which a pragma is permitted, the harder 
it is to define its semantics.  For diagnostic pragmas, note that some 
diagnostics are associated with a *range* of locations within an 
expression, leading to obvious questions about the semantics if diagnostic 
pragma state varies within that range.  (Though that could also arise when 
statement-like pragmas are used within the existing statement expression 
extension.)

Reply via email to