comp.lang.ada
 help / color / mirror / Atom feed
From: anon@anon.org (anon)
Subject: Re: Pragma Unreferenced in GNAT GPL 2008
Date: Sun, 06 Jul 2008 00:38:47 GMT
Date: 2008-07-06T00:38:47+00:00	[thread overview]
Message-ID: <ruUbk.97809$102.21346@bgtnsc05-news.ops.worldnet.att.net> (raw)
In-Reply-To: 6d8f0qF1c5qaU1@mid.individual.net

A quick patch is just to comment out the line. That way the file still 
maintains all original statements.

The "pragma Unreferenced ( ... ) ;" is part of the GNAT extra pragma 
extensions. 

0. So, it depends on where you downloaded the package.  Some maintainer 
   do not recognize the statement, while others do.

1. You can also, check to see if you have;
      pragma Restrictions ( "No_Implementation_Pragmas" ) ;
   in your source or configuration files.  This statement will cause an 
   compiler error, if the compiler encounters any GNAT only "pragma" 
   statement.

2. Then check the command line options.  The GNAT maintainer may have 
   created a command line options to turn on/off GNAT extensions.

In <6d8f0qF1c5qaU1@mid.individual.net>, Wilhelm Spickermann <quast.20.unbenutzbar@spamgourmet.com> writes:
>After installing GNAT GPL 2008 I get unexpected warnings on
>unreferenced variables:
>
>....
>      entry Wait (S : Event_State) when True is
>      begin
>         if S = On then
>            requeue Wait_On with abort;
>         else
>            requeue Wait_Off with abort;
>         end if;
>      end Wait;
>
>      entry Wait_On (S : Event_State) when Value = On is
>         pragma Unreferenced (S);
>      begin
>         null;
>      end Wait_On;
>....
>"pragma Unreferenced (S);" is honoured by GNAT GPL 2007 and seems
>to be ignored by GNAT GPL 2008. 
>
>Is this a compiler bug?
>
>Wilhelm Spickermann
>




  parent reply	other threads:[~2008-07-06  0:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-05  5:26 Pragma Unreferenced in GNAT GPL 2008 Wilhelm Spickermann
2008-07-05  7:57 ` Dmitry A. Kazakov
2008-07-05 12:26   ` Wilhelm Spickermann
2008-07-05 12:51 ` Simon Wright
2008-07-09  6:37   ` Wilhelm Spickermann
2008-07-06  0:38 ` anon [this message]
2008-07-09  6:29   ` Wilhelm Spickermann
2008-07-08  8:28 ` Alex R. Mosteo
2008-07-09  6:06   ` Wilhelm Spickermann
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox