- 
                Notifications
    You must be signed in to change notification settings 
- Fork 13.9k
Implement lint against using Interner and InferCtxtLike in random compiler crates #138964
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
          
     Merged
      
      
    Conversation
  
    
      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
    
  
  
    
    
      
        
              This comment has been minimized.
        
        
      
    
  This comment has been minimized.
6336728    to
    5f1e36f      
    Compare
  
    | @bors r+ rollup | 
    
  TaKO8Ki 
      added a commit
        to TaKO8Ki/rust
      that referenced
      this pull request
    
      Mar 26, 2025 
    
    
      
  
    
      
    
  
… r=lcnr Implement lint against using Interner and InferCtxtLike in random compiler crates Often `Interner` defines similar methods to `TyCtxt` (but often simplified due to the simpler API surface of the type system layer for the new solver), which people will either unintentionally or intentionally import and use. Let's discourage that. r? lcnr
    
  bors 
      added a commit
        to rust-lang-ci/rust
      that referenced
      this pull request
    
      Mar 26, 2025 
    
    
      
  
    
      
    
  
Rollup of 9 pull requests Successful merges: - rust-lang#130883 (Add environment variable query) - rust-lang#138672 (Avoiding calling queries when collecting active queries) - rust-lang#138702 (Allow spawning threads after TLS destruction) - rust-lang#138935 (Update wg-prio triagebot config) - rust-lang#138946 (Un-bury chapters from the chapter list in rustc book) - rust-lang#138964 (Implement lint against using Interner and InferCtxtLike in random compiler crates) - rust-lang#138977 (Don't deaggregate InvocationParent just to reaggregate it again) - rust-lang#138980 (Collect items referenced from var_debug_info) - rust-lang#138985 (Use the correct binder scope for elided lifetimes in assoc consts) r? `@ghost` `@rustbot` modify labels: rollup
    
  jhpratt 
      added a commit
        to jhpratt/rust
      that referenced
      this pull request
    
      Mar 27, 2025 
    
    
      
  
    
      
    
  
… r=lcnr Implement lint against using Interner and InferCtxtLike in random compiler crates Often `Interner` defines similar methods to `TyCtxt` (but often simplified due to the simpler API surface of the type system layer for the new solver), which people will either unintentionally or intentionally import and use. Let's discourage that. r? lcnr
    
  bors 
      added a commit
        to rust-lang-ci/rust
      that referenced
      this pull request
    
      Mar 27, 2025 
    
    
      
  
    
      
    
  
Rollup of 10 pull requests Successful merges: - rust-lang#136083 (Suggest {to,from}_ne_bytes for transmutations between arrays and integers, etc) - rust-lang#138344 (Enable `reliable_f16_math` on x86) - rust-lang#138624 (Add mipsel maintainer) - rust-lang#138935 (Update wg-prio triagebot config) - rust-lang#138946 (Un-bury chapters from the chapter list in rustc book) - rust-lang#138964 (Implement lint against using Interner and InferCtxtLike in random compiler crates) - rust-lang#138977 (Don't deaggregate InvocationParent just to reaggregate it again) - rust-lang#138980 (Collect items referenced from var_debug_info) - rust-lang#138985 (Use the correct binder scope for elided lifetimes in assoc consts) - rust-lang#138987 (Always emit `native-static-libs` note, even if it is empty) r? `@ghost` `@rustbot` modify labels: rollup
    
  jhpratt 
      added a commit
        to jhpratt/rust
      that referenced
      this pull request
    
      Mar 27, 2025 
    
    
      
  
    
      
    
  
… r=lcnr Implement lint against using Interner and InferCtxtLike in random compiler crates Often `Interner` defines similar methods to `TyCtxt` (but often simplified due to the simpler API surface of the type system layer for the new solver), which people will either unintentionally or intentionally import and use. Let's discourage that. r? lcnr
    
  bors 
      added a commit
        to rust-lang-ci/rust
      that referenced
      this pull request
    
      Mar 27, 2025 
    
    
      
  
    
      
    
  
Rollup of 9 pull requests Successful merges: - rust-lang#136083 (Suggest {to,from}_ne_bytes for transmutations between arrays and integers, etc) - rust-lang#138624 (Add mipsel maintainer) - rust-lang#138935 (Update wg-prio triagebot config) - rust-lang#138946 (Un-bury chapters from the chapter list in rustc book) - rust-lang#138964 (Implement lint against using Interner and InferCtxtLike in random compiler crates) - rust-lang#138977 (Don't deaggregate InvocationParent just to reaggregate it again) - rust-lang#138980 (Collect items referenced from var_debug_info) - rust-lang#138985 (Use the correct binder scope for elided lifetimes in assoc consts) - rust-lang#138987 (Always emit `native-static-libs` note, even if it is empty) r? `@ghost` `@rustbot` modify labels: rollup
    
  bors 
      added a commit
        to rust-lang-ci/rust
      that referenced
      this pull request
    
      Mar 27, 2025 
    
    
      
  
    
      
    
  
Rollup of 10 pull requests Successful merges: - rust-lang#130883 (Add environment variable query) - rust-lang#138624 (Add mipsel maintainer) - rust-lang#138672 (Avoiding calling queries when collecting active queries) - rust-lang#138935 (Update wg-prio triagebot config) - rust-lang#138946 (Un-bury chapters from the chapter list in rustc book) - rust-lang#138964 (Implement lint against using Interner and InferCtxtLike in random compiler crates) - rust-lang#138977 (Don't deaggregate InvocationParent just to reaggregate it again) - rust-lang#138980 (Collect items referenced from var_debug_info) - rust-lang#138985 (Use the correct binder scope for elided lifetimes in assoc consts) - rust-lang#138987 (Always emit `native-static-libs` note, even if it is empty) r? `@ghost` `@rustbot` modify labels: rollup
    
  rust-timer 
      added a commit
        to rust-lang-ci/rust
      that referenced
      this pull request
    
      Mar 27, 2025 
    
    
      
  
    
      
    
  
Rollup merge of rust-lang#138964 - compiler-errors:usage-of-interner, r=lcnr Implement lint against using Interner and InferCtxtLike in random compiler crates Often `Interner` defines similar methods to `TyCtxt` (but often simplified due to the simpler API surface of the type system layer for the new solver), which people will either unintentionally or intentionally import and use. Let's discourage that. r? lcnr
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
      Labels
      
    S-waiting-on-bors
  Status: Waiting on bors to run and complete tests. Bors will change the label on completion. 
  
    T-compiler
  Relevant to the compiler team, which will review and decide on the PR/issue. 
  
    WG-trait-system-refactor
  The Rustc Trait System Refactor Initiative (-Znext-solver) 
  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.
  
    
  
    
Often
Internerdefines similar methods toTyCtxt(but often simplified due to the simpler API surface of the type system layer for the new solver), which people will either unintentionally or intentionally import and use. Let's discourage that.r? lcnr