[kernel] Parsing share/libc/__fc_builtin_for_normalization.i (no preprocessing)
[kernel] Parsing tests/spec/model.i (no preprocessing)
tests/spec/model.i:9:[kernel] warning: Cannot add model field x for type struct S: it already exists. Ignoring global annotation
tests/spec/model.i:13:[kernel] warning: Cannot add model field z for type T: it already exists. Ignoring global annotation
tests/spec/model.i:14:[kernel] warning: Cannot add model field x for type T: it already exists. Ignoring global annotation
Model fields for type T:
z, t, 
After adding field
Model fields for type T:
z, test_field, t, 
After removing field
Model fields for type T:
z, t, 
/* Generated by Frama-C */
struct S {
   int x ;
   int y ;
};
typedef struct S T;
/*@
model struct S { ℤ z }; */
/*@
model T { ℤ t }; */
/*@ type invariant t_invariant(T t) = t.t ≡ t.z*2;
 */
/*@ ensures (*\old(s)).z ≡ \result;
    assigns *s; */
extern int f(struct S *s);

/*@ type invariant sum(struct S s) = s.z ≡ s.x+s.y;
 */
void main(void)
{
  struct S s;
  T t;
  int a;
  s.x = 0;
  s.y = 0;
  t.x = 1;
  t.y = 2;
  /*@ assert t.t ≡ 6 ∧ t.z ≡ 3; */ ;
  a = f(& s);
  if (a) {
    if (! s.x) 
      /*@ assert s.y ≢ 0; */ ;
    else goto _LAND;
  }
  else 
    _LAND: if (s.x == 1) ;
  /*@ assert s.z ≢ 0; */ ;
  return;
}

/*@
model double { ℝ exact }; */
/*@
model double { ℝ round };
*/
/*@ ensures \result ≡ (double)(\old(x)+\old(y));
    ensures \result.exact ≡ \old(x.exact)+\old(y.exact);
    ensures \result ≡ \result.exact+\result.round;
 */
extern double add(double x, double y);

double foo(double x)
{
  double tmp;
  tmp = add(x,x);
  return tmp;
}


