summaryrefslogtreecommitdiff
path: root/cparser/StructReturn.ml
diff options
context:
space:
mode:
Diffstat (limited to 'cparser/StructReturn.ml')
-rw-r--r--cparser/StructReturn.ml4
1 files changed, 3 insertions, 1 deletions
diff --git a/cparser/StructReturn.ml b/cparser/StructReturn.ml
index e13b09d..228cc53 100644
--- a/cparser/StructReturn.ml
+++ b/cparser/StructReturn.ml
@@ -113,6 +113,8 @@ let rec transf_expr env ctx e =
etyp = newty}
| ECast(ty, e1) ->
{edesc = ECast(transf_type env ty, transf_expr env Val e1); etyp = newty}
+ | ECompound(ty, ie) ->
+ {edesc = ECompound(transf_type env ty, transf_init env ie); etyp = newty}
| ECall(fn, args) ->
transf_call env ctx None fn args e.etyp
@@ -176,7 +178,7 @@ and transf_call env ctx opt_lhs fn args ty =
(* Initializers *)
-let rec transf_init env = function
+and transf_init env = function
| Init_single e ->
Init_single (transf_expr env Val e)
| Init_array il ->