Skip to content

MIR basic_block should not be accessed via function #1626

Closed
@Hoblovski

Description

@Hoblovski

I'm reading the section on Identifiers in the compiler and it claims

BasicBlock identifies a basic block. It points to an instance of BasicBlockData, which can be retrieved by indexing into Body::basic_blocks() (note that you must call a function; the field is private).

However as of March 2023, I see rust-lang/rust/master is no longer using the function basic_block(), but instead directly accessing the field (yeah it's public now).

Am I missing anything or should we update this sentence? Thank you.

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