avoid overflow when generating debuginfo for expanding recursive types#138599
Merged
bors merged 2 commits intorust-lang:masterfrom Apr 18, 2025
Merged
avoid overflow when generating debuginfo for expanding recursive types#138599bors merged 2 commits intorust-lang:masterfrom
bors merged 2 commits intorust-lang:masterfrom
Conversation
Collaborator
This comment has been minimized.
This comment has been minimized.
Collaborator
|
This PR changes a file inside |
Member
|
overloaded rn r? compiler |
Member
|
sorry for the bouncing, but I'm not familiar enough with this code to judge whether this is a good solution or not. |
wesleywiser
approved these changes
Apr 18, 2025
Member
wesleywiser
left a comment
There was a problem hiding this comment.
Yes, I think this is a pretty reasonable solution.
Member
|
Thanks @adwinwhite! Nice to see all of those issues fixed 🥇 @bors r+ |
Collaborator
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Apr 18, 2025
…iaskrgr Rollup of 6 pull requests Successful merges: - rust-lang#137881 (Add `copy_within` to `IndexSlice`) - rust-lang#138599 (avoid overflow when generating debuginfo for expanding recursive types) - rust-lang#139934 (Update `compiler-builtins` to 0.1.155) - rust-lang#139976 (run-make: drop `os_pipe` workaround now that `anonymous_pipe` is stable on beta) - rust-lang#139989 (tests: adjust 101082 test for LLVM 21 fix) - rust-lang#139991 (remove stray file) r? `@ghost` `@rustbot` modify labels: rollup
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Apr 18, 2025
…iaskrgr Rollup of 6 pull requests Successful merges: - rust-lang#137881 (Add `copy_within` to `IndexSlice`) - rust-lang#138599 (avoid overflow when generating debuginfo for expanding recursive types) - rust-lang#139934 (Update `compiler-builtins` to 0.1.155) - rust-lang#139976 (run-make: drop `os_pipe` workaround now that `anonymous_pipe` is stable on beta) - rust-lang#139989 (tests: adjust 101082 test for LLVM 21 fix) - rust-lang#139991 (remove stray file) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Apr 18, 2025
Rollup merge of rust-lang#138599 - adwinwhite:recursive-overflow, r=wesleywiser avoid overflow when generating debuginfo for expanding recursive types Fixes rust-lang#135093 Fixes rust-lang#121538 Fixes rust-lang#107362 Fixes rust-lang#100618 Fixes rust-lang#115994 The overflow happens because expanding recursive types keep creating new nested types when recurring into sub fields. I fixed that by returning an empty stub node when expanding recursion is detected.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #135093
Fixes #121538
Fixes #107362
Fixes #100618
Fixes #115994
The overflow happens because expanding recursive types keep creating new nested types when recurring into sub fields.
I fixed that by returning an empty stub node when expanding recursion is detected.