Przeglądaj źródła

[display] change something about toplevel paths again

I don't know anymore, ask @Gama11
Simon Krajewski 7 lat temu
rodzic
commit
a6081c3b28
1 zmienionych plików z 3 dodań i 1 usunięć
  1. 3 1
      src/compiler/displayOutput.ml

+ 3 - 1
src/compiler/displayOutput.ml

@@ -85,7 +85,9 @@ let print_toplevel il =
 		| IdentifierType.ITType(mt,rm) ->
 			let infos = t_infos mt in
 			let import,name = match rm with
-				| IdentifierType.RMOtherModule path -> Printf.sprintf " import=\"%s\"" (s_type_path path),s_type_path infos.mt_path
+				| IdentifierType.RMOtherModule path ->
+					let label_path = if path = infos.mt_path then path else (fst path @ [snd path],snd infos.mt_path) in
+					Printf.sprintf " import=\"%s\"" (s_type_path path),s_type_path label_path
 				| _ -> "",(snd infos.mt_path)
 			in
 			Buffer.add_string b (Printf.sprintf "<i k=\"type\" p=\"%s\"%s%s>%s</i>\n" (s_type_path infos.mt_path) import ("") name);