Skip to content

fix: disallow &mut (*x) when x is not a mutable reference - #13447

Open
asterite wants to merge 2 commits into
masterfrom
ab/ownership-clone-ref-to-array-index
Open

fix: disallow &mut (*x) when x is not a mutable reference#13447
asterite wants to merge 2 commits into
masterfrom
ab/ownership-clone-ref-to-array-index

Conversation

@asterite

@asterite asterite commented Aug 3, 2026

Copy link
Copy Markdown
Collaborator

Problem Resolved

Resolves https://github.com/noir-lang/noir-claude/issues/1562

Summary of Changes

The bug happened because we previously allowed &mut (*x) to be done even if x was not a mutable reference. This now behaves the same way as in Rust.

User Documentation

Check one:

  • No user documentation needed.
  • Documented in docs/.
  • [For Experimental Features] Documentation tracking issue created:

PR Checklist

  • I have tested the changes locally.
  • I have formatted the changes with Prettier and/or cargo fmt on default settings.

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

Successfully merging this pull request may close these issues.

1 participant