فهرست منبع

Fix warnings (#11170)

* remove / ignore warnings

* get rid of "method overridden" warnings
Rudy Ges 2 سال پیش
والد
کامیت
e8e29c4732
100فایلهای تغییر یافته به همراه193 افزوده شده و 230 حذف شده
  1. 3 3
      libs/extc/extc.ml
  2. 7 1
      libs/extlib-leftovers/dune
  3. 5 5
      libs/extlib-leftovers/multiArray.ml
  4. 7 1
      libs/ilib/dune
  5. 7 1
      libs/javalib/dune
  6. 7 1
      libs/neko/dune
  7. 7 1
      libs/swflib/dune
  8. 7 1
      libs/ttflib/dune
  9. 7 1
      libs/ziplib/dune
  10. 7 1
      plugins/example/dune
  11. 7 1
      src-prebuild/dune
  12. 0 1
      src/codegen/codegen.ml
  13. 1 1
      src/codegen/dotnet.ml
  14. 2 3
      src/codegen/gencommon/castDetect.ml
  15. 1 2
      src/codegen/gencommon/closuresToClass.ml
  16. 0 1
      src/codegen/gencommon/dynamicOperators.ml
  17. 0 1
      src/codegen/gencommon/enumToClass.ml
  18. 0 1
      src/codegen/gencommon/enumToClass2.ml
  19. 1 2
      src/codegen/gencommon/fixOverrides.ml
  20. 0 1
      src/codegen/gencommon/gencommon.ml
  21. 0 1
      src/codegen/gencommon/initFunction.ml
  22. 1 2
      src/codegen/gencommon/overloadingConstructor.ml
  23. 3 4
      src/codegen/gencommon/realTypeParams.ml
  24. 1 2
      src/codegen/gencommon/reflectionCFs.ml
  25. 0 1
      src/codegen/gencommon/switchToIf.ml
  26. 0 1
      src/codegen/gencommon/unreachableCodeEliminationSynf.ml
  27. 2 2
      src/codegen/javaModern.ml
  28. 2 2
      src/codegen/swfLoader.ml
  29. 0 4
      src/compiler/displayOutput.ml
  30. 1 4
      src/compiler/server.ml
  31. 0 1
      src/compiler/serverMessage.ml
  32. 0 1
      src/context/abstractCast.ml
  33. 0 2
      src/context/common.ml
  34. 0 4
      src/context/display/diagnostics.ml
  35. 0 1
      src/context/display/diagnosticsPrinter.ml
  36. 1 4
      src/context/display/display.ml
  37. 1 2
      src/context/display/displayEmitter.ml
  38. 0 1
      src/context/display/displayJson.ml
  39. 1 3
      src/context/display/displayTexpr.ml
  40. 0 1
      src/context/display/displayToplevel.ml
  41. 1 3
      src/context/display/findReferences.ml
  42. 1 4
      src/context/display/statistics.ml
  43. 1 2
      src/context/memory.ml
  44. 1 2
      src/context/nativeLibraries.ml
  45. 1 3
      src/context/sourcemaps.ml
  46. 1 2
      src/context/typecore.ml
  47. 0 2
      src/core/abstract.ml
  48. 3 5
      src/core/ast.ml
  49. 1 3
      src/core/displayTypes.ml
  50. 1 1
      src/core/error.ml
  51. 1 3
      src/core/inheritDoc.ml
  52. 2 2
      src/core/tUnification.ml
  53. 2 2
      src/core/warning.ml
  54. 10 2
      src/dune
  55. 0 1
      src/filters/defaultArguments.ml
  56. 2 4
      src/filters/exceptions.ml
  57. 1 1
      src/filters/filters.ml
  58. 1 1
      src/generators/gencpp.ml
  59. 4 5
      src/generators/gencs.ml
  60. 3 4
      src/generators/genhl.ml
  61. 2 5
      src/generators/genjava.ml
  62. 9 9
      src/generators/genphp7.ml
  63. 1 1
      src/generators/genshared.ml
  64. 0 1
      src/generators/genswf.ml
  65. 1 1
      src/generators/genswf9.ml
  66. 8 9
      src/generators/jvm/jvmBuilder.ml
  67. 5 5
      src/generators/jvm/jvmMethod.ml
  68. 3 5
      src/generators/jvm/jvmWriter.ml
  69. 1 3
      src/macro/eval/EvalStackTrace.ml
  70. 0 1
      src/macro/eval/evalArray.ml
  71. 1 2
      src/macro/eval/evalContext.ml
  72. 1 9
      src/macro/eval/evalDebug.ml
  73. 1 3
      src/macro/eval/evalDebugSocket.ml
  74. 2 2
      src/macro/eval/evalDecode.ml
  75. 4 4
      src/macro/eval/evalEmitter.ml
  76. 2 4
      src/macro/eval/evalMain.ml
  77. 0 1
      src/macro/eval/evalMisc.ml
  78. 0 1
      src/macro/eval/evalPrinting.ml
  79. 1 3
      src/macro/eval/evalStdLib.ml
  80. 1 2
      src/macro/eval/evalValue.ml
  81. 3 3
      src/optimization/analyzer.ml
  82. 1 1
      src/optimization/analyzerTexpr.ml
  83. 1 1
      src/optimization/analyzerTexprTransformer.ml
  84. 1 1
      src/optimization/dce.ml
  85. 1 1
      src/optimization/optimizerTexpr.ml
  86. 2 2
      src/syntax/grammar.mly
  87. 0 1
      src/syntax/parser.ml
  88. 2 2
      src/typing/callUnification.ml
  89. 0 1
      src/typing/finalization.ml
  90. 1 1
      src/typing/generic.ml
  91. 1 1
      src/typing/macroContext.ml
  92. 4 4
      src/typing/matcher/compile.ml
  93. 1 2
      src/typing/matcher/pattern.ml
  94. 1 2
      src/typing/matcher/texprConverter.ml
  95. 2 2
      src/typing/matcher/useless.ml
  96. 2 2
      src/typing/nullSafety.ml
  97. 1 2
      src/typing/typeload.ml
  98. 0 1
      src/typing/typeloadCheck.ml
  99. 0 2
      src/typing/typeloadFunction.ml
  100. 0 2
      src/typing/typeloadModule.ml

+ 3 - 3
libs/extc/extc.ml

@@ -110,10 +110,10 @@ let input_zip ?(bufsize=65536) ch =
 	let buf = ref "" in
 	let buf = ref "" in
 	let p = ref 0 in
 	let p = ref 0 in
 	let z = zlib_inflate_init() in
 	let z = zlib_inflate_init() in
-	let rec fill_buffer() =
+	let fill_buffer() =
 		let rec loop pos len =
 		let rec loop pos len =
 			if len > 0 || pos = 0 then begin
 			if len > 0 || pos = 0 then begin
-				let r = zlib_inflate z (Bytes.unsafe_to_string tmp_in) pos len tmp_out 0 bufsize (if pos = 0 && len = 0 then Z_FINISH else Z_SYNC_FLUSH) in
+				let r = zlib_inflate z ~src:(Bytes.unsafe_to_string tmp_in) ~spos:pos ~slen:len ~dst:tmp_out ~dpos:0 ~dlen:bufsize (if pos = 0 && len = 0 then Z_FINISH else Z_SYNC_FLUSH) in
 				Buffer.add_subbytes tmp_buf tmp_out 0 r.z_wrote;
 				Buffer.add_subbytes tmp_buf tmp_out 0 r.z_wrote;
 				loop (pos + r.z_read) (len - r.z_read);
 				loop (pos + r.z_read) (len - r.z_read);
 			end
 			end
@@ -155,7 +155,7 @@ let output_zip ?(bufsize=65536) ?(level=9) ch =
 	let tmp_out = Bytes.create bufsize in
 	let tmp_out = Bytes.create bufsize in
 	let p = ref 0 in
 	let p = ref 0 in
 	let rec flush finish =
 	let rec flush finish =
-		let r = zlib_deflate z (Bytes.unsafe_to_string out) 0 !p tmp_out 0 bufsize (if finish then Z_FINISH else Z_SYNC_FLUSH) in
+		let r = zlib_deflate z ~src:(Bytes.unsafe_to_string out) ~spos:0 ~slen:!p ~dst:tmp_out ~dpos:0 ~dlen:bufsize (if finish then Z_FINISH else Z_SYNC_FLUSH) in
 		ignore(IO.really_output ch tmp_out 0 r.z_wrote);
 		ignore(IO.really_output ch tmp_out 0 r.z_wrote);
 		let remain = !p - r.z_read in
 		let remain = !p - r.z_read in
 		Bytes.blit out r.z_read out 0 remain;
 		Bytes.blit out r.z_read out 0 remain;

+ 7 - 1
libs/extlib-leftovers/dune

@@ -1,7 +1,13 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -27 -w -32))
+	)
+)
+
 (library
 (library
 	(name extlib_leftovers)
 	(name extlib_leftovers)
 	(libraries extlib)
 	(libraries extlib)
 	; (wrapped false)
 	; (wrapped false)
-)
+)

+ 5 - 5
libs/extlib-leftovers/multiArray.ml

@@ -77,7 +77,7 @@ let init len f =
 			len = len;
 			len = len;
 			arr = imake 0 0;
 			arr = imake 0 0;
 			darr = Some arr;
 			darr = Some arr;
-		}		
+		}
 	end
 	end
 
 
 let make len e =
 let make len e =
@@ -124,7 +124,7 @@ let set d idx v =
 	| None -> iset (iget d.arr (idx lsr nbits)) (idx land mask) v
 	| None -> iset (iget d.arr (idx lsr nbits)) (idx land mask) v
 	| Some arr -> iset arr idx v
 	| Some arr -> iset arr idx v
 
 
-let rec add d v =
+let add d v =
 	(match d.darr with
 	(match d.darr with
 	| None ->
 	| None ->
 		let asize = ilen d.arr in
 		let asize = ilen d.arr in
@@ -140,7 +140,7 @@ let rec add d v =
 	| Some arr ->
 	| Some arr ->
 		if d.len < ilen arr then begin
 		if d.len < ilen arr then begin
 			(* set *)
 			(* set *)
-			iset arr d.len v;			
+			iset arr d.len v;
 		end else if d.len lsl 1 >= Sys.max_array_length then begin
 		end else if d.len lsl 1 >= Sys.max_array_length then begin
 			(* promote *)
 			(* promote *)
 			let count = (d.len + size) lsr nbits in
 			let count = (d.len + size) lsr nbits in
@@ -180,7 +180,7 @@ let of_list src =
 	let c = create() in
 	let c = create() in
 	List.iter (add c) src;
 	List.iter (add c) src;
 	c
 	c
-	
+
 let iter f d = match d.darr with
 let iter f d = match d.darr with
 	| None ->
 	| None ->
 	 	let max = ilen d.arr - 1 in
 	 	let max = ilen d.arr - 1 in
@@ -281,4 +281,4 @@ let fold_left f acc d = match d.darr with
 		for i = 0 to d.len - 1 do
 		for i = 0 to d.len - 1 do
 			acc := f !acc (iget arr i)
 			acc := f !acc (iget arr i)
 		done;
 		done;
-		!acc
+		!acc

+ 7 - 1
libs/ilib/dune

@@ -1,9 +1,15 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -27))
+	)
+)
+
 (library
 (library
 	(name ilib)
 	(name ilib)
 	(modules_without_implementation ilData ilMeta)
 	(modules_without_implementation ilData ilMeta)
 	(modules (:standard \ dump))
 	(modules (:standard \ dump))
 	(libraries extlib)
 	(libraries extlib)
 	(wrapped false)
 	(wrapped false)
-)
+)

+ 7 - 1
libs/javalib/dune

@@ -1,7 +1,13 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -50))
+	)
+)
+
 (library
 (library
 	(name javalib)
 	(name javalib)
 	(libraries extlib)
 	(libraries extlib)
 	(wrapped false)
 	(wrapped false)
-)
+)

+ 7 - 1
libs/neko/dune

@@ -1,7 +1,13 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -27))
+	)
+)
+
 (library
 (library
 	(name neko)
 	(name neko)
 	(libraries extlib)
 	(libraries extlib)
 	(wrapped false)
 	(wrapped false)
-)
+)

+ 7 - 1
libs/swflib/dune

@@ -1,8 +1,14 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -27))
+	)
+)
+
 (library
 (library
 	(name swflib)
 	(name swflib)
 	(libraries extc extlib extlib_leftovers)
 	(libraries extc extlib extlib_leftovers)
 	(modules_without_implementation as3 as3hl)
 	(modules_without_implementation as3 as3hl)
 	(wrapped false)
 	(wrapped false)
-)
+)

+ 7 - 1
libs/ttflib/dune

@@ -1,8 +1,14 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -27 -w -35))
+	)
+)
+
 (library
 (library
 	(name ttflib)
 	(name ttflib)
 	(libraries extlib extlib_leftovers swflib unix)
 	(libraries extlib extlib_leftovers swflib unix)
 	(modules (:standard \ main))
 	(modules (:standard \ main))
 	(wrapped false)
 	(wrapped false)
-)
+)

+ 7 - 1
libs/ziplib/dune

@@ -1,7 +1,13 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -27 -w -35 -w -50))
+	)
+)
+
 (library
 (library
 	(name ziplib)
 	(name ziplib)
 	(libraries extc unix)
 	(libraries extc unix)
 	(wrapped false)
 	(wrapped false)
-)
+)

+ 7 - 1
plugins/example/dune

@@ -1,7 +1,13 @@
 (data_only_dirs cmxs hx)
 (data_only_dirs cmxs hx)
 (include_subdirs unqualified)
 (include_subdirs unqualified)
 
 
+(env
+	(_
+		(flags -w -27 -w -50)
+	)
+)
+
 (library
 (library
 	(name example)
 	(name example)
 	(libraries haxe)
 	(libraries haxe)
-)
+)

+ 7 - 1
src-prebuild/dune

@@ -1,8 +1,14 @@
 (include_subdirs no)
 (include_subdirs no)
 
 
+(env
+	(_
+		(flags (-w -9 -w -32))
+	)
+)
+
 (executable
 (executable
 	(name prebuild)
 	(name prebuild)
 	(public_name haxe_prebuild)
 	(public_name haxe_prebuild)
 	(package haxe_prebuild)
 	(package haxe_prebuild)
 	(libraries extlib json)
 	(libraries extlib json)
-)
+)

+ 0 - 1
src/codegen/codegen.ml

@@ -20,7 +20,6 @@
 open Ast
 open Ast
 open Type
 open Type
 open Common
 open Common
-open Error
 open Globals
 open Globals
 open Extlib_leftovers
 open Extlib_leftovers
 
 

+ 1 - 1
src/codegen/dotnet.ml

@@ -1112,7 +1112,7 @@ let normalize_ilcls ctx cls =
 	in
 	in
 	let refclsfields = List.fold_left fold_field [] refclsfields in
 	let refclsfields = List.fold_left fold_field [] refclsfields in
 
 
-	let rec fold (fields,methods,props) f = match !f with
+	let fold (fields,methods,props) f = match !f with
 		| IlField f,_,_,_ -> f :: fields,methods,props
 		| IlField f,_,_,_ -> f :: fields,methods,props
 		| IlMethod m,_,_,_ -> fields,m :: methods,props
 		| IlMethod m,_,_,_ -> fields,m :: methods,props
 		| IlProp p,_,_,_ -> fields,methods,p :: props
 		| IlProp p,_,_,_ -> fields,methods,p :: props

+ 2 - 3
src/codegen/gencommon/castDetect.ml

@@ -21,7 +21,6 @@ open Common
 open Ast
 open Ast
 open Globals
 open Globals
 open Type
 open Type
-open Codegen
 open Gencommon
 open Gencommon
 
 
 (* ******************************************* *)
 (* ******************************************* *)
@@ -241,7 +240,7 @@ let is_exactly_basic gen t1 t2 =
 		| _ ->
 		| _ ->
 			false
 			false
 
 
-let rec is_unsafe_cast gen to_t from_t =
+let is_unsafe_cast gen to_t from_t =
 	match (follow to_t, follow from_t) with
 	match (follow to_t, follow from_t) with
 		| TInst(cl_to, to_params), TInst(cl_from, from_params) ->
 		| TInst(cl_to, to_params), TInst(cl_from, from_params) ->
 			not (is_cl_related gen cl_from from_params cl_to to_params)
 			not (is_cl_related gen cl_from from_params cl_to to_params)
@@ -657,7 +656,7 @@ let choose_ctor gen cl tparams etl maybe_empty_t p =
 		| _ ->
 		| _ ->
 			false
 			false
 	in
 	in
-	let rec check_cf cf =
+	let check_cf cf =
 		let t = apply_params sup.cl_params stl cf.cf_type in
 		let t = apply_params sup.cl_params stl cf.cf_type in
 		replace_mono t;
 		replace_mono t;
 		let args, _ = get_fun t in
 		let args, _ = get_fun t in

+ 1 - 2
src/codegen/gencommon/closuresToClass.ml

@@ -19,7 +19,6 @@
 open Option
 open Option
 open Common
 open Common
 open Globals
 open Globals
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Ast
 open Ast
 open Type
 open Type
@@ -1080,7 +1079,7 @@ struct
 			let cl = parent_func_class in
 			let cl = parent_func_class in
 			let pos = cl.cl_pos in
 			let pos = cl.cl_pos in
 
 
-			let rec mk_dyn_call arity api =
+			let mk_dyn_call arity api =
 				let zero = make_float gen.gcon.basic "0.0" pos in
 				let zero = make_float gen.gcon.basic "0.0" pos in
 				let rec loop i acc =
 				let rec loop i acc =
 					if i = 0 then
 					if i = 0 then

+ 0 - 1
src/codegen/gencommon/dynamicOperators.ml

@@ -19,7 +19,6 @@
 open Common
 open Common
 open Ast
 open Ast
 open Type
 open Type
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Gencommon
 open Gencommon
 
 

+ 0 - 1
src/codegen/gencommon/enumToClass.ml

@@ -20,7 +20,6 @@ open Common
 open Globals
 open Globals
 open Ast
 open Ast
 open Type
 open Type
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Gencommon
 open Gencommon
 
 

+ 0 - 1
src/codegen/gencommon/enumToClass2.ml

@@ -18,7 +18,6 @@
 *)
 *)
 open Common
 open Common
 open Ast
 open Ast
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Type
 open Type
 open Gencommon
 open Gencommon

+ 1 - 2
src/codegen/gencommon/fixOverrides.ml

@@ -19,7 +19,6 @@
 open Option
 open Option
 open Common
 open Common
 open Type
 open Type
-open Codegen
 open Gencommon
 open Gencommon
 
 
 (* ******************************************* *)
 (* ******************************************* *)
@@ -161,7 +160,7 @@ let run ~explicit_fn_name ~get_vmtype gen =
 			in
 			in
 			List.iter (fun (iface,itl) -> loop_iface iface itl) c.cl_implements;
 			List.iter (fun (iface,itl) -> loop_iface iface itl) c.cl_implements;
 			(* now go through all overrides, *)
 			(* now go through all overrides, *)
-			let rec check_f f =
+			let check_f f =
 				(* find the first declared field *)
 				(* find the first declared field *)
 				let is_overload = has_class_field_flag f CfOverload in
 				let is_overload = has_class_field_flag f CfOverload in
 				let decl = if is_overload then
 				let decl = if is_overload then

+ 0 - 1
src/codegen/gencommon/gencommon.ml

@@ -60,7 +60,6 @@ open Globals
 open Option
 open Option
 open Printf
 open Printf
 open ExtString
 open ExtString
-open Codegen
 open Overloads
 open Overloads
 
 
 (* ******************************************* *)
 (* ******************************************* *)

+ 0 - 1
src/codegen/gencommon/initFunction.ml

@@ -18,7 +18,6 @@
 *)
 *)
 open Common
 open Common
 open Type
 open Type
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Gencommon
 open Gencommon
 
 

+ 1 - 2
src/codegen/gencommon/overloadingConstructor.ml

@@ -19,7 +19,6 @@
 open Option
 open Option
 open Common
 open Common
 open Type
 open Type
-open Codegen
 open Gencommon
 open Gencommon
 
 
 (* ******************************************* *)
 (* ******************************************* *)
@@ -237,7 +236,7 @@ let create_static_ctor com ~empty_ctor_expr cl ctor follow_type =
 
 
 (* makes constructors that only call super() for the 'ctor' argument *)
 (* makes constructors that only call super() for the 'ctor' argument *)
 let clone_ctors com ctor sup stl cl =
 let clone_ctors com ctor sup stl cl =
-	let rec clone cf =
+	let clone cf =
 		let ncf = mk_class_field "new" (apply_params sup.cl_params stl cf.cf_type) (has_class_field_flag cf CfPublic) cf.cf_pos cf.cf_kind cf.cf_params in
 		let ncf = mk_class_field "new" (apply_params sup.cl_params stl cf.cf_type) (has_class_field_flag cf CfPublic) cf.cf_pos cf.cf_kind cf.cf_params in
 		if Meta.has Meta.Protected cf.cf_meta then
 		if Meta.has Meta.Protected cf.cf_meta then
 			ncf.cf_meta <- (Meta.Protected,[],ncf.cf_pos) :: ncf.cf_meta;
 			ncf.cf_meta <- (Meta.Protected,[],ncf.cf_pos) :: ncf.cf_meta;

+ 3 - 4
src/codegen/gencommon/realTypeParams.ml

@@ -20,7 +20,6 @@ open Option
 open Common
 open Common
 open Ast
 open Ast
 open Type
 open Type
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Gencommon
 open Gencommon
 
 
@@ -91,7 +90,7 @@ let rec has_type_params t =
 			List.exists (fun (n,o,t) -> has_type_params t) args || has_type_params ret
 			List.exists (fun (n,o,t) -> has_type_params t) args || has_type_params ret
 		| _ -> false
 		| _ -> false
 
 
-let rec follow_all_md md =
+let follow_all_md md =
 	let t = match md with
 	let t = match md with
 		| TClassDecl { cl_kind = KAbstractImpl a } ->
 		| TClassDecl { cl_kind = KAbstractImpl a } ->
 			TAbstract(a, extract_param_types a.a_params)
 			TAbstract(a, extract_param_types a.a_params)
@@ -366,7 +365,7 @@ module RealTypeParamsModf =
 struct
 struct
 
 
 	let set_only_hxgeneric gen =
 	let set_only_hxgeneric gen =
-		let rec run md =
+		let run md =
 			match md with
 			match md with
 				| TTypeDecl _ | TAbstractDecl _ -> md
 				| TTypeDecl _ | TAbstractDecl _ -> md
 				| _ -> ignore (set_hxgeneric gen md); md
 				| _ -> ignore (set_hxgeneric gen md); md
@@ -655,7 +654,7 @@ struct
 			end
 			end
 		in
 		in
 
 
-		let rec run md =
+		let run md =
 			match md with
 			match md with
 				| TClassDecl ({ cl_params = [] } as cl) ->
 				| TClassDecl ({ cl_params = [] } as cl) ->
 					(* see if we're implementing any generic interface *)
 					(* see if we're implementing any generic interface *)

+ 1 - 2
src/codegen/gencommon/reflectionCFs.ml

@@ -20,7 +20,6 @@ open Option
 open Common
 open Common
 open Ast
 open Ast
 open Type
 open Type
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Gencommon
 open Gencommon
 open ClosuresToClass
 open ClosuresToClass
@@ -1490,7 +1489,7 @@ struct
 	let priority = min_dep +. 10.
 	let priority = min_dep +. 10.
 
 
 	let configure gen baseclass baseinterface basedynamic =
 	let configure gen baseclass baseinterface basedynamic =
-		let rec run md =
+		let run md =
 			if is_hxgen md then
 			if is_hxgen md then
 				match md with
 				match md with
 				| TClassDecl cl when (has_class_flag cl CInterface) && cl.cl_path <> baseclass.cl_path && cl.cl_path <> baseinterface.cl_path && cl.cl_path <> basedynamic.cl_path ->
 				| TClassDecl cl when (has_class_flag cl CInterface) && cl.cl_path <> baseclass.cl_path && cl.cl_path <> baseinterface.cl_path && cl.cl_path <> basedynamic.cl_path ->

+ 0 - 1
src/codegen/gencommon/switchToIf.ml

@@ -18,7 +18,6 @@
 *)
 *)
 open Common
 open Common
 open Type
 open Type
-open Codegen
 open Gencommon
 open Gencommon
 
 
 (* ******************************************* *)
 (* ******************************************* *)

+ 0 - 1
src/codegen/gencommon/unreachableCodeEliminationSynf.ml

@@ -16,7 +16,6 @@
 	along with this program; if not, write to the Free Software
 	along with this program; if not, write to the Free Software
 	Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 	Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 *)
 *)
-open Common
 open Ast
 open Ast
 open Type
 open Type
 open Gencommon
 open Gencommon

+ 2 - 2
src/codegen/javaModern.ml

@@ -422,7 +422,7 @@ module JReaderModern = struct
 			let len = read_i32 ch in
 			let len = read_i32 ch in
 			ignore(IO.nread_string ch len); (* code *)
 			ignore(IO.nread_string ch len); (* code *)
 			let len = read_ui16 ch in
 			let len = read_ui16 ch in
-			for i = 0 to len - 1 do
+			for _ = 0 to len - 1 do
 				ignore(IO.nread_string ch 8);
 				ignore(IO.nread_string ch 8);
 			done; (* exceptions *)
 			done; (* exceptions *)
 			let attribs = parse_attributes consts ch in
 			let attribs = parse_attributes consts ch in
@@ -1056,4 +1056,4 @@ class java_library_modern com name file_path = object(self)
 		build path
 		build path
 
 
 	method get_data = ()
 	method get_data = ()
-end
+end

+ 2 - 2
src/codegen/swfLoader.ml

@@ -454,7 +454,7 @@ let build_class com c file =
 let extract_data (_,tags) =
 let extract_data (_,tags) =
 	let t = Timer.timer ["read";"swf"] in
 	let t = Timer.timer ["read";"swf"] in
 	let h = Hashtbl.create 0 in
 	let h = Hashtbl.create 0 in
-	let rec loop_field f =
+	let loop_field f =
 		match f.hlf_kind with
 		match f.hlf_kind with
 		| HFClass c ->
 		| HFClass c ->
 			let path = make_tpath f.hlf_name in
 			let path = make_tpath f.hlf_name in
@@ -647,7 +647,7 @@ let remove_classes toremove lib l =
 					match t.tdata with
 					match t.tdata with
 					| TActionScript3 (h,data) ->
 					| TActionScript3 (h,data) ->
 						let data = As3hlparse.parse data in
 						let data = As3hlparse.parse data in
-						let rec loop f =
+						let loop f =
 							match f.hlf_kind with
 							match f.hlf_kind with
 							| HFClass _ ->
 							| HFClass _ ->
 								let path = make_tpath f.hlf_name in
 								let path = make_tpath f.hlf_name in

+ 0 - 4
src/compiler/displayOutput.ml

@@ -1,20 +1,16 @@
 open Globals
 open Globals
 open Ast
 open Ast
 open Common
 open Common
-open Filename
 open Timer
 open Timer
 open DisplayTypes.DisplayMode
 open DisplayTypes.DisplayMode
 open DisplayTypes.CompletionResultKind
 open DisplayTypes.CompletionResultKind
 open CompletionItem
 open CompletionItem
 open CompletionClassField
 open CompletionClassField
 open CompletionEnumField
 open CompletionEnumField
-open ClassFieldOrigin
 open DisplayException
 open DisplayException
 open Type
 open Type
-open Display
 open DisplayTypes
 open DisplayTypes
 open CompletionModuleType
 open CompletionModuleType
-open Typecore
 open Genjson
 open Genjson
 open CompilationContext
 open CompilationContext
 open DisplayProcessingGlobals
 open DisplayProcessingGlobals

+ 1 - 4
src/compiler/server.ml

@@ -1,13 +1,10 @@
-open Printf
 open Globals
 open Globals
-open Ast
 open Common
 open Common
 open CompilationCache
 open CompilationCache
 open Timer
 open Timer
 open Type
 open Type
 open DisplayProcessingGlobals
 open DisplayProcessingGlobals
 open Json
 open Json
-open Compiler
 open CompilationContext
 open CompilationContext
 open MessageReporting
 open MessageReporting
 
 
@@ -557,7 +554,7 @@ let do_connect host port args =
 	let s = (String.concat "" (List.map (fun a -> a ^ "\n") args)) ^ (display_stdin args) in
 	let s = (String.concat "" (List.map (fun a -> a ^ "\n") args)) ^ (display_stdin args) in
 	ssend sock (Bytes.of_string (s ^ "\000"));
 	ssend sock (Bytes.of_string (s ^ "\000"));
 	let has_error = ref false in
 	let has_error = ref false in
-	let rec print line =
+	let print line =
 		match (if line = "" then '\x00' else line.[0]) with
 		match (if line = "" then '\x00' else line.[0]) with
 		| '\x01' ->
 		| '\x01' ->
 			print_string (String.concat "\n" (List.tl (ExtString.String.nsplit line "\x01")));
 			print_string (String.concat "\n" (List.tl (ExtString.String.nsplit line "\x01")));

+ 0 - 1
src/compiler/serverMessage.ml

@@ -2,7 +2,6 @@ open Globals
 open Common
 open Common
 open CompilationCache
 open CompilationCache
 open Type
 open Type
-open Json
 
 
 type server_message_options = {
 type server_message_options = {
 	mutable print_added_directory : bool;
 	mutable print_added_directory : bool;

+ 0 - 1
src/context/abstractCast.ml

@@ -4,7 +4,6 @@ open Ast
 open Type
 open Type
 open Typecore
 open Typecore
 open Error
 open Error
-open CallUnification
 
 
 let cast_stack = new_rec_stack()
 let cast_stack = new_rec_stack()
 
 

+ 0 - 2
src/context/common.ml

@@ -1260,8 +1260,6 @@ let display_error_ext com err =
 let display_error com ?(depth = 0) msg p =
 let display_error com ?(depth = 0) msg p =
 	display_error_ext com (Error.make_error ~depth (Custom msg) p)
 	display_error_ext com (Error.make_error ~depth (Custom msg) p)
 
 
-open Printer
-
 let dump_path com =
 let dump_path com =
 	Define.defined_value_safe ~default:"dump" com.defines Define.DumpPath
 	Define.defined_value_safe ~default:"dump" com.defines Define.DumpPath
 
 

+ 0 - 4
src/context/display/diagnostics.ml

@@ -1,12 +1,8 @@
 open Globals
 open Globals
 open Ast
 open Ast
 open Type
 open Type
-open Typecore
 open Common
 open Common
-open Display
-open DisplayTypes.DisplayMode
 open DisplayTypes
 open DisplayTypes
-open DisplayException
 
 
 let add_removable_code ctx s p prange =
 let add_removable_code ctx s p prange =
 	ctx.removable_code <- (s,p,prange) :: ctx.removable_code
 	ctx.removable_code <- (s,p,prange) :: ctx.removable_code

+ 0 - 1
src/context/display/diagnosticsPrinter.ml

@@ -2,7 +2,6 @@ open Globals
 open Common
 open Common
 open Json
 open Json
 open DisplayTypes
 open DisplayTypes
-open DisplayTypes
 open Type
 open Type
 open Genjson
 open Genjson
 open MessageKind
 open MessageKind

+ 1 - 4
src/context/display/display.ml

@@ -2,13 +2,10 @@ open Ast
 open Common
 open Common
 open DisplayTypes
 open DisplayTypes
 open DisplayMode
 open DisplayMode
-open DisplayPosition
 open CompletionItem
 open CompletionItem
-open CompletionResultKind
 open Type
 open Type
 open Typecore
 open Typecore
 open Globals
 open Globals
-open Genjson
 open DisplayPosition
 open DisplayPosition
 open ImportStatus
 open ImportStatus
 
 
@@ -290,7 +287,7 @@ let sort_fields l with_type tk =
 	in
 	in
 	let l = match with_type with
 	let l = match with_type with
 		| WithType.WithType(t,_) when (match follow t with TMono _ -> false | _ -> true) ->
 		| WithType.WithType(t,_) when (match follow t with TMono _ -> false | _ -> true) ->
-			let rec comp item = match item.ci_type with
+			let comp item = match item.ci_type with
 				| None -> 9
 				| None -> 9
 				| Some (t',_) ->
 				| Some (t',_) ->
 				(* For enum constructors, we consider the return type of the constructor function
 				(* For enum constructors, we consider the return type of the constructor function

+ 1 - 2
src/context/display/displayEmitter.ml

@@ -6,7 +6,6 @@ open DisplayException
 open DisplayTypes
 open DisplayTypes
 open DisplayMode
 open DisplayMode
 open CompletionItem
 open CompletionItem
-open CompletionType
 open ClassFieldOrigin
 open ClassFieldOrigin
 open DisplayTypes.CompletionResultKind
 open DisplayTypes.CompletionResultKind
 open Common
 open Common
@@ -192,4 +191,4 @@ let check_field_modifiers ctx c cf override display_modifier =
 			) missing_fields [] in
 			) missing_fields [] in
 			let l = sort_fields l NoValue TKOverride in
 			let l = sort_fields l NoValue TKOverride in
 			raise_fields l CROverride (make_subject (Some cf.cf_name) cf.cf_name_pos)
 			raise_fields l CROverride (make_subject (Some cf.cf_name) cf.cf_name_pos)
-		| _ -> ()
+		| _ -> ()

+ 0 - 1
src/context/display/displayJson.ml

@@ -1,5 +1,4 @@
 open Globals
 open Globals
-open Json.Reader
 open JsonRpc
 open JsonRpc
 open Jsonrpc_handler
 open Jsonrpc_handler
 open Json
 open Json

+ 1 - 3
src/context/display/displayTexpr.ml

@@ -4,9 +4,7 @@ open Ast
 open Type
 open Type
 open Typecore
 open Typecore
 open DisplayPosition
 open DisplayPosition
-open CompletionItem
 open CompilationCache
 open CompilationCache
-open ClassFieldOrigin
 
 
 let find_field_by_position sc p =
 let find_field_by_position sc p =
 	List.find (fun cff ->
 	List.find (fun cff ->
@@ -184,4 +182,4 @@ let check_display_file ctx cs =
 			cs#taint_modules fkey "check_display_file";
 			cs#taint_modules fkey "check_display_file";
 		end
 		end
 	| None ->
 	| None ->
-		()
+		()

+ 0 - 1
src/context/display/displayToplevel.ml

@@ -24,7 +24,6 @@ open Typecore
 open CompletionItem
 open CompletionItem
 open ClassFieldOrigin
 open ClassFieldOrigin
 open DisplayTypes
 open DisplayTypes
-open Genjson
 open Globals
 open Globals
 
 
 (* Merges argument and return types from macro and non-macro context, preferring the one that isn't Dynamic.
 (* Merges argument and return types from macro and non-macro context, preferring the one that isn't Dynamic.

+ 1 - 3
src/context/display/findReferences.ml

@@ -1,10 +1,8 @@
 open Globals
 open Globals
-open Ast
 open DisplayTypes
 open DisplayTypes
 open Common
 open Common
 open Type
 open Type
 open Typecore
 open Typecore
-open ImportHandling
 
 
 let find_possible_references tctx cs =
 let find_possible_references tctx cs =
 	let name,_,kind = Display.ReferencePosition.get () in
 	let name,_,kind = Display.ReferencePosition.get () in
@@ -164,4 +162,4 @@ let find_implementations tctx com name pos kind =
 let find_implementations tctx com =
 let find_implementations tctx com =
 	let name,pos,kind = Display.ReferencePosition.get () in
 	let name,pos,kind = Display.ReferencePosition.get () in
 	if pos <> null_pos then find_implementations tctx com name pos kind
 	if pos <> null_pos then find_implementations tctx com name pos kind
-	else DisplayException.raise_positions []
+	else DisplayException.raise_positions []

+ 1 - 4
src/context/display/statistics.ml

@@ -1,12 +1,9 @@
 open Globals
 open Globals
-open Ast
 open Type
 open Type
 open Common
 open Common
 open Typecore
 open Typecore
 open DisplayTypes
 open DisplayTypes
 
 
-open ImportHandling
-
 type relation =
 type relation =
 	| Implemented
 	| Implemented
 	| Extended
 	| Extended
@@ -367,4 +364,4 @@ module Printer = struct
 			]) :: acc
 			]) :: acc
 		) files [] in
 		) files [] in
 		string_of_json (JArray ja)
 		string_of_json (JArray ja)
-end
+end

+ 1 - 2
src/context/memory.ml

@@ -1,5 +1,4 @@
 open Globals
 open Globals
-open CompilationCache
 open Common
 open Common
 open Type
 open Type
 open Genjson
 open Genjson
@@ -283,4 +282,4 @@ let display_memory com =
 		if k1 = k2 then s1 - s2 else if k1 > k2 then 1 else -1
 		if k1 = k2 then s1 - s2 else if k1 > k2 then 1 else -1
 	) modules);
 	) modules);
 	if !mcount > 0 then print ("*** " ^ string_of_int !mcount ^ " modules have leaks !");
 	if !mcount > 0 then print ("*** " ^ string_of_int !mcount ^ " modules have leaks !");
