Rust compiler hangs when using macro_rules! to generate code with complex type parameters #116681
Labels
A-macros
Area: All kinds of macros (custom derive, macro_rules!, proc macros, ..)
C-bug
Category: This is a bug.
I-hang
Issue: The compiler never terminates, due to infinite loops, deadlock, livelock, etc.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
cat hang.rs
Command
rustc -C opt-level=0 hang.rs
I expected to see this happen: The compiler compiles successfully or outputs an error message.
Instead, this happened: The code, as provided below, appears to encounter a hang
The same problem is reproduced on the nightly version(1.75.0-nightly (d627cf0 2023-10-10)) as well.
Meta
rustc --version --verbose
:There is not any error information or stack information when using
export RUST_BACKTRACE=1
Backtrace
The text was updated successfully, but these errors were encountered: