Browse Source

Merge branch 'development' into hxb_server_cache_simn_cleanup

Simon Krajewski 1 year ago
parent
commit
1bcbc35cc4
4 changed files with 15 additions and 13 deletions
  1. 1 0
      extra/release-checklist.txt
  2. 11 9
      src/compiler/compiler.ml
  3. 3 3
      src/core/classPaths.ml
  4. 0 1
      std/haxe/ValueException.hx

+ 1 - 0
extra/release-checklist.txt

@@ -23,6 +23,7 @@
 	- If everything was working, run the command again without `--dry`
 - Update https://github.com/HaxeFoundation/haxe.org/blob/staging/downloads/versions.json
 - Wait for staging to update, check everything related to release and merge to master
+- Update https://github.com/HaxeFoundation/api.haxe.org/blob/master/theme/templates/topbar.mtt
 
 # Cleanup
 

+ 11 - 9
src/compiler/compiler.ml

@@ -206,7 +206,7 @@ module Setup = struct
 					l
 			in
 			let parts = Str.split_delim (Str.regexp "[;:]") p in
-			List.map (fun s -> Path.add_trailing_slash s,Std) (loop parts)
+			List.map (fun s -> s,Std) (loop parts)
 		with Not_found ->
 			let base_path = Path.get_real_path (try executable_path() with _ -> "./") in
 			if Sys.os_type = "Unix" then
@@ -214,21 +214,23 @@ module Setup = struct
 				let lib_path = Filename.concat prefix_path "lib" in
 				let share_path = Filename.concat prefix_path "share" in
 				[
-					(Path.add_trailing_slash (Filename.concat share_path "haxe/std"),Std);
-					(Path.add_trailing_slash (Filename.concat lib_path "haxe/std"),Std);
-					(Path.add_trailing_slash (Filename.concat base_path "std"),Std);
+					(Filename.concat share_path "haxe/std"),Std;
+					(Filename.concat lib_path "haxe/std"),Std;
+					(Filename.concat base_path "std"),Std;
 				]
 			else
 				[
-					(Path.add_trailing_slash (Filename.concat base_path "std"),Std);
+					(Filename.concat base_path "std"),Std;
 				]
 
 	let init_std_class_paths com =
-		com.class_paths#add com.empty_class_path;
 		List.iter (fun (s,scope) ->
-			let cp = new ClassPath.directory_class_path s scope in
-			com.class_paths#add cp
-		) (List.rev (get_std_class_paths ()))
+			try if Sys.is_directory s then
+				let cp = new ClassPath.directory_class_path (Path.add_trailing_slash s) scope in
+				com.class_paths#add cp
+			with Sys_error _ -> ()
+		) (List.rev (get_std_class_paths ()));
+		com.class_paths#add com.empty_class_path
 
 	let setup_common_context ctx =
 		let com = ctx.com in

+ 3 - 3
src/core/classPaths.ml

@@ -27,11 +27,11 @@ class class_paths = object(self)
 
 	method add (cp : class_path) =
 		l <- cp :: l;
-		file_lookup_cache#clear
+		self#clear_cache
 
 	method push (cp : class_path) =
 		l <- l @ [cp];
-		file_lookup_cache#clear
+		self#clear_cache
 
 	method find (f : class_path -> bool) =
 		List.find f l
@@ -54,7 +54,7 @@ class class_paths = object(self)
 				loop (cpl @ acc) l
 		in
 		l <- loop [] cpl;
-		file_lookup_cache#clear
+		self#clear_cache
 
 	method modify_inplace (f : class_path -> class_path list) =
 		self#modify f l

+ 0 - 1
std/haxe/ValueException.hx

@@ -18,7 +18,6 @@ class ValueException extends Exception {
 	/**
 		Thrown value.
 	**/
-	@:keep
 	public var value(default, null):Any;
 
 	public function new(value:Any, ?previous:Exception, ?native:Any):Void {