]> git.lizzy.rs Git - rust.git/blobdiff - src/missed_spans.rs
Try "overflowing" the final function argument when it's a closure
[rust.git] / src / missed_spans.rs
index 5c5565c65969e25acd99ab5c918df42de49c73f5..f33b7a3014f3fc23cc152e47b123e6a7e7450e1a 100644 (file)
@@ -22,16 +22,15 @@ pub fn format_missing(&mut self, end: BytePos) {
 
     pub fn format_missing_with_indent(&mut self, end: BytePos) {
         let config = self.config;
-        self.format_missing_inner(end,
-                                  |this, last_snippet, snippet| {
-                                      this.buffer.push_str(last_snippet.trim_right());
-                                      if last_snippet == snippet {
-                                          // No new lines in the snippet.
-                                          this.buffer.push_str("\n");
-                                      }
-                                      let indent = this.block_indent.to_string(config);
-                                      this.buffer.push_str(&indent);
-                                  })
+        self.format_missing_inner(end, |this, last_snippet, snippet| {
+            this.buffer.push_str(last_snippet.trim_right());
+            if last_snippet == snippet {
+                // No new lines in the snippet.
+                this.buffer.push_str("\n");
+            }
+            let indent = this.block_indent.to_string(config);
+            this.buffer.push_str(&indent);
+        })
     }
 
     fn format_missing_inner<F: Fn(&mut FmtVisitor, &str, &str)>(&mut self,