Explorar o código

Revert "write TInt as leb too"

This reverts commit ce6c8de751133b2e5898d9d9239e51128358198f.
Simon Krajewski hai 1 ano
pai
achega
7c1f5ef8e2
Modificáronse 2 ficheiros con 2 adicións e 2 borrados
  1. 1 1
      src/compiler/hxb/hxbReader.ml
  2. 1 1
      src/compiler/hxb/hxbWriter.ml

+ 1 - 1
src/compiler/hxb/hxbReader.ml

@@ -982,7 +982,7 @@ class hxb_reader
 					| 2 -> TConst TSuper
 					| 3 -> TConst (TBool false)
 					| 4 -> TConst (TBool true)
-					| 5 -> TConst (TInt (Int32.of_int self#read_leb128))
+					| 5 -> TConst (TInt self#read_i32)
 					| 6 -> TConst (TFloat self#read_string)
 					| 7 -> TConst (TString self#read_string)
 

+ 1 - 1
src/compiler/hxb/hxbWriter.ml

@@ -1267,7 +1267,7 @@ class hxb_writer
 					self#write_texpr_byte 4;
 				| TInt i32 ->
 					self#write_texpr_byte 5;
-					chunk#write_leb128 (Int32.to_int i32);
+					chunk#write_i32 i32;
 				| TFloat f ->
 					self#write_texpr_byte 6;
 					chunk#write_string f;