This commit is contained in:
Craig Everett 2025-08-15 13:24:39 +09:00
parent 5ebb532b86
commit 2ecde986bf

View File

@ -837,9 +837,9 @@ open_hash3(State, Address, Source) ->
% TODO: Compile on load and verify the deployed hash for validity.
Options = sophia_options(),
case so_compiler:from_string(Source, Options) of
{ok, Build} ->
AACI = hz:prepare_aaci(Build),
{Defs = #{functions := Funs}, ConIfaces} = find_main(AACI),
{ok, Build = #{aci := ACI}} ->
% AACI = hz:prepare_aaci(ACI),
{Defs = #{functions := Funs}, ConIfaces} = find_main(ACI),
Callable = maps:remove("init", Funs),
FunDefs = {maps:put(functions, Callable, Defs), ConIfaces},
ok = tell(info, "Compilation Succeeded!~n~tp~n~n~tp", [Build, FunDefs]),