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

ERL-997: Valid code fails to compile with +no_type_opt #3794

Closed
OTP-Maintainer opened this issue Jul 9, 2019 · 2 comments
Closed

ERL-997: Valid code fails to compile with +no_type_opt #3794

OTP-Maintainer opened this issue Jul 9, 2019 · 2 comments
Assignees
Labels
bug Issue is reported as a bug priority:low team:VM Assigned to OTP team VM
Milestone

Comments

@OTP-Maintainer
Copy link

Original reporter: josevalim
Affected version: OTP-22.0
Fixed in version: OTP-22.1
Component: compiler
Migrated from: https://bugs.erlang.org/browse/ERL-997


Given this module:

{code:erlang}
-module(foo).
-compile(export_all).

foo() ->
  try
    InsertedAt = true,
    UpdatedAt = true,

    case InsertedAt of
      true -> io:format("foo");
      false ->
        case UpdatedAt of
          true -> io:format("bar");
          false -> io:format("bat")
        end
    end
  after
    ok
  end.
{code}

It compiles with  "erlc foo.erl" but not with "erlc +no_type_opt foo.erl". I have verified the bug on OTP 22 and master.
@OTP-Maintainer
Copy link
Author

john said:

Thanks for your report, we'll fix it after summer vacations.

@OTP-Maintainer
Copy link
Author

bjorn said:

https://github.com/erlang/otp/pull/2334

@OTP-Maintainer OTP-Maintainer added bug Issue is reported as a bug team:VM Assigned to OTP team VM priority:low labels Feb 10, 2021
@OTP-Maintainer OTP-Maintainer added this to the OTP-22.1 milestone Feb 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue is reported as a bug priority:low team:VM Assigned to OTP team VM
Projects
None yet
Development

No branches or pull requests

2 participants