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

CompilerPanic for concat on empty(Bytes) #3986

Open
cyberthirst opened this issue May 1, 2024 · 0 comments
Open

CompilerPanic for concat on empty(Bytes) #3986

cyberthirst opened this issue May 1, 2024 · 0 comments

Comments

@cyberthirst
Copy link
Collaborator

Version Information

  • vyper Version (output of vyper --version OR linkable commit hash vyperlang/vyper@commitish): 0.4.0rc3+commit.80708e6d

Issue description

Certain contracts which contain empty and concat fail to compile with CompilerPanic.

POC

These contracts

#@version 0.4.0.rc3

@external
def foo():
    s: Bytes[63] = concat(empty(Bytes[31]), empty(bytes32))
#@version 0.4.0.rc3

@external
def foo():
    s: Bytes[63] = concat(empty(Bytes[31]), b"a")

fail to compile with:

vyper.exceptions.CompilerPanic: tried to modify non-pointer type

credits: @trocher

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

No branches or pull requests

1 participant