Skip to content

Consider checking constants in public interfaces for privacy #30475

Closed
@petrochenkov

Description

@petrochenkov

I.e. making something like

const PRIV: usize = 10;
pub fn f() -> [u8; PRIV] { ... };

a privacy error/warning.

Some discussion in #29973 (comment) and below.
There are unresolved questions - what exactly should be checked - all signatures, all signatures except for constant initializers, const function bodies?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions