diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2020-04-10 12:48:50 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-04-10 12:48:50 +0200 |
| commit | 490bdc0e57a160fdcf07e70b8bb8d49085aa2640 (patch) | |
| tree | 1011344fa02aecd61045ee91df80f6d7cbe7df07 /src | |
| parent | 54807cab1d2efd84a5a6046561339cc7d15568a7 (diff) | |
| parent | 1761a65ebadd3c4125fa80c0f5570b24429bafff (diff) | |
| download | rust-490bdc0e57a160fdcf07e70b8bb8d49085aa2640.tar.gz rust-490bdc0e57a160fdcf07e70b8bb8d49085aa2640.zip | |
Rollup merge of #70964 - RalfJung:mark-cli-lint-hack, r=petrochenkov
rustc_session CLI lint parsing: mark a temporary hack as such This code was added in https://github.com/rust-lang/rust/pull/70918, but it should not be necessary any more once `forbid` works as expected for in-code attributes. Cc @tobithiel @davidtwco
Diffstat (limited to 'src')
| -rw-r--r-- | src/librustc_session/config.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/librustc_session/config.rs b/src/librustc_session/config.rs index 4e2423bc3b1..aaf30c583e2 100644 --- a/src/librustc_session/config.rs +++ b/src/librustc_session/config.rs @@ -1019,7 +1019,9 @@ pub fn get_cmd_lint_options( for &level in &[lint::Allow, lint::Warn, lint::Deny, lint::Forbid] { for (passed_arg_pos, lint_name) in matches.opt_strs_pos(level.as_str()) { let arg_pos = if let lint::Forbid = level { - // forbid is always specified last, so it can't be overridden + // HACK: forbid is always specified last, so it can't be overridden. + // FIXME: remove this once <https://github.com/rust-lang/rust/issues/70819> is + // fixed and `forbid` works as expected. usize::max_value() } else { passed_arg_pos |