-	print "Cache dump complete"
+	print "Cache dump complete"

+ 1 - 2
src/context/nativeLibraries.ml

@@ -18,7 +18,6 @@
  *)
  *)
 
 
 open Globals
 open Globals
-open ExtString
 
 
 type native_lib_flags =
 type native_lib_flags =
 	| FlagIsStd
 	| FlagIsStd
@@ -57,4 +56,4 @@ let create_native_libs () = {
 	net_libs = [];
 	net_libs = [];
 	swf_libs = [];
 	swf_libs = [];
 	all_libs = [];
 	all_libs = [];
-}
+}

+ 1 - 3
src/context/sourcemaps.ml

@@ -1,7 +1,5 @@
 open Extlib_leftovers
 open Extlib_leftovers
 open Globals
 open Globals
-open Ast
-open Lexer
 open Common
 open Common
 
 
 (**
 (**
@@ -299,4 +297,4 @@ let set_sourcemap_pointer (builder:sourcemap_builder option) (pointer:sm_node op
 		| Some builder ->
 		| Some builder ->
 			match pointer with
 			match pointer with
 				| Some node -> builder#seek node
 				| Some node -> builder#seek node
-				| None -> ()
+				| None -> ()

+ 1 - 2
src/context/typecore.ml

@@ -22,7 +22,6 @@ open Ast
 open Common
 open Common
 open Type
 open Type
 open Error
 open Error
-open DisplayTypes
 
 
 type type_patch = {
 type type_patch = {
 	mutable tp_type : complex_type option;
 	mutable tp_type : complex_type option;
@@ -468,7 +467,7 @@ let is_removable_field com f =
 	)
 	)
 
 
 (** checks if we can access to a given class field using current context *)
 (** checks if we can access to a given class field using current context *)
-let rec can_access ctx c cf stat =
+let can_access ctx c cf stat =
 	if (has_class_field_flag cf CfPublic) then
 	if (has_class_field_flag cf CfPublic) then
 		true
 		true
 	else if c == ctx.curclass then
 	else if c == ctx.curclass then

+ 0 - 2
src/core/abstract.ml

@@ -1,6 +1,4 @@
-open Globals
 open Ast
 open Ast
-open Meta
 open TType
 open TType
 open TFunctions
 open TFunctions
 open TPrinting
 open TPrinting

+ 3 - 5
src/core/ast.ml

@@ -441,7 +441,7 @@ let gen_doc_text_opt = Option.map gen_doc_text
 
 
 let get_own_doc_opt = Option.map_default (fun d -> d.doc_own) None
 let get_own_doc_opt = Option.map_default (fun d -> d.doc_own) None
 
 
-let rec is_postfix (e,_) op = match op with
+let is_postfix (e,_) op = match op with
 	| Increment | Decrement | Not -> true
 	| Increment | Decrement | Not -> true
 	| Neg | NegBits | Spread -> false
 	| Neg | NegBits | Spread -> false
 
 
@@ -1207,7 +1207,7 @@ module Expr = struct
 		Buffer.contents buf
 		Buffer.contents buf
 
 
 	let find_ident e =
 	let find_ident e =
-		let rec loop e = match fst e with
+		match fst e with
 			| EConst ct ->
 			| EConst ct ->
 				begin match ct with
 				begin match ct with
 				| Ident s ->
 				| Ident s ->
@@ -1217,8 +1217,6 @@ module Expr = struct
 				end
 				end
 			| _ ->
 			| _ ->
 				None
 				None
-		in
-		loop e
 end
 end
 
 
 let has_meta_option metas meta s =
 let has_meta_option metas meta s =
@@ -1260,4 +1258,4 @@ let get_meta_string meta key =
 		| (k,[EConst (String(name,_)),_],_) :: _ when k = key -> Some name
 		| (k,[EConst (String(name,_)),_],_) :: _ when k = key -> Some name
 		| _ :: l -> loop l
 		| _ :: l -> loop l
 	in
 	in
-	loop meta
+	loop meta

+ 1 - 3
src/core/displayTypes.ml

@@ -1,8 +1,6 @@
 open Globals
 open Globals
-open Path
 open Ast
 open Ast
 open Type
 open Type
-open Json
 open Genjson
 open Genjson
 
 
 module SymbolKind = struct
 module SymbolKind = struct
@@ -344,4 +342,4 @@ type display_exception_kind =
 	| DisplayPositions of pos list
 	| DisplayPositions of pos list
 	| DisplayFields of fields_result
 	| DisplayFields of fields_result
 	| DisplayPackage of string list
 	| DisplayPackage of string list
-	| DisplayNoResult
+	| DisplayNoResult

+ 1 - 1
src/core/error.ml

@@ -275,7 +275,7 @@ module BetterErrors = struct
 				let s1,s2 = loop() in
 				let s1,s2 = loop() in
 				Printf.sprintf "(...) -> %s" s1,Printf.sprintf "(...) -> %s" s2
 				Printf.sprintf "(...) -> %s" s1,Printf.sprintf "(...) -> %s" s2
 			| TypeParameter i ->
 			| TypeParameter i ->
-				let rec get_params t = match t with
+				let get_params t = match t with
 					| TInst({cl_path = path},params) | TEnum({e_path = path},params) | TAbstract({a_path = path},params) | TType({t_path = path},params) ->
 					| TInst({cl_path = path},params) | TEnum({e_path = path},params) | TAbstract({a_path = path},params) | TType({t_path = path},params) ->
 						path,params
 						path,params
 					| _ ->
 					| _ ->

+ 1 - 3
src/core/inheritDoc.ml

@@ -1,7 +1,5 @@
-open Globals
 open Ast
 open Ast
 open Type
 open Type
-open Typecore
 
 
 let expr_to_target e =
 let expr_to_target e =
 	let rec loop (e,p) =
 	let rec loop (e,p) =
@@ -194,7 +192,7 @@ and get_target_doc ctx e_target =
 		with Not_found ->
 		with Not_found ->
 			None
 			None
 	in
 	in
-	let rec resolve_type_t t =
+	let resolve_type_t t =
 		match follow t with
 		match follow t with
 		| TInst (c, _) ->
 		| TInst (c, _) ->
 			build_class_doc ctx c;
 			build_class_doc ctx c;

+ 2 - 2
src/core/tUnification.ml

@@ -166,7 +166,7 @@ module Monomorph = struct
 		| CMixed l ->
 		| CMixed l ->
 			List.iter (fun constr -> check_down_constraints constr t) l
 			List.iter (fun constr -> check_down_constraints constr t) l
 
 
-	let rec collect_up_constraints m =
+	let collect_up_constraints m =
 		let rec collect m acc =
 		let rec collect m acc =
 			List.fold_left (fun acc (t,name) ->
 			List.fold_left (fun acc (t,name) ->
 				match t with
 				match t with
@@ -286,7 +286,7 @@ let rec follow_and_close t = match follow t with
 	| t ->
 	| t ->
 		t
 		t
 
 
-let rec link e a b =
+let link e a b =
 	(* tell if setting a == b will create a type-loop *)
 	(* tell if setting a == b will create a type-loop *)
 	let rec loop t =
 	let rec loop t =
 		if t == a then
 		if t == a then

+ 2 - 2
src/core/warning.ml

@@ -13,7 +13,7 @@ type warning_option = {
 
 
 let parse_options s ps lexbuf =
 let parse_options s ps lexbuf =
 	let fail msg p =
 	let fail msg p =
-		Error.raise_typing_error msg {p with pmin = ps.pmin + p.pmin; pmax = ps.pmin + p.pmax}
+		raise_typing_error msg {p with pmin = ps.pmin + p.pmin; pmax = ps.pmin + p.pmax}
 	in
 	in
 	let parse_string s p =
 	let parse_string s p =
 		begin try
 		begin try
@@ -58,7 +58,7 @@ let from_meta ml =
 			let p = snd e in
 			let p = snd e in
 			parse_options s {p with pmin = p.pmin + 1; pmax = p.pmax - 1} (* pmin is on the quote *)
 			parse_options s {p with pmin = p.pmin + 1; pmax = p.pmax - 1} (* pmin is on the quote *)
 		| _ ->
 		| _ ->
-			Error.raise_typing_error "String expected" (snd e)
+			raise_typing_error "String expected" (snd e)
 	in
 	in
 	let rec loop acc ml = match ml with
 	let rec loop acc ml = match ml with
 		| (Meta.HaxeWarning,args,_) :: ml ->
 		| (Meta.HaxeWarning,args,_) :: ml ->

+ 10 - 2
src/dune

@@ -2,7 +2,15 @@
 
 
 (env
 (env
 	(_
 	(_
-		(flags (:standard -w -3 -w -23 -thread))
+		; 3 - Remove deprecation warnings
+		; 6 - Label omitted in function application
+		; 9 - Missing record field in a record pattern
+		; 23 - Useless record `with` clause (all fields already listed)
+		; 27 - Unused var (strict)
+		; 32 - Unused value declaration
+		; 36 - Unused `as super`
+		; 50 - Unexpected docstring
+		(flags (:standard -w -3 -w -6 -w -9 -w -23 -w -27 -w -32 -w -36 -w -50 -thread))
 	)
 	)
 )
 )
 
 
@@ -31,4 +39,4 @@
 	(link_flags (:include ../lib.sexp))
 	(link_flags (:include ../lib.sexp))
 	; Uncomment to enable bytecode output for ocamldebug support
 	; Uncomment to enable bytecode output for ocamldebug support
 	; (modes byte)
 	; (modes byte)
-)
+)

+ 0 - 1
src/filters/defaultArguments.ml

@@ -18,7 +18,6 @@
 *)
 *)
 open Common
 open Common
 open Type
 open Type
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 
 
 (*
 (*

+ 2 - 4
src/filters/exceptions.ml

@@ -3,8 +3,6 @@ open Ast
 open Type
 open Type
 open Common
 open Common
 open Typecore
 open Typecore
-open TyperBase
-open Fields
 open Error
 open Error
 
 
 let haxe_exception_type_path = (["haxe"],"Exception")
 let haxe_exception_type_path = (["haxe"],"Exception")
@@ -107,13 +105,13 @@ let is_in_list t lst =
 (**
 (**
 	Check if `t` can be thrown without wrapping.
 	Check if `t` can be thrown without wrapping.
 *)
 *)
-let rec is_native_throw ctx t =
+let is_native_throw ctx t =
 	ctx.throws_anything || is_in_list t ctx.config.ec_native_throws
 	ctx.throws_anything || is_in_list t ctx.config.ec_native_throws
 
 
 (**
 (**
 	Check if `t` can be caught without wrapping.
 	Check if `t` can be caught without wrapping.
 *)
 *)
-let rec is_native_catch ctx t =
+let is_native_catch ctx t =
 	ctx.catches_anything || is_in_list t ctx.config.ec_native_catches
 	ctx.catches_anything || is_in_list t ctx.config.ec_native_catches
 
 
 (**
 (**

+ 1 - 1
src/filters/filters.ml

@@ -849,7 +849,7 @@ let save_class_state ctx t =
 		in
 		in
 		let mk_field_restore f =
 		let mk_field_restore f =
 			Option.may save_vars f.cf_expr;
 			Option.may save_vars f.cf_expr;
-			let rec mk_overload_restore f =
+			let mk_overload_restore f =
 				add_class_field_flag f CfPostProcessed;
 				add_class_field_flag f CfPostProcessed;
 				f.cf_name,f.cf_kind,f.cf_expr,f.cf_type,f.cf_meta,f.cf_params
 				f.cf_name,f.cf_kind,f.cf_expr,f.cf_type,f.cf_meta,f.cf_params
 			in
 			in

+ 1 - 1
src/generators/gencpp.ml

@@ -4906,7 +4906,7 @@ let find_referenced_types_flags ctx obj field_name super_deps constructor_deps h
          visited := List.tl !visited;
          visited := List.tl !visited;
       end
       end
    in
    in
-   let rec visit_params expression =
+   let visit_params expression =
       begin
       begin
       let rec visit_expression = fun expression ->
       let rec visit_expression = fun expression ->
          (* Expand out TTypeExpr (ie, the name of a class, as used for static access etc ... *)
          (* Expand out TTypeExpr (ie, the name of a class, as used for static access etc ... *)

+ 4 - 5
src/generators/gencs.ml

@@ -24,7 +24,6 @@ open Common
 open Type
 open Type
 open Gencommon
 open Gencommon
 open Gencommon.SourceWriter
 open Gencommon.SourceWriter
-open Codegen
 open Texpr.Builder
 open Texpr.Builder
 open Printf
 open Printf
 open Option
 open Option
@@ -1153,7 +1152,7 @@ let generate con =
 
 
 		let in_value = ref false in
 		let in_value = ref false in
 
 
-		let rec md_s md =
+		let md_s md =
 			let md = follow_module (gen.gfollow#run_f) md in
 			let md = follow_module (gen.gfollow#run_f) md in
 			match md with
 			match md with
 				| TClassDecl ({ cl_params = [] } as cl) ->
 				| TClassDecl ({ cl_params = [] } as cl) ->
@@ -1559,7 +1558,7 @@ let generate con =
 								let nblocks = loop (List.rev !fixeds) 0 in
 								let nblocks = loop (List.rev !fixeds) 0 in
 								in_value := false;
 								in_value := false;
 								expr_s w { e with eexpr = TBlock el };
 								expr_s w { e with eexpr = TBlock el };
-								for i = 1 to nblocks do
+								for _ = 1 to nblocks do
 									end_block w
 									end_block w
 								done
 								done
 							| _ ->
 							| _ ->
@@ -2105,7 +2104,7 @@ let generate con =
 			write w (String.concat " " (List.rev !parts));
 			write w (String.concat " " (List.rev !parts));
 		in
 		in
 
 
-		let rec gen_event w is_static cl (event,t,custom,add,remove) =
+		let gen_event w is_static cl (event,t,custom,add,remove) =
 			let is_interface = (has_class_flag cl CInterface) in
 			let is_interface = (has_class_flag cl CInterface) in
 			let visibility = if is_interface then "" else "public" in
 			let visibility = if is_interface then "" else "public" in
 			let visibility, modifiers = get_fun_modifiers event.cf_meta visibility ["event"] in
 			let visibility, modifiers = get_fun_modifiers event.cf_meta visibility ["event"] in
@@ -2125,7 +2124,7 @@ let generate con =
 			newline w;
 			newline w;
 		in
 		in
 
 
-		let rec gen_prop w is_static cl is_final (prop,t,get,set) =
+		let gen_prop w is_static cl is_final (prop,t,get,set) =
 			gen_attributes w prop.cf_meta;
 			gen_attributes w prop.cf_meta;
 			let is_interface = (has_class_flag cl CInterface) in
 			let is_interface = (has_class_flag cl CInterface) in
 			let fn_is_final = function
 			let fn_is_final = function

+ 3 - 4
src/generators/genhl.ml

@@ -20,7 +20,6 @@
  * DEALINGS IN THE SOFTWARE.
  * DEALINGS IN THE SOFTWARE.
  *)
  *)
 open Extlib_leftovers
 open Extlib_leftovers
-open Unix
 open Globals
 open Globals
 open Ast
 open Ast
 open Type
 open Type
@@ -2738,7 +2737,7 @@ and eval_expr ctx e =
 		let r = alloc_tmp ctx rt in
 		let r = alloc_tmp ctx rt in
 		(try
 		(try
 			let max = ref (-1) in
 			let max = ref (-1) in
-			let rec get_int e =
+			let get_int e =
 				match e.eexpr with
 				match e.eexpr with
 				| TConst (TInt i) ->
 				| TConst (TInt i) ->
 					let v = Int32.to_int i in
 					let v = Int32.to_int i in
@@ -3345,7 +3344,7 @@ let generate_static ctx c f =
 		loop f.cf_meta
 		loop f.cf_meta
 
 
 
 
-let rec generate_member ctx c f =
+let generate_member ctx c f =
 	match f.cf_kind with
 	match f.cf_kind with
 	| Var _ -> ()
 	| Var _ -> ()
 	| _ when is_extern_field f -> ()
 	| _ when is_extern_field f -> ()
@@ -3688,7 +3687,7 @@ let write_code ch code debug =
 	let byte = IO.write_byte ch in
 	let byte = IO.write_byte ch in
 	let write_index = write_index_gen byte in
 	let write_index = write_index_gen byte in
 
 
-	let rec write_type t =
+	let write_type t =
 		write_index (try PMap.find t htypes with Not_found -> die (tstr t) __LOC__)
 		write_index (try PMap.find t htypes with Not_found -> die (tstr t) __LOC__)
 	in
 	in
 
 

+ 2 - 5
src/generators/genjava.ml

@@ -18,12 +18,9 @@
  *)
  *)
 open Extlib_leftovers
 open Extlib_leftovers
 open Globals
 open Globals
-open JData
-open Unix
 open Ast
 open Ast
 open Common
 open Common
 open Type
 open Type
-open Codegen
 open Gencommon
 open Gencommon
 open Gencommon.SourceWriter
 open Gencommon.SourceWriter
 open Printf
 open Printf
@@ -1055,7 +1052,7 @@ let generate con =
 		String.map (function | '$' -> '.' | c -> c) name
 		String.map (function | '$' -> '.' | c -> c) name
 	in
 	in
 	let change_id name = try Hashtbl.find reserved name with | Not_found -> name in
 	let change_id name = try Hashtbl.find reserved name with | Not_found -> name in
-	let rec change_ns ns = match ns with
+	let change_ns ns = match ns with
 		| [] -> ["haxe"; "root"]
 		| [] -> ["haxe"; "root"]
 		| _ -> List.map change_id ns
 		| _ -> List.map change_id ns
 	in
 	in
@@ -1374,7 +1371,7 @@ let generate con =
 
 
 	let in_value = ref false in
 	let in_value = ref false in
 
 
-	let rec md_s pos md =
+	let md_s pos md =
 		let md = follow_module (gen.gfollow#run_f) md in
 		let md = follow_module (gen.gfollow#run_f) md in
 		match md with
 		match md with
 			| TClassDecl (cl) ->
 			| TClassDecl (cl) ->

+ 9 - 9
src/generators/genphp7.ml

@@ -226,7 +226,7 @@ let get_real_path path = List.map get_real_name path
 (**
 (**
 	Resolve real type (bypass abstracts and typedefs)
 	Resolve real type (bypass abstracts and typedefs)
 *)
 *)
-let rec follow = Abstract.follow_with_abstracts
+let follow = Abstract.follow_with_abstracts
 
 
 (**
 (**
 	Adds packages specified by `-D php-prefix` to `type_path`.
 	Adds packages specified by `-D php-prefix` to `type_path`.
@@ -276,7 +276,7 @@ let fail ?msg p = Globals.die (Option.default "" msg) ~p
 (**
 (**
 	Check if `target` is a `Dynamic` type
 	Check if `target` is a `Dynamic` type
 *)
 *)
-let rec is_dynamic_type (target:Type.t) = match follow target with TDynamic _ -> true | _ -> false
+let is_dynamic_type (target:Type.t) = match follow target with TDynamic _ -> true | _ -> false
 
 
 (**
 (**
 	Check if `target` is `php.Ref`
 	Check if `target` is `php.Ref`
@@ -286,7 +286,7 @@ let is_ref (target:Type.t) = match target with TType ({ t_path = type_path }, _)
 (**
 (**
 	Check if `field` is a `dynamic function`
 	Check if `field` is a `dynamic function`
 *)
 *)
-let rec is_dynamic_method (field:tclass_field) =
+let is_dynamic_method (field:tclass_field) =
 	match field.cf_kind with
 	match field.cf_kind with
 		| Method MethDynamic -> true
 		| Method MethDynamic -> true
 		| _ -> false
 		| _ -> false
@@ -978,7 +978,7 @@ class class_wrapper (cls) =
 			Returns expression of a user-defined static __init__ method
 			Returns expression of a user-defined static __init__ method
 			@see http://old.haxe.org/doc/advanced/magic#initialization-magic
 			@see http://old.haxe.org/doc/advanced/magic#initialization-magic
 		*)
 		*)
-		method get_magic_init = cls.cl_init
+		method! get_magic_init = cls.cl_init
 		(**
 		(**
 			Returns hx source file name where this type was declared
 			Returns hx source file name where this type was declared
 		*)
 		*)
@@ -990,7 +990,7 @@ class class_wrapper (cls) =
 		(**
 		(**
 			If current type requires some additional type to be generated
 			If current type requires some additional type to be generated
 		*)
 		*)
-		method get_service_type : module_type option =
+		method! get_service_type : module_type option =
 			if not (has_class_flag cls CExtern) then
 			if not (has_class_flag cls CExtern) then
 				None
 				None
 			else
 			else
@@ -3434,7 +3434,7 @@ class class_builder ctx (cls:tclass) =
 		(**
 		(**
 			Indicates if type should be declared as `final`
 			Indicates if type should be declared as `final`
 		*)
 		*)
-		method is_final =
+		method! is_final =
 			if not (has_class_flag cls CFinal) then
 			if not (has_class_flag cls CFinal) then
 				false
 				false
 			else begin
 			else begin
@@ -3454,7 +3454,7 @@ class class_builder ctx (cls:tclass) =
 			Get amount of arguments of a parent method.
 			Get amount of arguments of a parent method.
 			Returns `None` if no such parent method exists.
 			Returns `None` if no such parent method exists.
 		*)
 		*)
-		method private get_parent_method_args_count name is_static : (int * int) option =
+		method! private get_parent_method_args_count name is_static : (int * int) option =
 			match cls.cl_super with
 			match cls.cl_super with
 				| None -> None
 				| None -> None
 				| Some (cls, _) ->
 				| Some (cls, _) ->
@@ -3478,14 +3478,14 @@ class class_builder ctx (cls:tclass) =
 		(**
 		(**
 			Indicates if `field` should be declared as `final`
 			Indicates if `field` should be declared as `final`
 		*)
 		*)
-		method is_final_field (field:tclass_field) : bool =
+		method! is_final_field (field:tclass_field) : bool =
 			has_class_field_flag field CfFinal
 			has_class_field_flag field CfFinal
 		(**
 		(**
 			Check if there is no native php constructor in inheritance chain of this class.
 			Check if there is no native php constructor in inheritance chain of this class.
 			E.g. `StdClass` does have a constructor while still can be called with `new StdClass()`.
 			E.g. `StdClass` does have a constructor while still can be called with `new StdClass()`.
 			So this method will return true for `MyClass` if `MyClass extends StdClass`.
 			So this method will return true for `MyClass` if `MyClass extends StdClass`.
 		*)
 		*)
-		method private extends_no_constructor =
+		method! private extends_no_constructor =
 			let rec extends_no_constructor tcls =
 			let rec extends_no_constructor tcls =
 				match tcls.cl_super with
 				match tcls.cl_super with
 					| None -> true
 					| None -> true

+ 1 - 1
src/generators/genshared.ml

@@ -369,7 +369,7 @@ object(self)
 					DynArray.add field_infos info;
 					DynArray.add field_infos info;
 					cf.cf_meta <- (Meta.Custom ":jvm.fieldInfo",[(EConst (Int (string_of_int index, None)),null_pos)],null_pos) :: cf.cf_meta;
 					cf.cf_meta <- (Meta.Custom ":jvm.fieldInfo",[(EConst (Int (string_of_int index, None)),null_pos)],null_pos) :: cf.cf_meta;
 					if not (Meta.has Meta.HxGen cf.cf_meta) then begin
 					if not (Meta.has Meta.HxGen cf.cf_meta) then begin
-						let rec loop next c =
+						let loop next c =
 							if (has_class_flag c CExtern) then make_native cf
 							if (has_class_flag c CExtern) then make_native cf
 							else match c.cl_constructor with
 							else match c.cl_constructor with
 								| Some cf' when Meta.has Meta.HxGen cf'.cf_meta -> make_haxe cf
 								| Some cf' when Meta.has Meta.HxGen cf'.cf_meta -> make_haxe cf

+ 0 - 1
src/generators/genswf.ml

@@ -18,7 +18,6 @@
 *)
 *)
 open Swf
 open Swf
 open As3hl
 open As3hl
-open Genswf9
 open ExtString
 open ExtString
 open Type
 open Type
 open Common
 open Common

+ 1 - 1
src/generators/genswf9.ml

@@ -917,7 +917,7 @@ let pop_value ctx retval =
 	   branch value *)
 	   branch value *)
 	if retval then ctx.infos.istack <- ctx.infos.istack - 1
 	if retval then ctx.infos.istack <- ctx.infos.istack - 1
 
 
-let rec gen_access ctx e (forset : 'a) : 'a access =
+let gen_access ctx e (forset : 'a) : 'a access =
 	match e.eexpr with
 	match e.eexpr with
 	| TLocal v ->
 	| TLocal v ->
 		gen_local_access ctx v e.epos forset
 		gen_local_access ctx v e.epos forset

+ 8 - 9
src/generators/jvm/jvmBuilder.ml

@@ -18,7 +18,6 @@
  *)
  *)
 
 
 open JvmGlobals
 open JvmGlobals
-open JvmData
 open JvmSignature
 open JvmSignature
 open JvmAttribute
 open JvmAttribute
 
 
@@ -29,7 +28,7 @@ type annotation_kind =
 	| ABool of bool
 	| ABool of bool
 	| AEnum of jsignature * string
 	| AEnum of jsignature * string
 	| AArray of annotation_kind list
 	| AArray of annotation_kind list
-	| AAnnotation of jsignature * annotation 
+	| AAnnotation of jsignature * annotation
 
 
 and annotation = (string * annotation_kind) list
 and annotation = (string * annotation_kind) list
 
 
@@ -38,7 +37,7 @@ type export_config = {
 }
 }
 
 
 let convert_annotations pool annotations =
 let convert_annotations pool annotations =
-	let rec process_annotation (jsig, l) = 		
+	let rec process_annotation (jsig, l) =
 		let offset = pool#add_string (generate_signature false jsig) in
 		let offset = pool#add_string (generate_signature false jsig) in
 		let l = List.map (fun (name,ak) ->
 		let l = List.map (fun (name,ak) ->
 			let offset = pool#add_string name in
 			let offset = pool#add_string name in
@@ -56,18 +55,18 @@ let convert_annotations pool annotations =
 				| AArray l ->
 				| AArray l ->
 					let l = List.map (fun ak -> loop ak) l in
 					let l = List.map (fun ak -> loop ak) l in
 					'[',ValArray(Array.of_list l)
 					'[',ValArray(Array.of_list l)
-				| AAnnotation (jsig, a) -> 
-					let ann = process_annotation (jsig, a) in 
+				| AAnnotation (jsig, a) ->
+					let ann = process_annotation (jsig, a) in
 					'@',ValAnnotation(ann)
 					'@',ValAnnotation(ann)
-					
+
 			in
 			in
 			offset,loop ak
 			offset,loop ak
 		) l in
 		) l in
-		{ 
+		{
 			ann_type = offset;
 			ann_type = offset;
 			ann_elements = Array.of_list l;
 			ann_elements = Array.of_list l;
-		} 
-	in  
+		}
+	in
 	let a = Array.map process_annotation annotations in
 	let a = Array.map process_annotation annotations in
 	a
 	a
 
 

+ 5 - 5
src/generators/jvm/jvmMethod.ml

@@ -496,7 +496,7 @@ class builder jc name jsig = object(self)
 			| _ ->
 			| _ ->
 				die "" __LOC__
 				die "" __LOC__
 		in
 		in
-		let rec unboxed_to_int () = match code#get_stack#top with
+		let unboxed_to_int () = match code#get_stack#top with
 			| TBool | TByte | TShort | TChar | TInt ->
 			| TBool | TByte | TShort | TChar | TInt ->
 				self#replace_top TInt;
 				self#replace_top TInt;
 			| TLong ->
 			| TLong ->
@@ -508,7 +508,7 @@ class builder jc name jsig = object(self)
 			| _ ->
 			| _ ->
 				die "" __LOC__
 				die "" __LOC__
 		in
 		in
-		let rec unboxed_to_long () = match code#get_stack#top with
+		let unboxed_to_long () = match code#get_stack#top with
 			| TBool | TByte | TShort | TChar | TInt ->
 			| TBool | TByte | TShort | TChar | TInt ->
 				code#i2l;
 				code#i2l;
 			| TLong ->
 			| TLong ->
@@ -520,7 +520,7 @@ class builder jc name jsig = object(self)
 			| _ ->
 			| _ ->
 				die "" __LOC__
 				die "" __LOC__
 		in
 		in
-		let rec unboxed_to_float () = match code#get_stack#top with
+		let unboxed_to_float () = match code#get_stack#top with
 			| TBool | TByte | TShort | TChar | TInt ->
 			| TBool | TByte | TShort | TChar | TInt ->
 				code#i2f;
 				code#i2f;
 			| TLong ->
 			| TLong ->
@@ -532,7 +532,7 @@ class builder jc name jsig = object(self)
 			| _ ->
 			| _ ->
 				die "" __LOC__
 				die "" __LOC__
 		in
 		in
-		let rec unboxed_to_double () = match code#get_stack#top with
+		let unboxed_to_double () = match code#get_stack#top with
 			| TBool | TByte | TShort | TChar | TInt ->
 			| TBool | TByte | TShort | TChar | TInt ->
 				code#i2d;
 				code#i2d;
 			| TLong ->
 			| TLong ->
@@ -1228,4 +1228,4 @@ and label (jm : builder) (name : string) = object(self)
 
 
 	method here =
 	method here =
 		self#at code#get_fp
 		self#at code#get_fp
-end
+end

+ 3 - 5
src/generators/jvm/jvmWriter.ml

@@ -85,7 +85,7 @@ let write_opcode ch code =
     wr (Int32.logand (Int32.shift_right_logical i32 8) i320xFF);
     wr (Int32.logand (Int32.shift_right_logical i32 8) i320xFF);
     wr (Int32.logand i32 i320xFF);
     wr (Int32.logand i32 i320xFF);
   in
   in
-  let rec loop code = match code with
+  match code with
     (* double *)
     (* double *)
     | OpD2f -> w 0x90
     | OpD2f -> w 0x90
     | OpD2i -> w 0x8e
     | OpD2i -> w 0x8e
@@ -302,7 +302,7 @@ let write_opcode ch code =
     | OpIinc(i,c) -> w 0x84; w i; w c (* TODO: signed? *)
     | OpIinc(i,c) -> w 0x84; w i; w c (* TODO: signed? *)
     | OpLookupswitch(pad,def,pairs) ->
     | OpLookupswitch(pad,def,pairs) ->
 		w 0xab;
 		w 0xab;
-		if pad > 0 then for i = 0 to pad -1 do w 0 done;
+		if pad > 0 then for _ = 0 to pad -1 do w 0 done;
 		b4 !def;
 		b4 !def;
 		b4 (Array.length pairs);
 		b4 (Array.length pairs);
 		Array.iter (fun (i,offset) ->
 		Array.iter (fun (i,offset) ->
@@ -311,7 +311,7 @@ let write_opcode ch code =
 		) pairs;
 		) pairs;
     | OpTableswitch(pad,def,low,high,offsets) ->
     | OpTableswitch(pad,def,low,high,offsets) ->
 		w 0xaa;
 		w 0xaa;
-		if pad > 0 then for i = 0 to pad -1 do w 0 done;
+		if pad > 0 then for _ = 0 to pad -1 do w 0 done;
 		b4 !def;
 		b4 !def;
 		b4r low;
 		b4r low;
 		b4r high;
 		b4r high;
@@ -337,5 +337,3 @@ let write_opcode ch code =
 			| OpWLstore i -> w 0x37; bp i
 			| OpWLstore i -> w 0x37; bp i
 			| OpWDstore i -> w 0x39; bp i
 			| OpWDstore i -> w 0x39; bp i
 		end
 		end
-  in
-  loop code

+ 1 - 3
src/macro/eval/EvalStackTrace.ml

@@ -1,9 +1,7 @@
 open Globals
 open Globals
 open EvalContext
 open EvalContext
-open EvalExceptions
 open EvalValue
 open EvalValue
 open EvalEncode
 open EvalEncode
-open EvalDecode
 open EvalHash
 open EvalHash
 open EvalString
 open EvalString
 
 
@@ -43,4 +41,4 @@ let getExceptionStack = vfun0 (fun () ->
 	let ctx = get_ctx() in
 	let ctx = get_ctx() in
 	let envs = ctx.exception_stack in
 	let envs = ctx.exception_stack in
 	make_stack (List.rev envs)
 	make_stack (List.rev envs)
-)
+)

+ 0 - 1
src/macro/eval/evalArray.ml

@@ -17,7 +17,6 @@
 	Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 	Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
  *)
  *)
 
 
-open Globals
 open EvalValue
 open EvalValue
 
 
 let create values = {
 let create values = {

+ 1 - 2
src/macro/eval/evalContext.ml

@@ -333,8 +333,7 @@ let get_eval ctx =
 		with Not_found ->
 		with Not_found ->
 			die "Cannot run Haxe code in a non-Haxe thread" __LOC__
 			die "Cannot run Haxe code in a non-Haxe thread" __LOC__
 
 
-
-let rec kind_name eval kind =
+let kind_name eval kind =
 	let rec loop kind env = match kind with
 	let rec loop kind env = match kind with
 		| EKMethod(i1,i2) ->
 		| EKMethod(i1,i2) ->
 			Printf.sprintf "%s.%s" (rev_hash i1) (rev_hash i2)
 			Printf.sprintf "%s.%s" (rev_hash i1) (rev_hash i2)

+ 1 - 9
src/macro/eval/evalDebug.ml

@@ -1,17 +1,9 @@
-open Gc
-open Globals
-open Ast
 open Type
 open Type
 open EvalJitContext
 open EvalJitContext
 open EvalContext
 open EvalContext
 open EvalValue
 open EvalValue
 open EvalExceptions
 open EvalExceptions
-open EvalPrinting
-open EvalHash
-open EvalEncode
-open EvalMisc
 open EvalDebugMisc
 open EvalDebugMisc
-open MacroApi
 
 
 let is_caught eval v =
 let is_caught eval v =
 	try
 	try
@@ -120,4 +112,4 @@ let debug_loop jit conn e f =
 		env.env_debug.debug_expr <- s_expr_pretty e;
 		env.env_debug.debug_expr <- s_expr_pretty e;
 		run_loop run_check_breakpoint env;
 		run_loop run_check_breakpoint env;
 	in
 	in
-	run_set
+	run_set

+ 1 - 3
src/macro/eval/evalDebugSocket.ml

@@ -1,6 +1,4 @@
-open Gc
 open Ast
 open Ast
-open Type
 open Globals
 open Globals
 open MacroApi
 open MacroApi
 open JsonRpcSocket
 open JsonRpcSocket
@@ -789,7 +787,7 @@ let make_connection socket =
 		debug.debug_context <- new eval_debug_context;
 		debug.debug_context <- new eval_debug_context;
 		send_event socket "exceptionStop" (Some (JObject ["threadId",JInt (Thread.id (Thread.self()));"text",JString (value_string v)]))
 		send_event socket "exceptionStop" (Some (JObject ["threadId",JInt (Thread.id (Thread.self()));"text",JString (value_string v)]))
 	in
 	in
-	let rec wait () : unit =
+	let wait () : unit =
 		let rec process_outcome id outcome =
 		let rec process_outcome id outcome =
 			let output j = send_json socket (JsonRpc.result id j) in
 			let output j = send_json socket (JsonRpc.result id j) in
 			output outcome;
 			output outcome;

+ 2 - 2
src/macro/eval/evalDecode.ml

@@ -110,7 +110,7 @@ let decode_pos v = match v with
 	| VInstance {ikind=IPos p} -> p
 	| VInstance {ikind=IPos p} -> p
 	| _ -> raise MacroApi.Invalid_expr (* maybe_decode_pos relies on this being raised *)
 	| _ -> raise MacroApi.Invalid_expr (* maybe_decode_pos relies on this being raised *)
 
 
-let rec decode_ref v : 'a = match v with
+let decode_ref v : 'a = match v with
 	| VInstance {ikind=IRef r} -> Obj.obj r
 	| VInstance {ikind=IRef r} -> Obj.obj r
 	| _ -> unexpected_value v "unsafe"
 	| _ -> unexpected_value v "unsafe"
 
 
@@ -127,4 +127,4 @@ let decode_option decode_value v =
 
 
 let decode_optional decode_value v =
 let decode_optional decode_value v =
 	if v = VNull then None
 	if v = VNull then None
-	else Some (decode_value v)
+	else Some (decode_value v)

+ 4 - 4
src/macro/eval/evalEmitter.ml

@@ -191,11 +191,11 @@ let emit_int_switch_array shift exec cases exec_def p env = match exec env with
 
 
 let rec run_while_continue exec_cond exec_body env =
 let rec run_while_continue exec_cond exec_body env =
 	try
 	try
-		while is_true (exec_cond env) do exec_body env done;
+		while is_true (exec_cond env) do ignore(exec_body env) done;
 	with Continue ->
 	with Continue ->
 		run_while_continue exec_cond exec_body env
 		run_while_continue exec_cond exec_body env
 
 
-let rec run_while exec_cond exec_body env =
+let run_while exec_cond exec_body env =
 	while is_true (exec_cond env) do exec_body env done
 	while is_true (exec_cond env) do exec_body env done
 
 
 let emit_while_break exec_cond exec_body env =
 let emit_while_break exec_cond exec_body env =
@@ -246,7 +246,7 @@ let emit_try exec catches env =
 			with Not_found ->
 			with Not_found ->
 				raise_notrace exc
 				raise_notrace exc
 		in
 		in
-		varacc (fun _ -> v) env;
+		ignore(varacc (fun _ -> v) env);
 		exec env
 		exec env
 	in
 	in
 	v
 	v
@@ -798,4 +798,4 @@ let emit_closure ctx mapping eci hasret exec fl env =
 		| _ -> create_closure refs
 		| _ -> create_closure refs
 	in
 	in
 	let f = create ctx eci exec fl in
 	let f = create ctx eci exec fl in
-	vstatic_function f
+	vstatic_function f

+ 2 - 4
src/macro/eval/evalMain.ml

@@ -25,8 +25,6 @@ open EvalValue
 open EvalContext
 open EvalContext
 open EvalPrototype
 open EvalPrototype
 open EvalExceptions
 open EvalExceptions
-open EvalJit
-open EvalJitContext
 open EvalPrinting
 open EvalPrinting
 open EvalMisc
 open EvalMisc
 open EvalHash
 open EvalHash
@@ -101,7 +99,7 @@ let create com api is_macro =
 	} in
 	} in
 	let eval = EvalThread.create_eval thread in
 	let eval = EvalThread.create_eval thread in
 	let evals = IntMap.singleton 0 eval in
 	let evals = IntMap.singleton 0 eval in
-	let rec ctx = {
+	let ctx = {
 		ctx_id = !GlobalState.sid;
 		ctx_id = !GlobalState.sid;
 		is_macro = is_macro;
 		is_macro = is_macro;
 		debug = debug;
 		debug = debug;
@@ -153,7 +151,7 @@ let create com api is_macro =
 				| Error.Error err ->
 				| Error.Error err ->
 						let messages = ref [] in
 						let messages = ref [] in
 						Error.recurse_error (fun depth err ->
 						Error.recurse_error (fun depth err ->
-							make_compiler_message ~from_macro:err.err_from_macro (Error.error_msg err.err_message) err.err_pos depth DKCompilerMessage Error
+							messages := (make_compiler_message ~from_macro:err.err_from_macro (Error.error_msg err.err_message) err.err_pos depth DKCompilerMessage Error) :: !messages;
 						) err;
 						) err;
 						MessageReporting.format_messages com !messages
 						MessageReporting.format_messages com !messages
 				| _ -> Printexc.to_string ex
 				| _ -> Printexc.to_string ex

+ 0 - 1
src/macro/eval/evalMisc.ml

@@ -19,7 +19,6 @@
 
 
 open Globals
 open Globals
 open Ast
 open Ast
-open Type
 open EvalValue
 open EvalValue
 open EvalContext
 open EvalContext
 open EvalEncode
 open EvalEncode

+ 0 - 1
src/macro/eval/evalPrinting.ml

@@ -18,7 +18,6 @@
  *)
  *)
 open Extlib_leftovers
 open Extlib_leftovers
 open Globals
 open Globals
-open Type
 open EvalValue
 open EvalValue
 open EvalContext
 open EvalContext
 open EvalField
 open EvalField

+ 1 - 3
src/macro/eval/evalStdLib.ml

@@ -1861,7 +1861,7 @@ module StdReflect = struct
 	)
 	)
 
 
 	let compareMethods = vfun2 (fun a b ->
 	let compareMethods = vfun2 (fun a b ->
-		let rec loop a b = a == b || match a,b with
+		let loop a b = a == b || match a,b with
 			| VFunction(f1,_),VFunction(f2,_) -> f1 == f2
 			| VFunction(f1,_),VFunction(f2,_) -> f1 == f2
 			| VFieldClosure(v1,f1),VFieldClosure(v2,f2) -> f1 == f2 && EvalMisc.compare v1 v2 = CEq
 			| VFieldClosure(v1,f1),VFieldClosure(v2,f2) -> f1 == f2 && EvalMisc.compare v1 v2 = CEq
 			| _ -> false
 			| _ -> false
@@ -2787,8 +2787,6 @@ module StdTls = struct
 end
 end
 
 
 module StdType = struct
 module StdType = struct
-	open Ast
-
 	let create_enum v constr params =
 	let create_enum v constr params =
 		let vf = field v constr in
 		let vf = field v constr in
 		match vf,params with
 		match vf,params with

+ 1 - 2
src/macro/eval/evalValue.ml

@@ -18,7 +18,6 @@
  *)
  *)
 open Extlib_leftovers
 open Extlib_leftovers
 open Globals
 open Globals
