Merge pull request #1325 from C4K3/master
Add error_on_line_overflow option
This commit is contained in:
commit
db10a0b9b2
27 changed files with 36 additions and 7 deletions
|
@ -18,7 +18,7 @@ fn test() {
|
|||
* amet, consectetur adipiscing elit. Aenean ut gravida lorem. Ut turpis
|
||||
* felis, pulvinar a semper sed, adipiscing id dolor. */
|
||||
|
||||
// Very looooooooooooooooooooooooooooooooooooooooooooooooooooooooong comment that should be split
|
||||
// Very loooooooooooooooooooooooooooooooooooooooooooooooooooooooong comment that should be split
|
||||
|
||||
// println!("{:?}", rewrite_comment(subslice,
|
||||
// false,
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
// rustfmt-wrap_comments: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
// Enums test
|
||||
|
||||
#[atrr]
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
// rustfmt-file_lines: [{"file":"tests/source/file-lines-3.rs","range":[4,8]},{"file":"tests/source/file-lines-3.rs","range":[10,15]}]
|
||||
// rustfmt-file_lines: [{"file":"tests/source/file-lines-3.rs","range":[5,9]},{"file":"tests/source/file-lines-3.rs","range":[11,16]}]
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
fn floaters() {
|
||||
let x = Foo {
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// rustfmt-single_line_if_else_max_width: 0
|
||||
// rustfmt-wrap_comments: true
|
||||
// rustfmt-hard_tabs: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
fn main() {
|
||||
let x = Bar;
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
// rustfmt-normalize_comments: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
// Imports.
|
||||
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
mod client {
|
||||
impl Client {
|
||||
fn test(self) -> Result<()> {
|
||||
|
@ -10,7 +12,7 @@ mod client {
|
|||
let next_state = match self.state {
|
||||
State::V5(v5::State::Command(v5::comand::State::WriteVersion(ref mut response))) => {
|
||||
// The pattern cannot be formatted in a way that the match stays
|
||||
// within the column limit. The rewrite should therefore be
|
||||
// within the column limit. The rewrite should therefore be
|
||||
// skipped.
|
||||
let x = dont . reformat . meeee();
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
// rustfmt-force_format_strings: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
// Long string literals
|
||||
|
||||
fn main() -> &'static str {
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
// rustfmt-format_strings: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
fn main() {
|
||||
println!("ThisIsAReallyLongStringWithNoSpaces.It_should_prefer_to_break_onpunctuation:Likethisssssssssssss");
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
// rustfmt-normalize_comments: true
|
||||
// rustfmt-wrap_comments: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
// Struct literal expressions.
|
||||
|
||||
fn main() {
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
// rustfmt-normalize_comments: true
|
||||
// rustfmt-wrap_comments: true
|
||||
// rustfmt-struct_lit_style: Visual
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
// Struct literal expressions.
|
||||
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
// rustfmt-wrap_comments: true
|
||||
// rustfmt-struct_lit_style: Visual
|
||||
// rustfmt-struct_lit_multiline_style: ForceMulti
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
// Struct literal expressions.
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
// rustfmt-normalize_comments: true
|
||||
// rustfmt-wrap_comments: true
|
||||
// rustfmt-error_on_line_overflow: false
|
||||
|
||||
/// A Doc comment
|
||||
#[AnAttribute]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue