comp.lang.ada
 help / color / mirror / Atom feed
From: sjw <simon.j.wright@mac.com>
Subject: Re: Minor SPARK problem concerning 'redundant' with clauses.
Date: Wed, 10 Jun 2009 13:11:56 -0700 (PDT)
Date: 2009-06-10T13:11:56-07:00	[thread overview]
Message-ID: <b67cbf34-adb3-4556-90e5-0512457ce0d9@z9g2000yqi.googlegroups.com> (raw)
In-Reply-To: d159ba39-a898-42fb-bb2b-a3b5142893d3@h28g2000yqd.googlegroups.com

On Jun 10, 8:31 pm, xorquew...@googlemail.com wrote:
> I have a package P1 that uses the value of a constant defined in P2.
>
> SPARK requires me to --# inherit P2 and the only place the annotation
> can appear is in the spec of P1. The Ada compiler, however, sees that
> the constant is only referenced in the body and complains loudly that
> the 'with' clause is redundant and might be moved into the body of P2.
>
> Is there a sensible solution to stop the two systems treading on each
> other like this? In most cases, I can hack around the problem with a
> spurious 'use type' clause (as much as I dislike it).

You could explore the options available with -gnatw, perhaps? None
look appropriate at first glance, but ..



  reply	other threads:[~2009-06-10 20:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-10 19:31 Minor SPARK problem concerning 'redundant' with clauses xorquewasp
2009-06-10 20:11 ` sjw [this message]
2009-06-10 20:55 ` britt.snodgrass
2009-06-11  8:45   ` xorque
2009-06-11  8:52   ` Robin Messer
replies disabled

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