- 
                Notifications
    
You must be signed in to change notification settings  - Fork 13.9k
 
Stop passing resolver disambiguator state to AST lowering. #143361
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
Conversation
| DefPathData::Ctor => 'c', | ||
| DefPathData::AnonConst => 'k', | ||
| DefPathData::AnonConst => 'K', | ||
| DefPathData::LateAnonConst => 'k', | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not certain changing mangling is the best idea. Is there some update to a demangler to be made before this PR is accepted?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm surprised you're not getting the demangler roundtrip ICE, but most likely this code path isn't hit in codegen tests with v0 mangling.
I don't think it's possible without changing mangling
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I couldn't find where in the demangler code this is used. IIUC, there are only two categories that are checked, 'C' and 'S', the latter not being produced any more. Should I look somewhere else?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it is unused, the demangler will just fail to demangle. Which is fine, you'd just get a weird symbol. We do have a roundtrip assertion checking that all symbols emitted in tests can be demangled back to the original symbol. I'm not quite certain why this is not causing issues, but maybe paths are just handled well enough together that it all works out.
| 
           @rustbot author Please add a codegen test (which will probably ICE if the compiler is built with debug assertions as the demangler can't support this new syntax yet).  | 
    
| 
           Reminder, once the PR becomes ready for a review, use   | 
    
| 
           ☔ The latest upstream changes (presumably #144249) made this pull request unmergeable. Please resolve the merge conflicts.  | 
    
4b55098    to
    235f4df      
    Compare
  
    | 
           Some changes occurred in tests/codegen-llvm/sanitizer cc @rcvalle  | 
    
      
        
              This comment has been minimized.
        
        
      
    
  This comment has been minimized.
235f4df    to
    b67453f      
    Compare
  
    | 
           This PR was rebased onto a different master commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.  | 
    
| 
           @bors r+  | 
    
Rollup of 4 pull requests Successful merges: - #143361 (Stop passing resolver disambiguator state to AST lowering.) - #148000 (Improvements to attribute suggestions) - #148007 (chore: Update to the latest annotate-snippets) - #148088 (compiletest: Simplify passing arguments to spawned test threads) r? `@ghost` `@rustbot` modify labels: rollup
Rollup of 4 pull requests Successful merges: - #143361 (Stop passing resolver disambiguator state to AST lowering.) - #148000 (Improvements to attribute suggestions) - #148007 (chore: Update to the latest annotate-snippets) - #148088 (compiletest: Simplify passing arguments to spawned test threads) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of #143361 - cjgillot:split-disambig, r=oli-obk Stop passing resolver disambiguator state to AST lowering. AST->HIR lowering can use a disjoint set of `DefPathData` as the resolver, so we don't need to pass the disambiguator state. r? `@oli-obk`
Rollup of 4 pull requests Successful merges: - rust-lang/rust#143361 (Stop passing resolver disambiguator state to AST lowering.) - rust-lang/rust#148000 (Improvements to attribute suggestions) - rust-lang/rust#148007 (chore: Update to the latest annotate-snippets) - rust-lang/rust#148088 (compiletest: Simplify passing arguments to spawned test threads) r? `@ghost` `@rustbot` modify labels: rollup
AST->HIR lowering can use a disjoint set of
DefPathDataas the resolver, so we don't need to pass the disambiguator state.r? @oli-obk