]> git.lizzy.rs Git - rust.git/blobdiff - tests/ui/redundant_field_names.rs
Addition `manual_map` test for `unsafe` blocks
[rust.git] / tests / ui / redundant_field_names.rs
index 68adba92f8a297d0dcc6d4958e3a3535f60f3306..3f97b80c56828c3842c451bb9b616bb3103e1eec 100644 (file)
@@ -1,15 +1,6 @@
-// Copyright 2014-2018 The Rust Project Developers. See the COPYRIGHT
-// file at the top-level directory of this distribution.
-//
-// 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.
-
+// run-rustfix
 #![warn(clippy::redundant_field_names)]
-#![allow(unused_variables)]
-#![feature(inclusive_range, inclusive_range_fields, inclusive_range_methods)]
+#![allow(clippy::no_effect, dead_code, unused_variables)]
 
 #[macro_use]
 extern crate derive_new;
@@ -68,3 +59,13 @@ fn main() {
     let _ = RangeInclusive::new(start, end);
     let _ = RangeToInclusive { end: end };
 }
+
+fn issue_3476() {
+    fn foo<T>() {}
+
+    struct S {
+        foo: fn(),
+    }
+
+    S { foo: foo::<i32> };
+}