This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: 3.2 PATCH: Fully support parallel gnat1/gnatbind builds
- From: Joe Buck <Joe dot Buck at synopsys dot com>
- To: dewar at gnat dot com (Robert Dewar)
- Cc: dewar at gnat dot com, kenner at vlsi1 dot ultra dot nyu dot edu,ro at TechFak dot Uni-Bielefeld dot DE, zack at codesourcery dot com, fw at deneb dot enyo dot de,gcc-patches at gcc dot gnu dot org, gcc at gcc dot gnu dot org
- Date: Fri, 24 May 2002 10:37:59 -0700 (PDT)
- Subject: Re: 3.2 PATCH: Fully support parallel gnat1/gnatbind builds
Robert Dewar writes:
> A good example is unreferenced parameters. We require building with
> warnings enabled and also the flag that makes warnings fatal. This means
> that an unreferenced formal parameter is a fatal error. For compatibility
> with old versions of GNAT, we use pragma Warnings (Off), but that's not
> nearly so nice as using pragma Unreferenced (entity-name) which much more
> clearly expresses the requirement, and avoids masking any other warnings.
> We could not use pragma Unreferenced in 3.1, because it was not implemented
> in earlier versions of GNAT, but we should at least consider this cleanup
> for 3.2. We most certainly will do this cleanup internally at ACT for the
> next version of GNAT Pro, since keeping the sources in maximally maintainable
> shape is certainly an internal requirement we have at ACT.
The usual way to handle such things is with configure-time tests: does
the existing Ada compiler support pragma Unreferenced? If so, use
it, otherwise use pragma Warnings. That way, developers, who will be
using the latest tools, will get warnings treated as fatals, but users,
who might have skipped one upgrade generation, will still be able to
build the compiler.