Skip to content

Audit deprecation lints and hardcoded warnings and turn most of them into errors in 2018 edition #52593

@petrochenkov

Description

@petrochenkov

Most these are going to become errors in 2015 edition as well sooner or later, but since edition switch is an explicit opt in, it's a good opportunity to tie disabling of all the deprecated stuff to it as well.

The amount of additional required changes will be negligible compared to changes already required for 2018 migration, especially if we are counting "2018 idioms" in.

Additionally, hardcoded warnings are bad, mkay, and audit is also necessary to turn them into configurable lints or errors. (Most of the warnings are very old and predate the deprecation lint system, and fire only in very rare cases.)

How to: add some kind of flag to span_warn and deprecation lint machinery that's false by default and "false" means it's a hard error on 2018 edition. Explicit opt-out can be applied so that a lint/warning continues being a lint/warning even on 2018 edition.

Known lints/warnings requiring opt-out:

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsArea: Messages for errors, warnings, and lintsA-edition-2018Area: The 2018 editionA-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.F-rust_2018_preview`#![feature(rust_2018_preview)]`T-langRelevant to the language team

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions