Uh oh!
There was an error while loading. Please reload this page.
Add test for #5239 - #8800
Closed
fhahn wants to merge 1 commit into
Closed
Conversation
alexcrichton
commented
Aug 28, 2013
Member
Could you add Also, I think you can remove the comment about it being a "bogus ref" because it's a legitimate way to write a pattern binding. I think that it'd also be a good idea to add a test for the original code as well as compile-fail, thanks! |
fhahn
commented
Aug 28, 2013
ContributorAuthor
I've added a compile-fail test and updated the commit message. |
catamorphism
commented
Aug 28, 2013
Contributor
Looks like the same problem as #8458 |
bors added a commit
that referenced
this pull request
Aug 29, 2013
I've added a test for the second example mentioned in #5239. The first example does not compile with a reasonable error message. Should I add a compile-fail test for that example as well? /rust/src/test/run-pass/issue-5239.rs:15:45: 15:51 error: binary operation + cannot be applied to type `&int` rust/src/test/run-pass/issue-5239.rs:15 let _f = |ref x: int| { x += 1}; ^~~~~~ error: aborting due to previous error
flip1995 pushed a commit
to flip1995/rust
that referenced
this pull request
Jun 30, 2022
…, r=Manishearth add vec.capacity() to [`slow_vec_initialization`] detection fixrust-lang#8800 for example ```rust let mut vec1 = Vec::with_capacity(len); vec1.resize(vec1.capacity(), 0); let mut vec2 = Vec::with_capacity(len); vec2.extend(repeat(0).take(vec2.capacity())); ``` will trigger the lint --- changelog: add `vec.capacity()` to [`slow_vec_initialization`] detection
U007D pushed a commit
to U007D/rust-mos
that referenced
this pull request
Aug 21, 2026
8800: feat: Make "pull assignments up" assist work in more cases r=Jesse-Bakker a=Jesse-Bakker Fixesrust-lang#8771 Co-authored-by: Jesse Bakker <github@jessebakker.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I've added a test for the second example mentioned in #5239. The first example does not compile with a reasonable error message. Should I add a compile-fail test for that example as well?