Skip to content

Commit 80c81c5

Browse files
committed
Allow newly added non_local_definitions lint in tests
1 parent 6170394 commit 80c81c5

File tree

14 files changed

+22
-5
lines changed

14 files changed

+22
-5
lines changed

tests/ui/async-await/async-assoc-fn-anon-lifetimes.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55

66
//@ edition:2018
77

8+
#![allow(non_local_definitions)]
9+
810
struct A<'a, 'b>(&'a &'b i32);
911
struct B<'a>(&'a i32);
1012

tests/ui/const-generics/min_const_generics/macro.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
//@ run-pass
2+
#![allow(non_local_definitions)]
3+
24
struct Example<const N: usize>;
35

46
macro_rules! external_macro {

tests/ui/consts/const_in_pattern/accept_structural.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ run-pass
22

3+
#![allow(non_local_definitions)]
34
#![warn(indirect_structural_match)]
45

56
// This test is checking our logic for structural match checking by enumerating

tests/ui/drop/dropck-eyepatch-reorder.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ run-pass
22
#![feature(dropck_eyepatch)]
3+
#![allow(non_local_definitions)]
34

45
// The point of this test is to test uses of `#[may_dangle]` attribute
56
// where the formal declaration order (in the impl generics) does not

tests/ui/drop/dropck-eyepatch.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
//@ run-pass
22
#![feature(dropck_eyepatch)]
3+
#![allow(non_local_definitions)]
34

45
// The point of this test is to illustrate that the `#[may_dangle]`
56
// attribute specifically allows, in the context of a type

tests/ui/imports/local-modularized-tricky-pass-2.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
// into the root module soon enough to act as usual items and shadow globs and preludes.
55

66
#![feature(decl_macro)]
7+
#![allow(non_local_definitions)]
78

89
// `macro_export` shadows globs
910
use inner1::*;

tests/ui/issues/issue-31776.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
//@ run-pass
22
#![allow(dead_code)]
33
#![allow(unused_variables)]
4+
#![allow(non_local_definitions)]
45
// Various scenarios in which `pub` is required in blocks
56

67
struct S;

tests/ui/issues/issue-41053.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
//@ run-pass
22
//@ aux-build:issue-41053.rs
33

4+
#![allow(non_local_definitions)]
5+
46
pub trait Trait { fn foo(&self) {} }
57

68
pub struct Foo;

tests/ui/macros/type-macros-simple.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
//@ run-pass
22
#![allow(dead_code)]
33
#![allow(unused_variables)]
4+
#![allow(non_local_definitions)]
5+
46
macro_rules! Tuple {
57
{ $A:ty,$B:ty } => { ($A, $B) }
68
}

tests/ui/packed/issue-46152.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
//@ run-pass
22
#![allow(dead_code)]
33
#![allow(unused_variables)]
4+
#![allow(non_local_definitions)]
45
#![feature(unsize, coerce_unsized)]
56

67
#[repr(packed)]

0 commit comments

Comments
 (0)