-open EvalHash
 
 
 type cmp =
 type cmp =
 	| CEq
 	| CEq
@@ -355,4 +354,4 @@ let s_expr_pretty e = (Type.s_expr_pretty false "" false (Type.s_type (Type.prin
 
 
 let rec vresolve v = match v with
 let rec vresolve v = match v with
 	| VLazy f -> vresolve (!f())
 	| VLazy f -> vresolve (!f())
-	| _ -> v
+	| _ -> v

+ 3 - 3
src/optimization/analyzer.ml

@@ -638,7 +638,7 @@ module LocalDce = struct
 	open Graph
 	open Graph
 	open AnalyzerConfig
 	open AnalyzerConfig
 
 
-	let rec has_side_effect e =
+	let has_side_effect e =
 		let rec loop e =
 		let rec loop e =
 			match e.eexpr with
 			match e.eexpr with
 			| TConst _ | TLocal _ | TTypeExpr _ | TFunction _ | TIdent _ -> ()
 			| TConst _ | TLocal _ | TTypeExpr _ | TFunction _ | TIdent _ -> ()
@@ -659,7 +659,7 @@ module LocalDce = struct
 		with Exit ->
 		with Exit ->
 			true
 			true
 
 
-	let rec apply ctx =
+	let apply ctx =
 		let is_used v =
 		let is_used v =
 			has_var_flag v VUsed
 			has_var_flag v VUsed
 		in
 		in
@@ -1167,4 +1167,4 @@ Typecore.analyzer_run_on_expr_ref := (fun com identifier e ->
 	let config = {config with AnalyzerConfig.optimize = true} in
 	let config = {config with AnalyzerConfig.optimize = true} in
 	let actx = Run.create_analyzer_context com config identifier e in
 	let actx = Run.create_analyzer_context com config identifier e in
 	Run.run_on_expr actx e
 	Run.run_on_expr actx e
-)
+)

+ 1 - 1
src/optimization/analyzerTexpr.ml

@@ -115,7 +115,7 @@ let target_handles_side_effect_order com = match com.platform with
 	| Php -> false
 	| Php -> false
 	| _ -> true
 	| _ -> true
 
 
-let rec can_be_used_as_value com e =
+let can_be_used_as_value com e =
 	let rec loop e = match e.eexpr with
 	let rec loop e = match e.eexpr with
 		| TBlock [e] -> loop e
 		| TBlock [e] -> loop e
 		| TBlock _ | TSwitch _ | TTry _ -> raise Exit
 		| TBlock _ | TSwitch _ | TTry _ -> raise Exit

+ 1 - 1
src/optimization/analyzerTexprTransformer.ml

@@ -687,7 +687,7 @@ let rec block_to_texpr_el ctx bb =
 		let block bb = block_to_texpr ctx bb in
 		let block bb = block_to_texpr ctx bb in
 		let live bb = not ctx.did_optimize || not ctx.config.local_dce || has_block_flag bb BlockDce in
 		let live bb = not ctx.did_optimize || not ctx.config.local_dce || has_block_flag bb BlockDce in
 		let if_live bb = if live bb then Some bb else None in
 		let if_live bb = if live bb then Some bb else None in
-		let rec loop bb se =
+		let loop bb se =
 			let get_terminator() = match bb.bb_terminator with
 			let get_terminator() = match bb.bb_terminator with
 				| TermCondBranch e1 -> e1
 				| TermCondBranch e1 -> e1
 				| _ -> die "" __LOC__
 				| _ -> die "" __LOC__

+ 1 - 1
src/optimization/dce.ml

@@ -267,7 +267,7 @@ let mark_mt dce mt = match mt with
 		()
 		()
 
 
 (* find all dependent fields by checking implementing/subclassing types *)
 (* find all dependent fields by checking implementing/subclassing types *)
-let rec mark_dependent_fields dce csup n stat =
+let mark_dependent_fields dce csup n stat =
 	let rec loop c =
 	let rec loop c =
 		(try
 		(try
 			let cf = PMap.find n (if stat then c.cl_statics else c.cl_fields) in
 			let cf = PMap.find n (if stat then c.cl_statics else c.cl_fields) in

+ 1 - 1
src/optimization/optimizerTexpr.ml

@@ -43,7 +43,7 @@ let is_read_only_field_access e fa = match fa with
 
 
 let create_affection_checker () =
 let create_affection_checker () =
 	let modified_locals = Hashtbl.create 0 in
 	let modified_locals = Hashtbl.create 0 in
-	let rec might_be_affected e =
+	let might_be_affected e =
 		let rec loop e = match e.eexpr with
 		let rec loop e = match e.eexpr with
 			| TConst _ | TFunction _ | TTypeExpr _ -> ()
 			| TConst _ | TFunction _ | TTypeExpr _ -> ()
 			| TLocal v when has_var_flag v VCaptured -> raise Exit
 			| TLocal v when has_var_flag v VCaptured -> raise Exit

+ 2 - 2
src/syntax/grammar.mly

@@ -30,7 +30,7 @@ let rec plist f = parser
 	| [< v = f; l = plist f >] -> v :: l
 	| [< v = f; l = plist f >] -> v :: l
 	| [< >] -> []
 	| [< >] -> []
 
 
-let rec psep_nonempty sep f = parser
+let psep_nonempty sep f = parser
 	| [< v = f; s >] ->
 	| [< v = f; s >] ->
 		let rec loop = parser
 		let rec loop = parser
 			| [< '(sep2,_) when sep2 = sep; v = f; l = loop >] -> v :: l
 			| [< '(sep2,_) when sep2 = sep; v = f; l = loop >] -> v :: l
@@ -38,7 +38,7 @@ let rec psep_nonempty sep f = parser
 		in
 		in
 		v :: loop s
 		v :: loop s
 
 
-let rec psep sep f = parser
+let psep sep f = parser
 	| [< r = psep_nonempty sep f >] -> r
 	| [< r = psep_nonempty sep f >] -> r
 	| [< >] -> []
 	| [< >] -> []
 
 

+ 0 - 1
src/syntax/parser.ml

@@ -19,7 +19,6 @@
 
 
 open Ast
 open Ast
 open Globals
 open Globals
-open Reification
 open DisplayTypes.DisplayMode
 open DisplayTypes.DisplayMode
 open DisplayPosition
 open DisplayPosition
 
 

+ 2 - 2
src/typing/callUnification.ml

@@ -13,7 +13,7 @@ let is_forced_inline c cf =
 	| _ when has_class_field_flag cf CfExtern -> true
 	| _ when has_class_field_flag cf CfExtern -> true
 	| _ -> false
 	| _ -> false
 
 
-let rec unify_call_args ctx el args r callp inline force_inline in_overload =
+let unify_call_args ctx el args r callp inline force_inline in_overload =
 	let call_error err p = raise_error_msg (Call_error err) p in
 	let call_error err p = raise_error_msg (Call_error err) p in
 
 
 	let arg_error e name opt =
 	let arg_error e name opt =
@@ -30,7 +30,7 @@ let rec unify_call_args ctx el args r callp inline force_inline in_overload =
 		let infos = mk_infos ctx callp [] in
 		let infos = mk_infos ctx callp [] in
 		type_expr ctx infos (WithType.with_type t)
 		type_expr ctx infos (WithType.with_type t)
 	in
 	in
-	let rec default_value name t =
+	let default_value name t =
 		if is_pos_infos t then
 		if is_pos_infos t then
 			mk_pos_infos t
 			mk_pos_infos t
 		else
 		else

+ 0 - 1
src/typing/finalization.ml

@@ -1,5 +1,4 @@
 open Globals
 open Globals
-open Ast
 open Common
 open Common
 open Type
 open Type
 open Error
 open Error

+ 1 - 1
src/typing/generic.ml

@@ -35,7 +35,7 @@ let make_generic ctx ps pt p =
 	in
 	in
 	let name =
 	let name =
 		String.concat "_" (List.map2 (fun {ttp_name=s} t ->
 		String.concat "_" (List.map2 (fun {ttp_name=s} t ->
-			let rec subst s = "_" ^ string_of_int (Char.code (String.get (Str.matched_string s) 0)) ^ "_" in
+			let subst s = "_" ^ string_of_int (Char.code (String.get (Str.matched_string s) 0)) ^ "_" in
 			let ident_safe = Str.global_substitute (Str.regexp "[^a-zA-Z0-9_]") subst in
 			let ident_safe = Str.global_substitute (Str.regexp "[^a-zA-Z0-9_]") subst in
 			let s_type_path_underscore (p,s) = match p with [] -> s | _ -> String.concat "_" p ^ "_" ^ s in
 			let s_type_path_underscore (p,s) = match p with [] -> s | _ -> String.concat "_" p ^ "_" ^ s in
 			let rec loop top t = match t with
 			let rec loop top t = match t with

+ 1 - 1
src/typing/macroContext.ml

@@ -534,7 +534,7 @@ let make_macro_api ctx p =
 		);
 		);
 	}
 	}
 
 
-let rec init_macro_interp mctx mint =
+let init_macro_interp mctx mint =
 	let p = null_pos in
 	let p = null_pos in
 	ignore(TypeloadModule.load_module mctx (["haxe";"macro"],"Expr") p);
 	ignore(TypeloadModule.load_module mctx (["haxe";"macro"],"Expr") p);
 	ignore(TypeloadModule.load_module mctx (["haxe";"macro"],"Type") p);
 	ignore(TypeloadModule.load_module mctx (["haxe";"macro"],"Type") p);

+ 4 - 4
src/typing/matcher/compile.ml

@@ -25,7 +25,7 @@ type matcher_context = {
 	mutable dt_count : int;
 	mutable dt_count : int;
 }
 }
 
 
-let rec hashcons mctx dt p =
+let hashcons mctx dt p =
 	try
 	try
 		DtTable.find mctx.dt_table dt
 		DtTable.find mctx.dt_table dt
 	with Not_found ->
 	with Not_found ->
@@ -41,7 +41,7 @@ let bind mctx bindings dt = hashcons mctx (Bind(bindings,dt)) dt.dt_pos
 let guard mctx e dt1 dt2 = hashcons mctx (Guard(e,dt1,dt2)) (punion dt1.dt_pos dt2.dt_pos)
 let guard mctx e dt1 dt2 = hashcons mctx (Guard(e,dt1,dt2)) (punion dt1.dt_pos dt2.dt_pos)
 let guard_null mctx e dt1 dt2 = hashcons mctx (GuardNull(e,dt1,dt2)) (punion dt1.dt_pos dt2.dt_pos)
 let guard_null mctx e dt1 dt2 = hashcons mctx (GuardNull(e,dt1,dt2)) (punion dt1.dt_pos dt2.dt_pos)
 
 
-let rec get_sub_subjects mctx e con arg_positions =
+let get_sub_subjects mctx e con arg_positions =
 	match fst con with
 	match fst con with
 	| ConEnum(en,ef) ->
 	| ConEnum(en,ef) ->
 		let tl = Monomorph.spawn_constrained_monos (fun t -> t) en.e_params in
 		let tl = Monomorph.spawn_constrained_monos (fun t -> t) en.e_params in
@@ -106,7 +106,7 @@ let rec is_wildcard_pattern pat = match fst pat with
 	| PatBind(_,pat1) -> is_wildcard_pattern pat1
 	| PatBind(_,pat1) -> is_wildcard_pattern pat1
 	| _ -> false
 	| _ -> false
 
 
-let rec expand cases =
+let expand cases =
 	let rec expand f (case,bindings,patterns) = match patterns with
 	let rec expand f (case,bindings,patterns) = match patterns with
 		| (PatOr(pat1,pat2),_) :: patterns ->
 		| (PatOr(pat1,pat2),_) :: patterns ->
 			(expand f (case,bindings,pat1 :: patterns)) @ (expand f (case,bindings,pat2 :: patterns))
 			(expand f (case,bindings,pat1 :: patterns)) @ (expand f (case,bindings,pat2 :: patterns))
@@ -413,4 +413,4 @@ let compile ctx match_debug subjects cases p =
 		match vars with
 		match vars with
 			| [] -> dt
 			| [] -> dt
 			| _ -> bind mctx vars dt
 			| _ -> bind mctx vars dt
-	end
+	end

+ 1 - 2
src/typing/matcher/pattern.ml

@@ -1,5 +1,4 @@
 open Globals
 open Globals
-open Constructor
 open Type
 open Type
 open MatcherGlobals
 open MatcherGlobals
 
 
@@ -26,4 +25,4 @@ let rec to_string pat = match fst pat with
 	| PatBind(v,pat1) -> Printf.sprintf "%s = %s" v.v_name (to_string pat1)
 	| PatBind(v,pat1) -> Printf.sprintf "%s = %s" v.v_name (to_string pat1)
 	| PatOr(pat1,pat2) -> Printf.sprintf "(%s) | (%s)" (to_string pat1) (to_string pat2)
 	| PatOr(pat1,pat2) -> Printf.sprintf "(%s) | (%s)" (to_string pat1) (to_string pat2)
 	| PatTuple pl -> Printf.sprintf "[%s]" (String.concat ", " (List.map to_string pl))
 	| PatTuple pl -> Printf.sprintf "[%s]" (String.concat ", " (List.map to_string pl))
-	| PatExtractor ex -> Printf.sprintf "%s => %s" (s_expr_pretty ex.ex_expr) (to_string ex.ex_pattern)
+	| PatExtractor ex -> Printf.sprintf "%s => %s" (s_expr_pretty ex.ex_expr) (to_string ex.ex_pattern)

+ 1 - 2
src/typing/matcher/texprConverter.ml

@@ -4,7 +4,6 @@ open Type
 open Typecore
 open Typecore
 open Common
 open Common
 open Error
 open Error
-open DisplayTypes
 open MatcherGlobals
 open MatcherGlobals
 open DecisionTree
 open DecisionTree
 open Constructor
 open Constructor
@@ -388,4 +387,4 @@ let to_texpr ctx t_switch with_type dt =
 	| None ->
 	| None ->
 		raise_typing_error "Unmatched patterns: _" p;
 		raise_typing_error "Unmatched patterns: _" p;
 	| Some e ->
 	| Some e ->
-		Texpr.duplicate_tvars e
+		Texpr.duplicate_tvars e

+ 2 - 2
src/typing/matcher/useless.ml

@@ -85,7 +85,7 @@ let transfer_column source target =
 
 
 let copy p = List.map (fun _ -> []) p
 let copy p = List.map (fun _ -> []) p
 
 
-let rec specialize' is_tuple con pM qM rM =
+let specialize' is_tuple con pM qM rM =
 	let arity = arity con in
 	let arity = arity con in
 	let rec loop pAcc qAcc rAcc pM qM rM = match pM,qM,rM with
 	let rec loop pAcc qAcc rAcc pM qM rM = match pM,qM,rM with
 		| p1 :: pM,q1 :: qM,r1 :: rM ->
 		| p1 :: pM,q1 :: qM,r1 :: rM ->
@@ -188,4 +188,4 @@ let check ctx cases =
 	ignore(List.fold_left (fun acc (case,bindings,patterns) ->
 	ignore(List.fold_left (fun acc (case,bindings,patterns) ->
 		check_case ctx acc (case,bindings,patterns);
 		check_case ctx acc (case,bindings,patterns);
 		if case.case_guard = None then acc @ [case,bindings,patterns] else acc
 		if case.case_guard = None then acc @ [case,bindings,patterns] else acc
-	) [] cases)
+	) [] cases)

+ 2 - 2
src/typing/nullSafety.ml

@@ -1408,7 +1408,7 @@ class expr_checker mode immediate_execution report =
 						| None ->
 						| None ->
 							List.iter self#check_expr args
 							List.iter self#check_expr args
 						| Some cf ->
 						| Some cf ->
-							let rec traverse t =
+							let traverse t =
 								match follow t with
 								match follow t with
 									| TFun (types, _) -> self#check_args e_new args types
 									| TFun (types, _) -> self#check_args e_new args types
 									| _ -> fail ~msg:"Unexpected constructor type." e_new.epos __POS__
 									| _ -> fail ~msg:"Unexpected constructor type." e_new.epos __POS__
@@ -1674,7 +1674,7 @@ let run (com:Common.context) (types:module_type list) =
 	let timer = Timer.timer ["null safety"] in
 	let timer = Timer.timer ["null safety"] in
 	let report = { sr_errors = [] } in
 	let report = { sr_errors = [] } in
 	let immediate_execution = new immediate_execution in
 	let immediate_execution = new immediate_execution in
-	let rec traverse module_type =
+	let traverse module_type =
 		match module_type with
 		match module_type with
 			| TEnumDecl enm -> ()
 			| TEnumDecl enm -> ()
 			| TTypeDecl typedef -> ()
 			| TTypeDecl typedef -> ()

+ 1 - 2
src/typing/typeload.ml

@@ -32,7 +32,6 @@ open Type
 open Typecore
 open Typecore
 open Error
 open Error
 open Globals
 open Globals
-open Filename
 
 
 let build_count = ref 0
 let build_count = ref 0
 
 
@@ -524,7 +523,7 @@ and load_complex_type' ctx allow_display (t,p) =
 		end
 		end
 	| CTAnonymous l ->
 	| CTAnonymous l ->
 		let displayed_field = ref None in
 		let displayed_field = ref None in
-		let rec loop acc f =
+		let loop acc f =
 			let n = fst f.cff_name in
 			let n = fst f.cff_name in
 			let pf = snd f.cff_name in
 			let pf = snd f.cff_name in
 			let p = f.cff_pos in
 			let p = f.cff_pos in

+ 0 - 1
src/typing/typeloadCheck.ml

@@ -52,7 +52,6 @@ let valid_redefinition ctx map1 map2 f1 t1 f2 t2 = (* child, parent *)
 		Type.unify t1 t2;
 		Type.unify t1 t2;
 		if is_null t1 <> is_null t2 || ((follow t1) == t_dynamic && (follow t2) != t_dynamic) then raise (Unify_error [Cannot_unify (t1,t2)]);
 		if is_null t1 <> is_null t2 || ((follow t1) == t_dynamic && (follow t2) != t_dynamic) then raise (Unify_error [Cannot_unify (t1,t2)]);
 	in
 	in
-	let open OptimizerTexpr in
 	begin match PurityState.get_purity_from_meta f2.cf_meta,PurityState.get_purity_from_meta f1.cf_meta with
 	begin match PurityState.get_purity_from_meta f2.cf_meta,PurityState.get_purity_from_meta f1.cf_meta with
 		| PurityState.Pure,PurityState.MaybePure -> f1.cf_meta <- (Meta.Pure,[EConst(Ident "expect"),f2.cf_pos],null_pos) :: f1.cf_meta
 		| PurityState.Pure,PurityState.MaybePure -> f1.cf_meta <- (Meta.Pure,[EConst(Ident "expect"),f2.cf_pos],null_pos) :: f1.cf_meta
 		| PurityState.ExpectPure p,PurityState.MaybePure -> f1.cf_meta <- (Meta.Pure,[EConst(Ident "expect"),p],null_pos) :: f1.cf_meta
 		| PurityState.ExpectPure p,PurityState.MaybePure -> f1.cf_meta <- (Meta.Pure,[EConst(Ident "expect"),p],null_pos) :: f1.cf_meta

+ 0 - 2
src/typing/typeloadFunction.ml

@@ -23,8 +23,6 @@ open Globals
 open Ast
 open Ast
 open Type
 open Type
 open Typecore
 open Typecore
-open DisplayTypes.DisplayMode
-open DisplayException
 open Common
 open Common
 open Error
 open Error
 open FunctionArguments
 open FunctionArguments

+ 0 - 2
src/typing/typeloadModule.ml

@@ -21,11 +21,9 @@
 
 
 open Globals
 open Globals
 open Ast
 open Ast
-open Filename
 open Type
 open Type
 open Typecore
 open Typecore
 open DisplayTypes.DisplayMode
 open DisplayTypes.DisplayMode
-open DisplayTypes.CompletionResultKind
 open Common
 open Common
 open Typeload
 open Typeload
 open Error
 open Error

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است