summaryrefslogtreecommitdiff
path: root/backend/PrintLTLin.ml
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2012-11-12 13:42:22 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2012-11-12 13:42:22 +0000
commitce4951549999f403446415c135ad1403a16a15c3 (patch)
treecac9bbb2fea29fce331916b277c38ed8fe29e471 /backend/PrintLTLin.ml
parentdcb9f48f51cec5e864565862a700c27df2a1a7e6 (diff)
Globalenvs: allocate one-byte block with permissions Nonempty for each
function definition, so that comparisons between function pointers are correctly defined. AST, Globalenvs, and many other files: represent programs as a list of (function or variable) definitions instead of two lists, one for functions and the other for variables. git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@2067 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'backend/PrintLTLin.ml')
-rw-r--r--backend/PrintLTLin.ml10
1 files changed, 5 insertions, 5 deletions
diff --git a/backend/PrintLTLin.ml b/backend/PrintLTLin.ml
index bb360eb..4dc311c 100644
--- a/backend/PrintLTLin.ml
+++ b/backend/PrintLTLin.ml
@@ -95,13 +95,13 @@ let print_function pp id f =
List.iter (print_instruction pp) f.fn_code;
fprintf pp "@;<0 -2>}@]@."
-let print_fundef pp (id, fd) =
- match fd with
- | Internal f -> print_function pp id f
- | External _ -> ()
+let print_globdef pp (id, gd) =
+ match gd with
+ | Gfun(Internal f) -> print_function pp id f
+ | _ -> ()
let print_program pp prog =
- List.iter (print_fundef pp) prog.prog_funct
+ List.iter (print_globdef pp) prog.prog_defs
let destination : string option ref = ref None