-
-
Notifications
You must be signed in to change notification settings - Fork 14.3k
Open
Labels
A-type-systemArea: Type systemArea: Type systemC-bugCategory: This is a bug.Category: This is a bug.I-hangIssue: The compiler never terminates, due to infinite loops, deadlock, livelock, etc.Issue: The compiler never terminates, due to infinite loops, deadlock, livelock, etc.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.T-typesRelevant to the types team, which will review and decide on the PR/issue.Relevant to the types team, which will review and decide on the PR/issue.
Description
I tried this code:
fn recur(lines: impl Iterator) {
recur(lines.filter(|_| true))
}
fn main() {
recur([0u8].into_iter());
}I expected the compiler would provide an error message, akin to reached the recursion limit while instantiating.
Instead, the compiler appears to hang indefinitely — I killed the process after a while.
Meta
% rustc +stable --version --verbose
rustc 1.57.0 (f1edd0429 2021-11-29)
binary: rustc
commit-hash: f1edd0429582dd29cccacaf50fd134b05593bd9c
commit-date: 2021-11-29
host: aarch64-apple-darwin
release: 1.57.0
LLVM version: 13.0.0
% rustc +nightly --version --verbose
rustc 1.59.0-nightly (acbe4443c 2021-12-02)
binary: rustc
commit-hash: acbe4443cc4c9695c0b74a7b64b60333c990a400
commit-date: 2021-12-02
host: aarch64-apple-darwin
release: 1.59.0-nightly
LLVM version: 13.0.0
Enet4, Canop, imjasonmiller, Stargateur, hkmatsumoto and 1 more
Metadata
Metadata
Assignees
Labels
A-type-systemArea: Type systemArea: Type systemC-bugCategory: This is a bug.Category: This is a bug.I-hangIssue: The compiler never terminates, due to infinite loops, deadlock, livelock, etc.Issue: The compiler never terminates, due to infinite loops, deadlock, livelock, etc.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.T-typesRelevant to the types team, which will review and decide on the PR/issue.Relevant to the types team, which will review and decide on the PR/issue.