Update tests
This commit is contained in:
parent
eb828ed9ff
commit
25bf1741b2
@ -1,6 +1,19 @@
|
||||
// rustfmt-wrap_comments: true
|
||||
// Test attributes and doc comments are preserved.
|
||||
|
||||
//! Doc comment
|
||||
|
||||
#![attribute]
|
||||
|
||||
//! Crate doc comment
|
||||
|
||||
// Comment
|
||||
|
||||
// Comment on attribute
|
||||
#![the(attribute)]
|
||||
|
||||
// Another comment
|
||||
|
||||
#[invalid attribute]
|
||||
fn foo() {}
|
||||
|
||||
|
@ -53,3 +53,7 @@ trait Ttttttttttttttttttttttttttttttttttttttttttttttttttttttttttt<T> where T: Fo
|
||||
|
||||
trait WhereList<T, J> where T: Foo, J: Bar {}
|
||||
|
||||
trait X /* comment */ {}
|
||||
trait Y // comment
|
||||
{
|
||||
}
|
||||
|
@ -1,6 +1,19 @@
|
||||
// rustfmt-wrap_comments: true
|
||||
// Test attributes and doc comments are preserved.
|
||||
|
||||
//! Doc comment
|
||||
|
||||
#![attribute]
|
||||
|
||||
//! Crate doc comment
|
||||
|
||||
// Comment
|
||||
|
||||
// Comment on attribute
|
||||
#![the(attribute)]
|
||||
|
||||
// Another comment
|
||||
|
||||
#[invalid attribute]
|
||||
fn foo() {}
|
||||
|
||||
@ -33,11 +46,12 @@ pub fn f2(self) {
|
||||
fn f3(self) -> Dog {}
|
||||
|
||||
/// Blah blah bing.
|
||||
|
||||
#[attrib1]
|
||||
/// Blah blah bing.
|
||||
#[attrib2]
|
||||
// Another comment that needs rewrite because it's
|
||||
// tooooooooooooooooooooooooooooooo loooooooooooong.
|
||||
// Another comment that needs rewrite because it's tooooooooooooooooooooooooooooooo
|
||||
// loooooooooooong.
|
||||
/// Blah blah bing.
|
||||
fn f4(self) -> Cat {}
|
||||
|
||||
|
@ -83,6 +83,7 @@ fn some_fn3() // some comment some comment some comment some comment some commen
|
||||
}
|
||||
|
||||
fn some_fn4()
|
||||
// some comment some comment some comment some comment some comment some comment some comment
|
||||
// some comment some comment some comment some comment some comment some comment
|
||||
// some comment
|
||||
{
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
#![allow(dead_code)]
|
||||
// bar
|
||||
#![allow(dead_code)] // bar
|
||||
|
||||
//! Doc comment
|
||||
fn test() {
|
||||
// comment
|
||||
|
@ -18,6 +18,11 @@ pub fn new(value: V) -> Self {
|
||||
}
|
||||
}
|
||||
|
||||
impl X<T> /* comment */ {}
|
||||
impl Y<T> // comment
|
||||
{
|
||||
}
|
||||
|
||||
impl<T> Foo for T
|
||||
// comment1
|
||||
where
|
||||
|
@ -79,3 +79,8 @@ trait WhereList<T, J>
|
||||
J: Bar,
|
||||
{
|
||||
}
|
||||
|
||||
trait X /* comment */ {}
|
||||
trait Y // comment
|
||||
{
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user