Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

beam_validator: Use set_aliased_type in more operations #1960

Conversation

jhogberg
Copy link
Contributor

hd/1 and friends only tracked types for their direct inputs, failing validation for legal code that used an aliased register.

https://bugs.erlang.org/browse/ERL-735

The following code broke because aliases weren't tracked for hd/1:

bug(Bool) ->
    Bug = remote:call(),
    if
        Bool -> %% Branch of some kind.
            _ = hd(Bug),
            remote:call(),
            hd(Bug)
    end.

Related to 1f221b2
@jhogberg jhogberg merged commit 08ef38b into erlang:master Sep 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant