summaryrefslogtreecommitdiffstats
path: root/src/tools/rustfmt/tests/source/issue-1049.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/rustfmt/tests/source/issue-1049.rs')
-rw-r--r--src/tools/rustfmt/tests/source/issue-1049.rs18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/tools/rustfmt/tests/source/issue-1049.rs b/src/tools/rustfmt/tests/source/issue-1049.rs
new file mode 100644
index 000000000..bcfba41e7
--- /dev/null
+++ b/src/tools/rustfmt/tests/source/issue-1049.rs
@@ -0,0 +1,18 @@
+// Test overlong function signature
+pub unsafe fn reborrow_mut(&mut X: Abcde) -> Handle<NodeRef<marker::Mut, K, V, NodeType>, HandleType> {
+}
+
+pub fn merge(mut X: Abcdef) -> Handle<NodeRef<marker::Mut<'a>, K, V, marker::Internal>, marker::Edge> {
+}
+
+impl Handle {
+ pub fn merge(a: Abcd) -> Handle<NodeRef<marker::Mut<'a>, K, V, marker::Internal>, marker::Edge> {
+ }
+}
+
+// Long function without return type that should not be reformatted.
+fn veeeeeeeeeeeeeeeeeeeeery_long_name(a: FirstTypeeeeeeeeee, b: SecondTypeeeeeeeeeeeeeeeeeeeeeee) {}
+
+fn veeeeeeeeeeeeeeeeeeeeeery_long_name(a: FirstTypeeeeeeeeee, b: SecondTypeeeeeeeeeeeeeeeeeeeeeee) {}
+
+fn veeeeeeeeeeeeeeeeeeeeeeery_long_name(a: FirstTypeeeeeeeeee, b: SecondTypeeeeeeeeeeeeeeeeeeeeeee) {}