2
0
Simon Krajewski 12 жил өмнө
parent
commit
c1d5bb43c5
2 өөрчлөгдсөн 2 нэмэгдсэн , 2 устгасан
  1. 1 1
      common.ml
  2. 1 1
      typeload.ml

+ 1 - 1
common.ml

@@ -484,7 +484,7 @@ let get_config com =
 			pf_pad_nulls = true;
 			pf_add_final_return = false;
 			pf_overload = false;
-			pf_pattern_matching = true;
+			pf_pattern_matching = false;
 		}
 	| Flash when defined Define.As3 ->
 		{

+ 1 - 1
typeload.ml

@@ -881,7 +881,7 @@ let rec return_flow ctx e =
 	| TSwitch (v,cases,Some e) ->
 		List.iter (fun (_,e) -> return_flow e) cases;
 		return_flow e
-	| TSwitch (e,cases,None) when (match follow e.etype with TEnum _ -> true | _ -> false) ->
+	| TSwitch ({eexpr = TMeta((Meta.Exhaustive,_,_),_)},cases,None) ->
 		List.iter (fun (_,e) -> return_flow e) cases;
 	| TPatMatch dt ->
 		let rec loop d = match d with