Skip to content
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

Add x.py check --stage 1 #80952

Closed
wants to merge 2 commits into from
Closed

Commits on Jan 12, 2021

  1. Add x.py check --stage 1

    This is useful for several cases:
    
    - Checking changes to the standard library with `cfg(not(bootstrap))`
    - Checking platform-specific changes to the compiler. In particular,
      checking with stage 1 doesn't require having a cross-compiling C native
      toolchain, unlike building.
    - Testing newly added internal lints without having to rebuild
      rustc_middle twice
    
    It is also very easy to support.
    jyn514 committed Jan 12, 2021
    Configuration menu
    Copy the full SHA
    62cd64e View commit details
    Browse the repository at this point in the history

Commits on Jan 13, 2021

  1. Always treat stage0 as the snapshot compiler when checking

    Otherwise, we may not have MIR for the standard library available:
    
    ```
    error: internal compiler error: compiler/rustc_mir/src/monomorphize/collector.rs:826:9: cannot create local mono-item for DefId(2:6820 ~ core[92cf]::fmt::{impl#2}::new_v1)
    ```
    
    The current error after this change is
    
    ```
    error[E0514]: found crate `chalk_derive` compiled by an incompatible version of rustc
      --> /home/joshua/.local/lib/cargo/registry/src/git.luolix.top-1ecc6299db9ec823/chalk-ir-0.36.0/src/lib.rs:13:5
       |
    13 | use chalk_derive::{Fold, HasInterner, SuperVisit, Visit, Zip};
       |     ^^^^^^^^^^^^
       |
       = help: please recompile that crate using this compiler (rustc 1.51.0-dev)
       = note: the following crate versions were found:
               crate `chalk_derive` compiled by rustc 1.49.0-beta.1 (21dea46 2020-11-18): /home/joshua/rustc3/build/x86_64-unknown-linux-gnu/stage1-rustc/release/deps/libchalk_derive-843b3d0b9b865ca6.so
    ```
    jyn514 committed Jan 13, 2021
    Configuration menu
    Copy the full SHA
    7ed8010 View commit details
    Browse the repository at this point in the history