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

The result of converting true to uint does not match the behavior in solc. #1743

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

Comments

@Subway2023
Copy link

Version: v0.3.3: Atlantis

contract C {
    function f() public returns (uint x) {
        assembly {
            x := true
        }
    }
}

Reproduction: I set up a Solang compilation and execution environment to test the program.

solang/target/debug/vmRunNoPara test.sol C f

The execution result from solang+svm:

0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff

The execution result from solc+evm(remix):

0x0000000000000000000000000000000000000000000000000000000000000001
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