Skip to content

fix: Make Vec::get accept immutable Vecs#2776

Merged
TomAFrench merged 1 commit intomasterfrom
jf/immutable-vec-get
Sep 21, 2023
Merged

fix: Make Vec::get accept immutable Vecs#2776
TomAFrench merged 1 commit intomasterfrom
jf/immutable-vec-get

Conversation

@jfecher
Copy link
Contributor

@jfecher jfecher commented Sep 21, 2023

Description

Problem*

Resolves #2775

Summary*

Vec::get used to require a mutable Vec since we did not automatically dereference &mut T -> T for objects of method calls before PR #2581. Now that this PR is merged, it can be immutable.

Documentation

  • This PR requires documentation updates when merged.

    • I will submit a noir-lang/docs PR.
    • I will request for and support Dev Rel's help in documenting this PR.
      • The type signature of Vec::get will need to be updated

Additional Context

PR Checklist*

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

@TomAFrench TomAFrench added this pull request to the merge queue Sep 21, 2023
Merged via the queue into master with commit f168a54 Sep 21, 2023
@TomAFrench TomAFrench deleted the jf/immutable-vec-get branch September 21, 2023 14:51
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.

Vec::get requires a mutable Vec

2 participants