Nicolas Cannasse 18 лет назад
Родитель
Сommit
ca4bf16141
4 измененных файлов с 7 добавлено и 2 удалено
  1. 1 0
      doc/CHANGES.txt
  2. 2 2
      genxml.ml
  3. 2 0
      type.ml
  4. 2 0
      typer.ml

+ 1 - 0
doc/CHANGES.txt

@@ -13,6 +13,7 @@
 	added flash9 bytearray serialization (to binary string, for neko com)
 	added flash9 bytearray serialization (to binary string, for neko com)
 	fixed Type.typeof on some flash9 instances
 	fixed Type.typeof on some flash9 instances
 	no more dontUseCache (haxe.Serializer.USE_CACHE, default to false)
 	no more dontUseCache (haxe.Serializer.USE_CACHE, default to false)
+	small genxml/haxedoc improvements
 
 
 2007-01-01: 1.10
 2007-01-01: 1.10
 	fix in haxe.remoting.SocketConnection.readAnswer
 	fix in haxe.remoting.SocketConnection.readAnswer

+ 2 - 2
genxml.ml

@@ -106,8 +106,8 @@ let gen_type ctx t =
 	let m = Typer.module_of_type ctx t in
 	let m = Typer.module_of_type ctx t in
 	match t with
 	match t with
 	| TClassDecl c ->
 	| TClassDecl c ->
-		let stats = pmap (gen_field ["static","1"]) c.cl_statics in
-		let fields = pmap (gen_field []) c.cl_fields in
+		let stats = List.map (gen_field ["static","1"]) c.cl_ordered_statics in
+		let fields = List.map (gen_field []) c.cl_ordered_fields in
 		let constr = (match c.cl_constructor with None -> [] | Some f -> [gen_field [] f]) in
 		let constr = (match c.cl_constructor with None -> [] | Some f -> [gen_field [] f]) in
 		let impl = List.map (gen_class_path "implements") c.cl_implements in
 		let impl = List.map (gen_class_path "implements") c.cl_implements in
 		let tree = (match c.cl_super with
 		let tree = (match c.cl_super with

+ 2 - 0
type.ml

@@ -123,6 +123,7 @@ and tclass = {
 	mutable cl_fields : (string , tclass_field) PMap.t;
 	mutable cl_fields : (string , tclass_field) PMap.t;
 	mutable cl_statics : (string, tclass_field) PMap.t;
 	mutable cl_statics : (string, tclass_field) PMap.t;
 	mutable cl_ordered_statics : tclass_field list;
 	mutable cl_ordered_statics : tclass_field list;
+	mutable cl_ordered_fields : tclass_field list;
 	mutable cl_dynamic : t option;
 	mutable cl_dynamic : t option;
 	mutable cl_constructor : tclass_field option;
 	mutable cl_constructor : tclass_field option;
 	mutable cl_init : texpr option;
 	mutable cl_init : texpr option;
@@ -202,6 +203,7 @@ let mk_class path pos doc priv =
 		cl_implements = [];
 		cl_implements = [];
 		cl_fields = PMap.empty;
 		cl_fields = PMap.empty;
 		cl_ordered_statics = [];
 		cl_ordered_statics = [];
+		cl_ordered_fields = [];
 		cl_statics = PMap.empty;
 		cl_statics = PMap.empty;
 		cl_dynamic = None;
 		cl_dynamic = None;
 		cl_constructor = None;
 		cl_constructor = None;

+ 2 - 0
typer.ml

@@ -2197,12 +2197,14 @@ let init_class ctx c p herits fields =
 				c.cl_ordered_statics <- f :: c.cl_ordered_statics;
 				c.cl_ordered_statics <- f :: c.cl_ordered_statics;
 			end else begin
 			end else begin
 				c.cl_fields <- PMap.add f.cf_name f c.cl_fields;
 				c.cl_fields <- PMap.add f.cf_name f c.cl_fields;
+				c.cl_ordered_fields <- f :: c.cl_ordered_fields;
 				if List.mem AOverride access then c.cl_overrides <- f.cf_name :: c.cl_overrides;
 				if List.mem AOverride access then c.cl_overrides <- f.cf_name :: c.cl_overrides;
 			end;
 			end;
 		end;
 		end;
 		delayed
 		delayed
 	) fields in
 	) fields in
 	c.cl_ordered_statics <- List.rev c.cl_ordered_statics;
 	c.cl_ordered_statics <- List.rev c.cl_ordered_statics;
+	c.cl_ordered_fields <- List.rev c.cl_ordered_fields;
 	(* define an default inherited constructor *)
 	(* define an default inherited constructor *)
 	(match c.cl_constructor, c.cl_super with
 	(match c.cl_constructor, c.cl_super with
 	| None , Some ({ cl_constructor = Some f; cl_types = tl } as csuper, cparams) ->
 	| None , Some ({ cl_constructor = Some f; cl_types = tl } as csuper, cparams) ->