Skip to content

A new lint for imports ending in ::{self}; #6552

@ghost

Description

What it does

It detects imports that end in ::{self}; and emits a warning for them.

Categories (optional)

  • Kind: Perhaps clippy::style.

The advantage of the recommended code over the original code is that it's shorter and simpler.

Drawbacks

None.

Example

use std::io::{self};

Could be written as:

use std::io;

Metadata

Metadata

Assignees

Labels

A-lintArea: New lintsE-mediumCall for participation: Medium difficulty level problem and requires some initial experience.L-styleLint: Belongs in the style lint group

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions