Skip to content

Commit

Permalink
Fix bugs caused by the addition of debugging symbols (#464)
Browse files Browse the repository at this point in the history
* Fix get_catchalls bug

* Fix for event datatype
  • Loading branch information
ghallak authored Jun 28, 2023
1 parent b902226 commit c15d411
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/aeso_ast_to_fcode.erl
Original file line number Diff line number Diff line change
Expand Up @@ -1262,7 +1262,7 @@ event_function(_Env = #{event_type := {variant_t, EventCons}}, EventType = {vari
end,
Indices = [ {var, [], V} || {indexed, V} <- IVars ],
Body = {builtin, [], chain_event, [Payload, Hash | Indices]},
{'case', {con, [], Arities, Tag, Vars}, {nosplit, [], Body}}
{'case', {con, Arities, Tag, Vars}, {nosplit, [], Body}}
end,
#{ attrs => [private],
args => [{"e", EventType}],
Expand Down Expand Up @@ -1580,7 +1580,7 @@ simpl_proj(Env, I, Expr) ->

-spec get_catchalls([fcase()]) -> [fcase()].
get_catchalls(Alts) ->
[ C || C = {'case', {var, _, _}, _} <- Alts ].
[ C || C = {'case', {var, _}, _} <- Alts ].

%% The scode compiler can't handle multiple catch-alls, so we need to nest them
%% inside each other. Instead of
Expand Down

0 comments on commit c15d411

Please sign in to comment.