Skip to content

regression: ICE on an unconfigured interpolated item in a macro invocation #34171

Closed
@jseyfried

Description

@jseyfried

For example, the following causes an ICE:

macro_rules! m {
    ($i:item) => {
        error! {
            $i //< This becomes an unconfigured interpolated item in the above macro invocation
        }
    }
}

fn main() {
    m!(#[cfg(any())] fn g() {}); //< in this expansion.
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions