From: Ben Hocking <benjaminhocking@gmail.com>
Subject: Using .rlu files in SPARK Ada
Date: Mon, 13 Aug 2012 07:00:59 -0700 (PDT)
Date: 2012-08-13T07:00:59-07:00 [thread overview]
Message-ID: <bbdd7647-8a13-41e1-9db7-b6842c22db0e@googlegroups.com> (raw)
I'm trying to satisfy all of the Verification Conditions that SPARK Ada generates in some code of mine.
I've been unable to satisfy the following check statement:
a2 := x3 - x1;
b := y3 - y1;
--# check b < a2 -> (b rem a2 = b);
It generates the following VC:
y3 - y1 < x3 - x1 -> y3 - y1 - (y3 - y1) div (x3 - x1) * (x3 - x1) = y3 - y1
In my .rlu file (which I know is being read because other rules are being applied, and I see it mentioned in my .slg file), I have:
small_rem: y3 - y1 - (y3 - y1) div (x3 - x1) * (x3 - x1) = (y3 - y1) may_be_deduced_from [y3 - y1 < x3 - x1].
(Note that I originally had:
small_rem: x rem y = x may_be_deduced_from [x < y].
However, in an effort to rule out any possible source of confusion, I expanded it to exactly what I was seeing in the .siv file.)
Am I doing something incorrectly, or is there some limitation of SPARK here?
next reply other threads:[~2012-08-13 14:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-13 14:00 Ben Hocking [this message]
2012-08-13 15:46 ` Using .rlu files in SPARK Ada Phil Thornley
2012-08-15 11:50 ` Ben Hocking
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox