From 3698105ccfa2729eaa44978d0c9bf22b72d2f3af Mon Sep 17 00:00:00 2001 From: Adrien Guatto Date: Thu, 8 Jul 2010 12:49:14 +0200 Subject: [PATCH] C back-end: yet another fix for array literals --- compiler/minils/sequential/c.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/minils/sequential/c.ml b/compiler/minils/sequential/c.ml index 5b0a421..0468edc 100644 --- a/compiler/minils/sequential/c.ml +++ b/compiler/minils/sequential/c.ml @@ -217,7 +217,7 @@ and pp_cexpr fmt ce = match ce with | Cstructlit (s, el) -> fprintf fmt "(%s){@[%a@]}" s (pp_list1 pp_cexpr ",") el | Carraylit el -> - fprintf fmt "((int *){@[%a@]})" (pp_list1 pp_cexpr ",") el (* WRONG *) + fprintf fmt "((int []){@[%a@]})" (pp_list1 pp_cexpr ",") el (* WRONG *) and pp_clhs fmt lhs = match lhs with | Cvar s -> fprintf fmt "%s" s | Cderef lhs' -> fprintf fmt "*%a" pp_clhs lhs'