mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-10 15:14:29 +00:00
Apply review suggestion
Co-authored-by: Fridtjof Stoldt <xFrednet@gmail.com>
This commit is contained in:
parent
c6cc160ec6
commit
e63061d75b
2 changed files with 2 additions and 2 deletions
|
@ -336,7 +336,7 @@ fn main() {
|
||||||
{
|
{
|
||||||
fn takes_writer<T: std::io::Write>(_: T) {}
|
fn takes_writer<T: std::io::Write>(_: T) {}
|
||||||
|
|
||||||
fn f(mut buffer: &mut Vec<u8>) {
|
fn issue_12856(mut buffer: &mut Vec<u8>) {
|
||||||
takes_writer(&mut buffer); // Don't lint, would make buffer unavailable later
|
takes_writer(&mut buffer); // Don't lint, would make buffer unavailable later
|
||||||
buffer.extend(b"\n");
|
buffer.extend(b"\n");
|
||||||
}
|
}
|
||||||
|
|
|
@ -336,7 +336,7 @@ fn main() {
|
||||||
{
|
{
|
||||||
fn takes_writer<T: std::io::Write>(_: T) {}
|
fn takes_writer<T: std::io::Write>(_: T) {}
|
||||||
|
|
||||||
fn f(mut buffer: &mut Vec<u8>) {
|
fn issue_12856(mut buffer: &mut Vec<u8>) {
|
||||||
takes_writer(&mut buffer); // Don't lint, would make buffer unavailable later
|
takes_writer(&mut buffer); // Don't lint, would make buffer unavailable later
|
||||||
buffer.extend(b"\n");
|
buffer.extend(b"\n");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue