Skip to content

cast_lossless on const item #2267

Closed
Closed
@letheed

Description

@letheed
const FOO: i32 = 42;
const FOO_I64: i64 = 42 as i64;

Triggers the suggestion try: i64::from(FOO) which isn't possible (yet?).

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: Clippy is not doing the correct thingE-needs-testCall for participation: writing testsgood first issueThese issues are a good way to get started with Clippy

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions