Changeset 751 for src/common/Values.ma


Ignore:
Timestamp:
Apr 13, 2011, 6:52:10 PM (10 years ago)
Author:
campbell
Message:

Initial version of the Cminor syntax and semantics.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/common/Values.ma

    r747 r751  
    265265  | bool_of_val_null:
    266266      ∀r. bool_of_val (Vnull r) true.
     267
     268definition eval_bool_of_val : val → res bool ≝
     269λv. match v with
     270[ Vint i ⇒ OK ? (notb (eq i zero))
     271| Vnull _ ⇒ OK ? false
     272| Vptr _ _ _ _ ⇒ OK ? true
     273| _ ⇒ Error ?
     274].
    267275
    268276definition neg : val → val ≝ λv.
Note: See TracChangeset for help on using the changeset viewer.