]> git.lizzy.rs Git - rust.git/commitdiff
Fixed tidy errors
authorSunjay Varma <varma.sunjay@gmail.com>
Fri, 10 Nov 2017 03:21:53 +0000 (22:21 -0500)
committerSunjay Varma <varma.sunjay@gmail.com>
Fri, 1 Dec 2017 06:26:29 +0000 (01:26 -0500)
src/libsyntax/feature_gate.rs
src/test/compile-fail/feature-gate-generic_associated_types.rs [new file with mode: 0644]
src/test/compile-fail/generic-associated-types.rs [deleted file]

index 9b5be298fd54e008a32cd21890ce46fe2e2f68a6..161967c3f3d6c7f06741a81ba1071f6b7447c703 100644 (file)
@@ -1622,7 +1622,8 @@ fn visit_trait_item(&mut self, ti: &'a ast::TraitItem) {
                                   "associated type defaults are unstable");
             }
             _ if ti.generics.is_parameterized() => {
-                gate_feature_post!(&self, generic_associated_types, ti.span, "generic associated types are unstable");
+                gate_feature_post!(&self, generic_associated_types, ti.span,
+                                   "generic associated types are unstable");
             }
             _ => {}
         }
@@ -1643,7 +1644,8 @@ fn visit_impl_item(&mut self, ii: &'a ast::ImplItem) {
                 }
             }
             _ if ii.generics.is_parameterized() => {
-                gate_feature_post!(&self, generic_associated_types, ii.span, "generic associated types are unstable");
+                gate_feature_post!(&self, generic_associated_types, ii.span,
+                                   "generic associated types are unstable");
             }
             _ => {}
         }
diff --git a/src/test/compile-fail/feature-gate-generic_associated_types.rs b/src/test/compile-fail/feature-gate-generic_associated_types.rs
new file mode 100644 (file)
index 0000000..a8fc822
--- /dev/null
@@ -0,0 +1,17 @@
+// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+use std::ops::Deref;
+
+trait PointerFamily {
+    type Pointer<T>: Deref<Target = T>;
+}
+
+fn main() {}
diff --git a/src/test/compile-fail/generic-associated-types.rs b/src/test/compile-fail/generic-associated-types.rs
deleted file mode 100644 (file)
index a8fc822..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
-// file at the top-level directory of this distribution and at
-// http://rust-lang.org/COPYRIGHT.
-//
-// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
-// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
-// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
-// option. This file may not be copied, modified, or distributed
-// except according to those terms.
-
-use std::ops::Deref;
-
-trait PointerFamily {
-    type Pointer<T>: Deref<Target = T>;
-}
-
-fn main() {}