8184: refine comment style of tests r=Veykril a=hi-rustin

Fix the comment style issues, it's in tests but maybe it's a little better to change it to this.

Co-authored-by: hi-rustin <rustin.liu@gmail.com>
This commit is contained in:
bors[bot] 2021-03-24 11:31:51 +00:00 committed by GitHub
commit 353aa87032
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 48 additions and 48 deletions

View File

@ -204,7 +204,7 @@ mod tests {
if$0 true { if$0 true {
foo(); foo();
//comment // comment
bar(); bar();
} }
} }
@ -217,7 +217,7 @@ mod tests {
} }
foo(); foo();
//comment // comment
bar(); bar();
} }
"#, "#,
@ -234,7 +234,7 @@ mod tests {
if$0 let Some(n) = n { if$0 let Some(n) = n {
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
} }
@ -248,7 +248,7 @@ mod tests {
}; };
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
"#, "#,
@ -288,7 +288,7 @@ mod tests {
if$0 let Some(n) = n { if$0 let Some(n) = n {
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
} }
@ -302,7 +302,7 @@ mod tests {
}; };
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
"#, "#,
@ -319,7 +319,7 @@ mod tests {
if$0 let Some(mut n) = n { if$0 let Some(mut n) = n {
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
} }
@ -333,7 +333,7 @@ mod tests {
}; };
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
"#, "#,
@ -350,7 +350,7 @@ mod tests {
if$0 let Some(ref n) = n { if$0 let Some(ref n) = n {
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
} }
@ -364,7 +364,7 @@ mod tests {
}; };
foo(n); foo(n);
//comment // comment
bar(); bar();
} }
"#, "#,

View File

@ -186,7 +186,7 @@ fn main() {
if true {$0 if true {$0
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -198,7 +198,7 @@ fn main() {
bar(); bar();
foo(); foo();
//comment // comment
bar(); bar();
} }
"#, "#,
@ -215,7 +215,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else {$0 } else {$0
println!("bar"); println!("bar");
@ -228,7 +228,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} }
println!("bar"); println!("bar");
@ -243,12 +243,12 @@ fn main() {
unwrap_block, unwrap_block,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false {$0 } else if false {$0
println!("bar"); println!("bar");
} else { } else {
@ -258,12 +258,12 @@ fn main() {
"#, "#,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} }
println!("bar"); println!("bar");
} }
@ -277,12 +277,12 @@ fn main() {
unwrap_block, unwrap_block,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false { } else if false {
println!("bar"); println!("bar");
} else if true {$0 } else if true {$0
@ -292,12 +292,12 @@ fn main() {
"#, "#,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false { } else if false {
println!("bar"); println!("bar");
} }
@ -313,12 +313,12 @@ fn main() {
unwrap_block, unwrap_block,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false { } else if false {
println!("bar"); println!("bar");
} else if true { } else if true {
@ -330,12 +330,12 @@ fn main() {
"#, "#,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false { } else if false {
println!("bar"); println!("bar");
} else if true { } else if true {
@ -353,12 +353,12 @@ fn main() {
unwrap_block, unwrap_block,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false { } else if false {
println!("bar"); println!("bar");
} else if true {$0 } else if true {$0
@ -370,12 +370,12 @@ fn main() {
"#, "#,
r#" r#"
fn main() { fn main() {
//bar(); // bar();
if true { if true {
println!("true"); println!("true");
//comment // comment
//bar(); // bar();
} else if false { } else if false {
println!("bar"); println!("bar");
} }
@ -395,7 +395,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -415,7 +415,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -428,7 +428,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -448,7 +448,7 @@ fn main() {
if true {$0 if true {$0
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -461,7 +461,7 @@ fn main() {
for i in 0..5 { for i in 0..5 {
foo(); foo();
//comment // comment
bar(); bar();
} }
} }
@ -479,7 +479,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -492,7 +492,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -512,7 +512,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -525,7 +525,7 @@ fn main() {
if true { if true {
foo(); foo();
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");
@ -569,7 +569,7 @@ fn main() {
if true { if true {
foo();$0 foo();$0
//comment // comment
bar(); bar();
} else { } else {
println!("bar"); println!("bar");