Content-Length: 24476 | pFad | https://doc.rust-lang.org/std/pin/../hash/../../std/sync/../../../std/../error_codes/./E0448.html

E0448 - Error codes index

Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Error code E0448

Note: this error code is no longer emitted by the compiler.

The pub keyword was used inside a public enum.

Erroneous code example:

#![allow(unused)]
fn main() {
pub enum Foo {
    pub Bar, // error: unnecessary `pub` visibility
}
}

Since the enum is already public, adding pub on one its elements is unnecessary. Example:

#![allow(unused)]
fn main() {
enum Foo {
    pub Bar, // not ok!
}
}

This is the correct syntax:

#![allow(unused)]
fn main() {
pub enum Foo {
    Bar, // ok!
}
}








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://doc.rust-lang.org/std/pin/../hash/../../std/sync/../../../std/../error_codes/./E0448.html

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy