Skip to content

variable_bindings/declare.md: Contradictory statements about uninitialized variables. #1900

Closed
@zanedp

Description

@zanedp

It says not initializing a variable when it's declared may lead to use of uninitialized variables, but the sentence after the example says the compiler forbids the use of an uninitialized variable. If the compiler forbids using uninitialized variables, it's not possible to use an uninitialized variable.

The part saying this form is seldom used because it could lead to the use of uninitialized variables should be removed, since it's not possible in Rust.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions