Browse Source

fix Class/Enum/Abstract path printing (closes #2807)

Simon Krajewski 11 years ago
parent
commit
c1180fc08c
2 changed files with 3 additions and 3 deletions
  1. 1 1
      typeload.ml
  2. 2 2
      typer.ml

+ 1 - 1
typeload.ml

@@ -77,7 +77,7 @@ let make_module ctx mpath file tdecls loadp =
 				e_constrs = PMap.empty;
 				e_constrs = PMap.empty;
 				e_names = [];
 				e_names = [];
 				e_type = {
 				e_type = {
-					t_path = fst path, "Enum<" ^ (snd path) ^ ">";
+					t_path = [], "Enum<" ^ (s_type_path path) ^ ">";
 					t_module = m;
 					t_module = m;
 					t_doc = None;
 					t_doc = None;
 					t_pos = p;
 					t_pos = p;

+ 2 - 2
typer.ml

@@ -617,7 +617,7 @@ let rec type_module_type ctx t tparams p =
 	match t with
 	match t with
 	| TClassDecl c ->
 	| TClassDecl c ->
 		let t_tmp = {
 		let t_tmp = {
-			t_path = fst c.cl_path, "Class<" ^ (snd c.cl_path) ^ ">" ;
+			t_path = [],"Class<" ^ (s_type_path c.cl_path) ^ ">" ;
 			t_module = c.cl_module;
 			t_module = c.cl_module;
 			t_doc = None;
 			t_doc = None;
 			t_pos = c.cl_pos;
 			t_pos = c.cl_pos;
@@ -649,7 +649,7 @@ let rec type_module_type ctx t tparams p =
 	| TAbstractDecl a ->
 	| TAbstractDecl a ->
 		if not (Meta.has Meta.RuntimeValue a.a_meta) then error (s_type_path a.a_path ^ " is not a value") p;
 		if not (Meta.has Meta.RuntimeValue a.a_meta) then error (s_type_path a.a_path ^ " is not a value") p;
 		let t_tmp = {
 		let t_tmp = {
-			t_path = fst a.a_path, "Abstract<" ^ (snd a.a_path) ^ ">";
+			t_path = [],"Abstract<" ^ (s_type_path a.a_path) ^ ">";
 			t_module = a.a_module;
 			t_module = a.a_module;
 			t_doc = None;
 			t_doc = None;
 			t_pos = a.a_pos;
 			t_pos = a.a_pos;