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

Bit shifting produces incorrect code #2288

Closed
jfecher opened this issue Aug 11, 2023 · 1 comment
Closed

Bit shifting produces incorrect code #2288

jfecher opened this issue Aug 11, 2023 · 1 comment
Assignees
Labels
bug Something isn't working ssa

Comments

@jfecher
Copy link
Contributor

jfecher commented Aug 11, 2023

Aim

fn main() {
    let c: u64 = -1 as u64;
    dep::std::println(c >> 32);
}

Expected Behavior

4294967295

Bug

Actual output is 10229803320271304084

To Reproduce

Installation Method

None

Nargo Version

No response

Additional Context

No response

Would you like to submit a PR for this Issue?

No

Support Needs

No response

@jfecher jfecher added bug Something isn't working ssa P-HIGH labels Aug 11, 2023
@github-project-automation github-project-automation bot moved this to 📋 Backlog in Noir Aug 11, 2023
@jfecher
Copy link
Contributor Author

jfecher commented Aug 11, 2023

Nevermind, I had some local changes for #2250 which affected codegen here. Closing.

@jfecher jfecher closed this as completed Aug 11, 2023
@github-project-automation github-project-automation bot moved this from 📋 Backlog to ✅ Done in Noir Aug 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working ssa
Projects
Archived in project
Development

No branches or pull requests

2 participants