-
Notifications
You must be signed in to change notification settings - Fork 12.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rustc segmentation fault with circular module #97589
Labels
C-bug
Category: This is a bug.
E-help-wanted
Call for participation: Help is requested to fix this issue.
I-crash
Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
I could reproduce this on a recent nightly
|
cuviper
added
I-crash
Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
C-bug
Category: This is a bug.
labels
May 31, 2022
Triage: Seems worthwhile to get help with fixing. Labeling E-help-wanted. |
Enselic
added
the
E-help-wanted
Call for participation: Help is requested to fix this issue.
label
Mar 16, 2024
dianne
added a commit
to dianne/rust
that referenced
this issue
Sep 11, 2024
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this issue
Sep 21, 2024
…nkov rustc_expand: remember module `#[path]`s during expansion During invocation collection, if a module item parsed from a `#[path]` attribute needed a second pass after parsing, its path wouldn't get added to the file path stack, so cycle detection broke. This checks the `#[path]` in such cases, so that it gets added appropriately. I think it should work identically to the case for external modules that don't need a second pass, but I'm not 100% sure. Fixes rust-lang#97589
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
C-bug
Category: This is a bug.
E-help-wanted
Call for participation: Help is requested to fix this issue.
I-crash
Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
The rust compiler segfaults when using the path attribute
#[path = "this_file.rs"]
pointing to itself with an inner line documentation comment in the file.Steps to reproduce
Install this version of rust on linux:
Create the following file structure:
lib.rs
:recursive.rs
:And compiling
lib.rs
will cause the segfault:rustc lib.rs
Notes
pub mod recursive
inlib.rs
lib.rs
containing a circular module declaration to itself, rather requires another fileThe text was updated successfully, but these errors were encountered: