Coccinelle release 1.0.0c7.
[bpt/coccinelle.git] / parsing_cocci / unparse_ast0.ml
index 105476b..4e108b5 100644 (file)
@@ -218,6 +218,9 @@ let rec expression e =
          mcode print_string_box lp; typeC ty; close_box();
          mcode print_string rp
       | Ast0.TypeExp(ty) -> typeC ty
+      | Ast0.Constructor(lp,ty,rp,init) ->
+         mcode print_string_box lp; typeC ty; close_box();
+         mcode print_string rp; initialiser init
       | Ast0.MetaErr(name,_,_) -> mcode print_meta name
       | Ast0.MetaExpr(name,_,ty,_,pure) ->
          mcode print_meta name; print_types ty(*;
@@ -631,8 +634,8 @@ let top_level t =
        Ast0.FILEINFO(old_file,new_file) ->
          print_string "--- "; mcode print_string old_file; force_newline();
          print_string "+++ "; mcode print_string new_file
-      | Ast0.DECL(stmt) -> statement "" stmt
-      | Ast0.CODE(stmt_dots) ->
+      | Ast0.NONDECL(stmt) -> statement "" stmt
+      | Ast0.CODE(stmt_dots) | Ast0.TOPCODE(stmt_dots) ->
          dots force_newline (statement "") stmt_dots
       | Ast0.ERRORWORDS(exps) ->
          print_string "error words = [";