2
0
Эх сурвалжийг харах

[cs] remove workaround for unity's #line bug as it's now fixed by d464df1a66b1c502dc97b327d172144d9e942f49 (see #3759)

Dan Korostelev 10 жил өмнө
parent
commit
ac30dd5dc7
2 өөрчлөгдсөн 1 нэмэгдсэн , 5 устгасан
  1. 0 3
      common.ml
  2. 1 2
      gencs.ml

+ 0 - 3
common.ml

@@ -240,7 +240,6 @@ module Define = struct
 		| SwfScriptTimeout
 		| SwfUseDoAbc
 		| Sys
-		| Unity46LineNumbers
 		| Unsafe
 		| UseNekoc
 		| UseRttiDoc
@@ -325,8 +324,6 @@ module Define = struct
 		| SwfScriptTimeout -> ("swf_script_timeout", "Maximum ActionScript processing time before script stuck dialog box displays (in seconds)")
 		| SwfUseDoAbc -> ("swf_use_doabc", "Use DoAbc swf-tag instead of DoAbcDefine")
 		| Sys -> ("sys","Defined for all system platforms")
-		(* see https://github.com/HaxeFoundation/haxe/issues/3759 *)
-		| Unity46LineNumbers -> ("unity46_line_numbers", "Fixes line numbers in generated C# files for Unity 4.6 Mono compiler")
 		| Unsafe -> ("unsafe","Allow unsafe code when targeting C#")
 		| UseNekoc -> ("use_nekoc","Use nekoc compiler instead of internal one")
 		| UseRttiDoc -> ("use_rtti_doc","Allows access to documentation during compilation")

+ 1 - 2
gencs.ml

@@ -1138,8 +1138,7 @@ let configure gen =
 		else fun w p ->
 			let cur_line = Lexer.get_error_line p in
 			let file = Common.get_full_path p.pfile in
-			let line = if Common.defined gen.gcon Define.Unity46LineNumbers then cur_line - 1 else cur_line in
-			if cur_line <> ((!last_line)+1) then begin print w "#line %d \"%s\"" line (Ast.s_escape file); newline w end;
+			if cur_line <> ((!last_line)+1) then begin print w "#line %d \"%s\"" cur_line (Ast.s_escape file); newline w end;
 			last_line := cur_line
 	in
 	let line_reset_directive =