summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2013-01-07 10:30:16 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2013-01-07 10:30:16 +0000
commit8e5f68c1a6d921a46bb817fe0a82fca1c3494dde (patch)
tree2cec8321fd218a49c6cc8ec70b9f9d37634ef43f /common
parent578cc2a54897e0c89425a56df7a173bebeee2382 (diff)
Update Cminor parser and printer so that the parser can parse the whole Cminor language and can reparse the output of the printer.
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@2090 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'common')
-rw-r--r--common/PrintAST.ml8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/PrintAST.ml b/common/PrintAST.ml
index 6a66c30..53741d5 100644
--- a/common/PrintAST.ml
+++ b/common/PrintAST.ml
@@ -29,15 +29,15 @@ let name_of_chunk = function
| Mfloat64al32 -> "float64al32"
let name_of_external = function
- | EF_external(name, sg) -> extern_atom name
- | EF_builtin(name, sg) -> extern_atom name
+ | EF_external(name, sg) -> sprintf "extern %S" (extern_atom name)
+ | EF_builtin(name, sg) -> sprintf "builtin %S" (extern_atom name)
| EF_vload chunk -> sprintf "volatile load %s" (name_of_chunk chunk)
| EF_vstore chunk -> sprintf "volatile store %s" (name_of_chunk chunk)
| EF_vload_global(chunk, id, ofs) ->
- sprintf "volatile load %s global %s %ld"
+ sprintf "volatile load %s global %S %ld"
(name_of_chunk chunk) (extern_atom id) (camlint_of_coqint ofs)
| EF_vstore_global(chunk, id, ofs) ->
- sprintf "volatile store %s global %s %ld"
+ sprintf "volatile store %s global %S %ld"
(name_of_chunk chunk) (extern_atom id) (camlint_of_coqint ofs)
| EF_malloc -> "malloc"
| EF_free -> "free"