Selaa lähdekoodia

case insensitive filename matching for completion

Nicolas Cannasse 15 vuotta sitten
vanhempi
commit
21ef0631d7
2 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 1 1
      main.ml
  2. 1 1
      parser.ml

+ 1 - 1
main.ml

@@ -414,7 +414,7 @@ try
 				let pos = try int_of_string pos with _ -> failwith ("Invalid format : "  ^ pos) in
 				Common.display := true;
 				Parser.resume_display := {
-					Ast.pfile = Common.get_full_path file;
+					Ast.pfile = String.lowercase (Common.get_full_path file);
 					Ast.pmin = pos;
 					Ast.pmax = pos;
 				};

+ 1 - 1
parser.ml

@@ -58,7 +58,7 @@ let display e = raise (Display e)
 
 let is_resuming p =
 	let p2 = !resume_display in
-	p.pmax = p2.pmin && Common.get_full_path p.pfile = p2.pfile
+	p.pmax = p2.pmin && String.lowercase (Common.get_full_path p.pfile) = p2.pfile
 
 let priority = function
 	| OpAssign | OpAssignOp _ -> -4