Skip to content

Commit

Permalink
[hxb] delay to PForce pass
Browse files Browse the repository at this point in the history
  • Loading branch information
kLabz committed Dec 13, 2024
1 parent 02e32e7 commit ff52375
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion src/compiler/server.ml
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,6 @@ class hxb_reader_api_server

method make_lazy_type t f =
let r = make_unforced_lazy t f "server-api" in
(* TODO: This should probably use the PForce pass, not PConnectField *)
delay (fun () -> ignore(lazy_type r));
TLazy r
end
Expand Down
2 changes: 1 addition & 1 deletion src/context/display/displayTexpr.ml
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ let check_display_file ctx cs =
let m = try
ctx.com.module_lut#find path
with Not_found ->
begin match !TypeloadCacheHook.type_module_hook ctx.com (delay ctx.g PConnectField) path null_pos with
begin match !TypeloadCacheHook.type_module_hook ctx.com (delay ctx.g PForce) path null_pos with
| NoModule | BadModule _ -> raise Not_found
| BinaryModule mc ->
let api = (new TypeloadModule.hxb_reader_api_typeload ctx.com ctx.g TypeloadModule.load_module' p :> HxbReaderApi.hxb_reader_api) in
Expand Down
2 changes: 1 addition & 1 deletion src/typing/typeloadModule.ml
Original file line number Diff line number Diff line change
Expand Up @@ -813,7 +813,7 @@ and load_module' com g m p =
com.module_lut#find m
with Not_found ->
(* Check cache *)
match !TypeloadCacheHook.type_module_hook com (delay g PConnectField) m p with
match !TypeloadCacheHook.type_module_hook com (delay g PForce) m p with
| GoodModule m ->
m
| BinaryModule _ ->
Expand Down

0 comments on commit ff52375

Please sign in to comment.