Browse Source

ignore `else false` cases in check_local_vars_init to avoid problems with the side-effect handler

Simon Krajewski 11 years ago
parent
commit
0959aea7b4
1 changed files with 2 additions and 0 deletions
  1. 2 0
      filters.ml

+ 2 - 0
filters.ml

@@ -275,6 +275,8 @@ let check_local_vars_init e =
 			loop vars e2;
 			(match eo with
 			| None -> vars := vbase
+			(* ignore else false cases (they are added by the side-effect handler) *)
+			| Some {eexpr = TConst (TBool(false))} -> ()
 			| Some e ->
 				let v1 = !vars in
 				vars := vbase;