-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
[Bug][Compiler-v2] mutability mismatch of reference (&mut != &) in equality expression #11738
Labels
bug
Something isn't working
compiler-v2
stale-exempt
Prevents issues from being automatically marked and closed as stale
Comments
rahxephon89
added
bug
Something isn't working
stale-exempt
Prevents issues from being automatically marked and closed as stale
compiler-v2
labels
Jan 23, 2024
wrwg
added a commit
that referenced
this issue
Feb 22, 2024
This enables the comparison of references with mixed mutability (`&x == &mut y`), and introduces generation of the `FreezeRef` operation when an argument is widned from mutable to immutable references. The later applies for any kind of function call, not only equalities. Without freeze, certain scenarios produce borrow errors in reference safety and/or the bytecode verifier. Note that this PR is intended to work together with the new reference safety analysis, so some tests do not yet work without it. Fixes #12151 Fixes #11738 Fixes #11434
wrwg
added a commit
that referenced
this issue
Feb 26, 2024
This enables the comparison of references with mixed mutability (`&x == &mut y`), and introduces generation of the `FreezeRef` operation when an argument is widned from mutable to immutable references. The later applies for any kind of function call, not only equalities. Without freeze, certain scenarios produce borrow errors in reference safety and/or the bytecode verifier. Note that this PR is intended to work together with the new reference safety analysis, so some tests do not yet work without it. Fixes #12151 Fixes #11738 Fixes #11434
wrwg
added a commit
that referenced
this issue
Feb 26, 2024
This enables the comparison of references with mixed mutability (`&x == &mut y`), and introduces generation of the `FreezeRef` operation when an argument is widned from mutable to immutable references. The later applies for any kind of function call, not only equalities. Without freeze, certain scenarios produce borrow errors in reference safety and/or the bytecode verifier. Note that this PR is intended to work together with the new reference safety analysis, so some tests do not yet work without it. Fixes #12151 Fixes #11738 Fixes #11434
wrwg
added a commit
that referenced
this issue
Feb 26, 2024
This enables the comparison of references with mixed mutability (`&x == &mut y`), and introduces generation of the `FreezeRef` operation when an argument is widned from mutable to immutable references. The later applies for any kind of function call, not only equalities. Without freeze, certain scenarios produce borrow errors in reference safety and/or the bytecode verifier. Note that this PR is intended to work together with the new reference safety analysis, so some tests do not yet work without it. Fixes #12151 Fixes #11738 Fixes #11434
wrwg
added a commit
that referenced
this issue
Feb 27, 2024
This enables the comparison of references with mixed mutability (`&x == &mut y`), and introduces generation of the `FreezeRef` operation when an argument is widned from mutable to immutable references. The later applies for any kind of function call, not only equalities. Without freeze, certain scenarios produce borrow errors in reference safety and/or the bytecode verifier. Note that this PR is intended to work together with the new reference safety analysis, so some tests do not yet work without it. Fixes #12151 Fixes #11738 Fixes #11434
github-project-automation
bot
moved this from 🆕 New
to ✅ Done
in Move Language and Runtime
Feb 27, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug
Something isn't working
compiler-v2
stale-exempt
Prevents issues from being automatically marked and closed as stale
🐛 Bug
When compiling the following code:
The following error will be generated:
Same issues happens when compiling experimental package in third_party/move/documentation/examples/diem-framework/move-packages/experimental using V2:
The text was updated successfully, but these errors were encountered: