Skip to content

Commit 6dab6fb

Browse files
committed
Temporarily make allow-by-default the non_local_definitions lint
1 parent 1547c07 commit 6dab6fb

File tree

6 files changed

+67
-56
lines changed

6 files changed

+67
-56
lines changed

compiler/rustc_lint/src/non_local_def.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ declare_lint! {
3636
/// All nested bodies (functions, enum discriminant, array length, consts) (expect for
3737
/// `const _: Ty = { ... }` in top-level module, which is still undecided) are checked.
3838
pub NON_LOCAL_DEFINITIONS,
39-
Warn,
39+
Allow,
4040
"checks for non-local definitions",
4141
report_in_external_macro
4242
}

tests/ui/lint/non_local_definitions.rs

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
//@ rustc-env:CARGO=/usr/bin/cargo
55

66
#![feature(inline_const)]
7+
#![warn(non_local_definitions)]
78

89
extern crate non_local_macro;
910

0 commit comments

Comments
 (0)