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

Unwrapping a user-defined type causes compilation crash. #1722

Open
Subway2023 opened this issue Feb 8, 2025 · 0 comments
Open

Unwrapping a user-defined type causes compilation crash. #1722

Subway2023 opened this issue Feb 8, 2025 · 0 comments

Comments

@Subway2023
Copy link

Version: v0.3.3: Atlantis

type MyUInt8 is uint8;

contract C {
    function j(MyUInt8 a) external returns (uint) {
        return MyUInt8.unwrap(a);
    }
}
solang compile --target solana test.sol

thread 'main' panicked at 'assertion failed: `(left == right)`
  left: `1`,
 right: `32`', src/emit/expression.rs:1933:13
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
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