diff options
author | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2012-06-28 07:59:03 +0000 |
---|---|---|
committer | xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e> | 2012-06-28 07:59:03 +0000 |
commit | 5312915c1b29929f82e1f8de80609a277584913f (patch) | |
tree | 0f7ee475743f0eb05d352148a9e1f0b861ee9d34 /backend/CMparser.mly | |
parent | f3250c32ff42ae18fd03a5311c1f0caec3415aba (diff) | |
download | compcert-5312915c1b29929f82e1f8de80609a277584913f.tar.gz compcert-5312915c1b29929f82e1f8de80609a277584913f.zip |
Use Flocq for floats
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@1939 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'backend/CMparser.mly')
-rw-r--r-- | backend/CMparser.mly | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/backend/CMparser.mly b/backend/CMparser.mly index 37b61444..4a91a010 100644 --- a/backend/CMparser.mly +++ b/backend/CMparser.mly @@ -368,10 +368,10 @@ init_data: | INT32 INTLIT { Init_int32 (coqint_of_camlint $2) } | INT INTLIT { Init_int32 (coqint_of_camlint $2) } | INTLIT { Init_int32 (coqint_of_camlint $1) } - | FLOAT32 FLOATLIT { Init_float32 ($2) } - | FLOAT64 FLOATLIT { Init_float64 ($2) } - | FLOAT FLOATLIT { Init_float64 ($2) } - | FLOATLIT { Init_float64 ($1) } + | FLOAT32 FLOATLIT { Init_float32 (coqfloat_of_camlfloat $2) } + | FLOAT64 FLOATLIT { Init_float64 (coqfloat_of_camlfloat $2) } + | FLOAT FLOATLIT { Init_float64 (coqfloat_of_camlfloat $2) } + | FLOATLIT { Init_float64 (coqfloat_of_camlfloat $1) } | LBRACKET INTLIT RBRACKET { Init_space (z_of_camlint $2) } | INTLIT LPAREN STRINGLIT RPAREN { Init_addrof ($3, coqint_of_camlint $1) } ; @@ -491,7 +491,7 @@ expr: LPAREN expr RPAREN { $2 } | IDENT { Rvar $1 } | INTLIT { intconst $1 } - | FLOATLIT { Rconst(Ofloatconst $1) } + | FLOATLIT { Rconst(Ofloatconst (coqfloat_of_camlfloat $1)) } | STRINGLIT { Rconst(Oaddrsymbol($1, Int.zero)) } | AMPERSAND INTLIT { Rconst(Oaddrstack(coqint_of_camlint $2)) } | MINUS expr %prec p_uminus { Runop(Onegint, $2) } |