Frama-C-discuss mailing list archives
This page gathers the archives of the old Frama-C-discuss archives, that was hosted by Inria's gforge before its demise at the end of 2020. To search for mails newer than September 2020, please visit the page of the new mailing list on Renater.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Frama-c-discuss] WP - Verifiable annotations with some types but not others
- Subject: [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: virgile.prevosto at m4x.org (Virgile Prevosto)
- Date: Fri, 6 Jul 2012 13:43:14 +0200
- In-reply-to: <1CF4D9E8-5E16-430B-AF5A-72F1ECE42E80@enseeiht.fr>
- References: <1341236500.2183.49.camel@iti27.informatik.htw-dresden.de> <47C0712F-E281-48EB-991E-263D6EADC271@enseeiht.fr> <1341564914.2095.2.camel@iti27.informatik.htw-dresden.de> <32B125A8-65E4-4455-B854-6CAE75E29A38@enseeiht.fr> <223E4B1A-AD1D-4314-B139-E679A0BC2BA1@first.fraunhofer.de> <EBAD3BAB-9682-4876-9636-9D4518495C95@enseeiht.fr> <1CF4D9E8-5E16-430B-AF5A-72F1ECE42E80@enseeiht.fr>
Hello, 2012/7/6 Arnaud Dieumegard <arnaud.dieumegard at enseeiht.fr>: > Sorry about that but I did a mistake on my last message. > The correct clause was: > > requires \forall unsigned char n; 0 <= n < 2 ==> \valid_range(&b.val[n],0,1); > or > requires \forall unsigned char n; 0 <= n < 2 ==> \valid(&b.val[n]+(0..1)); > > This still does the trick but I can't prove it. > First, just a remark: \valid_range is deprecated (use \valid and .. as you did in the latter version of your requires). More importantly, you shouldn't need this requirement: your argument is a struct which contains an array, so b.val is always a valid block of 4 doubles. In fact all annotations are proved with Nitrogen and alt-ergo. In addition, you cannot prove a requires clause directly: it leads to a proof obligation on the callers of the function (to ensure that they meet the requirements set up by the function). Since there is no caller of init in your code, there's nothing to be proved for the requires. Best regards, -- E tutto per oggi, a la prossima volta Virgile
- Follow-Ups:
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: arnaud.dieumegard at enseeiht.fr (Arnaud Dieumegard)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- References:
- [Frama-c-discuss] Predicates fully supported in WP?
- From: hollas at informatik.htw-dresden.de (Boris Hollas)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: arnaud.dieumegard at enseeiht.fr (Arnaud Dieumegard)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: hollas at informatik.htw-dresden.de (Boris Hollas)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: arnaud.dieumegard at enseeiht.fr (Arnaud Dieumegard)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: jens.gerlach at first.fraunhofer.de (Jens Gerlach)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: arnaud.dieumegard at enseeiht.fr (Arnaud Dieumegard)
- [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- From: arnaud.dieumegard at enseeiht.fr (Arnaud Dieumegard)
- [Frama-c-discuss] Predicates fully supported in WP?
- Prev by Date: [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- Next by Date: [Frama-c-discuss] Aliasing
- Previous by thread: [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- Next by thread: [Frama-c-discuss] WP - Verifiable annotations with some types but not others
- Index(es):