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

Accessing non-existent field in constructor causes failed assertion #1932

Closed
plietar opened this issue May 30, 2017 · 0 comments · Fixed by #1941
Closed

Accessing non-existent field in constructor causes failed assertion #1932

plietar opened this issue May 30, 2017 · 0 comments · Fixed by #1941
Assignees

Comments

@plietar
Copy link
Contributor

plietar commented May 30, 2017

actor Main
    new create(env: Env) =>
        this.x = None
Building builtin -> /Users/paul/Projects/ponyc/packages/builtin
Building . -> /private/tmp/a
src/libponyc/pass/refer.c:636: is_lvalue: Assertion `def != NULL` failed.

Backtrace:
  0   ponyc                               0x000000010ed61a41 ponyint_assert_fail + 161
  1   ponyc                               0x000000010ed5b190 is_lvalue + 560
  2   ponyc                               0x000000010ed59470 refer_assign + 176
  3   ponyc                               0x000000010ed58f15 pass_refer + 165
  4   ponyc                               0x000000010ed1b20d ast_visit + 685
  5   ponyc                               0x000000010ed1b144 ast_visit + 484
  6   ponyc                               0x000000010ed1b144 ast_visit + 484
  7   ponyc                               0x000000010ed1b144 ast_visit + 484
  8   ponyc                               0x000000010ed1b144 ast_visit + 484
  9   ponyc                               0x000000010ed1b144 ast_visit + 484
  10  ponyc                               0x000000010ed1b144 ast_visit + 484
  11  ponyc                               0x000000010ed1b144 ast_visit + 484
  12  ponyc                               0x000000010ed1bb0c visit_pass + 156
  13  ponyc                               0x000000010ed1b5bf ast_passes + 671
  14  ponyc                               0x000000010ed1b315 ast_passes_program + 37
  15  ponyc                               0x000000010ed388ae program_load + 190
  16  ponyc                               0x000000010ec7dc1f compile_package + 47
  17  ponyc                               0x000000010ec7da50 main + 1120
  18  libdyld.dylib                       0x00007fff8f773255 start + 1
  19  ???                                 0x0000000000000001 0x0 + 1

cc @jemc, this seems related to ##1715 and #1867.

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 a pull request may close this issue.

2 participants