Robert Dewar <[EMAIL PROTECTED]> writes: | DJ Delorie wrote: | | >I had planned on forcing the user to place these pragmas before the | >first function definition, otherwise it becomes difficult to track | >when various warnings are in force. | > | For warnings, it is definitely useful to be able to use them on a fine | grained basis in the | source. One way to get the source placement issue handled accurately | is to have the | pragma make an entry in a table of source positions, then before | issuing a warning | you check this table with a search to see if there is an active pragma | that suppresses | warnings. That's the way we do things in GNAT for pragma Warnings On|Off.
Most of the time I've seen request for the #pragma (#dogma?) stuff, it was mostly for controlling diagnostic in a limited region or program text. GCC in its current state is not prepared to handle that correctly. (That said, I still remain unconvinced. Many of the requests come partly from defects in the diagnostic logic, and partly from program organization logic.) -- Gaby