Repository navigation
Added more queries to AdtDef in rustc_public to check for rust language types - #166012
Conversation
|
Thanks for the pull request, and welcome! The Rust Project has assigned @scottmcm (or someone else) to review your changes, you should hear from them (or someone else) within the next two weeks. Please see the contribution instructions and our LLM policy for more information. Why was this reviewer chosen?The reviewer was selected based on:
|
This comment has been minimized.
This comment has been minimized.
|
r? me |
|
@makai410 i've added the test, also referring to the rest of my first comment "Also i'm having troubles finding an AdtDef query for is_anonymous all my research leads me to anonymous lifetimes which are not ADTs Also more AdtDef queries such as is_fundamental is_unsafe_pinned is_pin is_pin_project is_field_representing_type can be added to add support for more language items, can i add them too?" |
This comment has been minimized.
This comment has been minimized.
I suspect that was a typo or something in the issue.
We can add those later when there's a request. |
|
CI wants some formatting. Fyi you can do |
|
Ok i will do that rn @makai410 do i also need to rebase? |
This comment has been minimized.
This comment has been minimized.
|
We need to squash these commits, let's use some bors magic @bors squash message="feat: add more AdtDef queries" |
This comment has been minimized.
This comment has been minimized.
|
🔨 5 commits were squashed into 3ee6c6f. |
2f5945c to
3ee6c6f
Compare
|
@bors r+ rollup |
3ee6c6f to
45426d2
Compare
|
@makai410 @JonathanBrouwer CI fixed, it was test-tidy detecting trailing whitespace |
|
@bors r=makai410 |
…s, r=makai410 Added more queries to AdtDef in rustc_public to check for rust language types Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133 No llm was used in the generation of this PR Also i'm having troubles finding an `AdtDef` query for `is_anonymous` all my research leads me to anonymous lifetimes which are not `ADT`s Also [more](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) AdtDef queries such as [is_fundamental](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L500) [is_unsafe_pinned](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) [is_pin](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L536) [is_pin_project](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L543) [is_field_representing_type](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L547) can be added to add support for more language items, can i add them too? @makai410 @celinval
…uwer Rollup of 5 pull requests Successful merges: - #166266 (miri subtree update) - #164878 (Don't require `extern "llvm-intrinsic"` return structs to be `#[repr(packed)]`) - #165930 (Add red-green mark when dumping dep graph. Show DefIds if available) - #166012 (Added more queries to AdtDef in rustc_public to check for rust language types) - #166269 (libcore: Revert some comment changes)
…s, r=makai410 Added more queries to AdtDef in rustc_public to check for rust language types Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133 No llm was used in the generation of this PR Also i'm having troubles finding an `AdtDef` query for `is_anonymous` all my research leads me to anonymous lifetimes which are not `ADT`s Also [more](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) AdtDef queries such as [is_fundamental](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L500) [is_unsafe_pinned](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) [is_pin](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L536) [is_pin_project](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L543) [is_field_representing_type](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L547) can be added to add support for more language items, can i add them too? @makai410 @celinval
…uwer Rollup of 14 pull requests Successful merges: - #166266 (miri subtree update) - #164878 (Don't require `extern "llvm-intrinsic"` return structs to be `#[repr(packed)]`) - #165008 (Support `NonNull` pointers as `asm!` input operands) - #165892 (`rustc_builtin_macros` cleanup, part 10) - #165930 (Add red-green mark when dumping dep graph. Show DefIds if available) - #166280 (std: also mark doctests with skip_unsupported_miri_tests) - #166295 (use `cfg!(overflow_checks)` in `overflow_checks` intrinsic instead of `cfg!(debug_assertions)`) - #165618 (Implement RangeIntersect on core::range types) - #166012 (Added more queries to AdtDef in rustc_public to check for rust language types) - #166142 (Lower to `hir::Param`s for extern functions) - #166259 (fmt: Improve `Debug` for `FormattingOptions`) - #166269 (libcore: Revert some comment changes) - #166287 (Use `core::ptr` in `implicit_provenance_casts` help for `no_std` crates) - #166306 (bootstrap: Stop passing `-Ztrim-paths` to cargo now that it's stable in beta)
@bors try jobs=test-x86_64-rust-for-linux |
Added more queries to AdtDef in rustc_public to check for rust language types try-job: test-x86_64-rust-for-linux
This comment has been minimized.
This comment has been minimized.
…s, r=makai410 Added more queries to AdtDef in rustc_public to check for rust language types Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133 No llm was used in the generation of this PR Also i'm having troubles finding an `AdtDef` query for `is_anonymous` all my research leads me to anonymous lifetimes which are not `ADT`s Also [more](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) AdtDef queries such as [is_fundamental](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L500) [is_unsafe_pinned](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) [is_pin](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L536) [is_pin_project](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L543) [is_field_representing_type](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L547) can be added to add support for more language items, can i add them too? @makai410 @celinval
Rollup of 15 pull requests Successful merges: - #166266 (miri subtree update) - #165720 (windows: remove redundant prefix parsing in `PathBuf::_push`) - #164878 (Don't require `extern "llvm-intrinsic"` return structs to be `#[repr(packed)]`) - #165008 (Support `NonNull` pointers as `asm!` input operands) - #165892 (`rustc_builtin_macros` cleanup, part 10) - #164485 (Stabilize unchecked `nonzero_ops`) - #165618 (Implement RangeIntersect on core::range types) - #165833 (Deallocate with the right provenance on Windows) - #165834 (Implement tidy alphabetical --bless on Windows) - #165889 (Fix docs of alloc fn: Allocator API stabilized) - #165923 (Don't load/store a LLVM aggregate type when returning an array from a generic SIMD intrinsic) - #166012 (Added more queries to AdtDef in rustc_public to check for rust language types) - #166216 (Stop using #![no_core] in profiler_builtins) - #166259 (fmt: Improve `Debug` for `FormattingOptions`) - #166263 (Show slice split results for empty and singleton slices)
…s, r=makai410 Added more queries to AdtDef in rustc_public to check for rust language types Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133 No llm was used in the generation of this PR Also i'm having troubles finding an `AdtDef` query for `is_anonymous` all my research leads me to anonymous lifetimes which are not `ADT`s Also [more](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) AdtDef queries such as [is_fundamental](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L500) [is_unsafe_pinned](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) [is_pin](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L536) [is_pin_project](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L543) [is_field_representing_type](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L547) can be added to add support for more language items, can i add them too? @makai410 @celinval
…s, r=makai410 Added more queries to AdtDef in rustc_public to check for rust language types Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133 No llm was used in the generation of this PR Also i'm having troubles finding an `AdtDef` query for `is_anonymous` all my research leads me to anonymous lifetimes which are not `ADT`s Also [more](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) AdtDef queries such as [is_fundamental](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L500) [is_unsafe_pinned](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) [is_pin](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L536) [is_pin_project](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L543) [is_field_representing_type](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L547) can be added to add support for more language items, can i add them too? @makai410 @celinval
…uwer Rollup of 19 pull requests Successful merges: - #166266 (miri subtree update) - #164878 (Don't require `extern "llvm-intrinsic"` return structs to be `#[repr(packed)]`) - #165008 (Support `NonNull` pointers as `asm!` input operands) - #165892 (`rustc_builtin_macros` cleanup, part 10) - #165930 (Add red-green mark when dumping dep graph. Show DefIds if available) - #166280 (std: also mark doctests with skip_unsupported_miri_tests) - #166295 (use `cfg!(overflow_checks)` in `overflow_checks` intrinsic instead of `cfg!(debug_assertions)`) - #164485 (Stabilize unchecked `nonzero_ops`) - #165618 (Implement RangeIntersect on core::range types) - #165782 (Make unsafe unknown diagnostic attributes an error again) - #165833 (Deallocate with the right provenance on Windows) - #165834 (Implement tidy alphabetical --bless on Windows) - #165889 (Fix docs of alloc fn: Allocator API stabilized) - #165923 (Don't load/store a LLVM aggregate type when returning an array from a generic SIMD intrinsic) - #166012 (Added more queries to AdtDef in rustc_public to check for rust language types) - #166186 (OpenOptions::append: clarify docs) - #166216 (Stop using #![no_core] in profiler_builtins) - #166259 (fmt: Improve `Debug` for `FormattingOptions`) - #166263 (Show slice split results for empty and singleton slices)
…uwer Rollup of 18 pull requests Successful merges: - #164878 (Don't require `extern "llvm-intrinsic"` return structs to be `#[repr(packed)]`) - #165008 (Support `NonNull` pointers as `asm!` input operands) - #165892 (`rustc_builtin_macros` cleanup, part 10) - #165930 (Add red-green mark when dumping dep graph. Show DefIds if available) - #166280 (std: also mark doctests with skip_unsupported_miri_tests) - #166295 (use `cfg!(overflow_checks)` in `overflow_checks` intrinsic instead of `cfg!(debug_assertions)`) - #164485 (Stabilize unchecked `nonzero_ops`) - #165618 (Implement RangeIntersect on core::range types) - #165782 (Make unsafe unknown diagnostic attributes an error again) - #165833 (Deallocate with the right provenance on Windows) - #165834 (Implement tidy alphabetical --bless on Windows) - #165889 (Fix docs of alloc fn: Allocator API stabilized) - #165923 (Don't load/store a LLVM aggregate type when returning an array from a generic SIMD intrinsic) - #166012 (Added more queries to AdtDef in rustc_public to check for rust language types) - #166186 (OpenOptions::append: clarify docs) - #166216 (Stop using #![no_core] in profiler_builtins) - #166259 (fmt: Improve `Debug` for `FormattingOptions`) - #166263 (Show slice split results for empty and singleton slices)
…uwer Rollup of 18 pull requests Successful merges: - #164878 (Don't require `extern "llvm-intrinsic"` return structs to be `#[repr(packed)]`) - #165008 (Support `NonNull` pointers as `asm!` input operands) - #165892 (`rustc_builtin_macros` cleanup, part 10) - #165930 (Add red-green mark when dumping dep graph. Show DefIds if available) - #166280 (std: also mark doctests with skip_unsupported_miri_tests) - #166295 (use `cfg!(overflow_checks)` in `overflow_checks` intrinsic instead of `cfg!(debug_assertions)`) - #164485 (Stabilize unchecked `nonzero_ops`) - #165618 (Implement RangeIntersect on core::range types) - #165782 (Make unsafe unknown diagnostic attributes an error again) - #165833 (Deallocate with the right provenance on Windows) - #165834 (Implement tidy alphabetical --bless on Windows) - #165889 (Fix docs of alloc fn: Allocator API stabilized) - #165923 (Don't load/store a LLVM aggregate type when returning an array from a generic SIMD intrinsic) - #166012 (Added more queries to AdtDef in rustc_public to check for rust language types) - #166186 (OpenOptions::append: clarify docs) - #166216 (Stop using #![no_core] in profiler_builtins) - #166259 (fmt: Improve `Debug` for `FormattingOptions`) - #166263 (Show slice split results for empty and singleton slices)
Rollup merge of #166012 - adpthegreat:add_more_adtdef_queries, r=makai410 Added more queries to AdtDef in rustc_public to check for rust language types Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133 No llm was used in the generation of this PR Also i'm having troubles finding an `AdtDef` query for `is_anonymous` all my research leads me to anonymous lifetimes which are not `ADT`s Also [more](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) AdtDef queries such as [is_fundamental](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L500) [is_unsafe_pinned](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L524) [is_pin](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L536) [is_pin_project](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L543) [is_field_representing_type](https://github.com/rust-lang/rust/blob/1a4d65fa9d3ff3990d766c52e741c7027ffa4fc6/compiler/rustc_middle/src/ty/adt.rs#L547) can be added to add support for more language items, can i add them too? @makai410 @celinval
View all comments
Closes rust-lang/rustc_public#86 was redirected to make a pr to this repo here rust-lang/rustc_public#133
No llm was used in the generation of this PR
Also i'm having troubles finding an
AdtDefquery foris_anonymousall my research leads me to anonymous lifetimes which are notADTsAlso more AdtDef queries such as is_fundamental is_unsafe_pinned is_pin is_pin_project is_field_representing_type can be added to add support for more language items, can i add them too?
@makai410 @celinval