Sfoglia il codice sorgente

minor completion optimization

Nicolas Cannasse 14 anni fa
parent
commit
7c28e8cc5e
1 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 2 0
      main.ml

+ 2 - 0
main.ml

@@ -559,6 +559,8 @@ try
 		| Php -> add_std "php"; "php"
 		| Cpp -> add_std "cpp"; "cpp"
 	) in
+	(* if we are at the last compilation step, allow all packages accesses - in case of macros or opening another project file *)
+	if com.display && not has_next then com.package_rules <- PMap.foldi (fun p r acc -> match r with Forbidden -> acc | _ -> PMap.add p r acc) com.package_rules PMap.empty;
 
 	(* check file extension. In case of wrong commandline, we don't want
 		to accidentaly delete a source file. *)