-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Move inline asm check to typeck, properly handle aliases #140302
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
These commits modify the If this was unintentional then you should revert the changes before this PR is merged. |
infcx, | ||
typeck_results, | ||
} | ||
pub(crate) fn new(def_id: LocalDefId, fcx: &'a FnCtxt<'a, 'tcx>) -> Self { |
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.
pls swap argument order
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.
or just recompute the DefId
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.
r=me after nits
51c0f33
to
f769f42
Compare
@bors r+ rollup |
…lcnr Move inline asm check to typeck, properly handle aliases Pull `InlineAsmCtxt` down to `rustc_hir_typeck`, and instead of using things like `Ty::is_copy`, use the `InferCtxt`-aware methods. To fix rust-lang/trait-system-refactor-initiative#189, we also add a `try_structurally_resolve_*` call to `expr_ty`. r? lcnr
…lcnr Move inline asm check to typeck, properly handle aliases Pull `InlineAsmCtxt` down to `rustc_hir_typeck`, and instead of using things like `Ty::is_copy`, use the `InferCtxt`-aware methods. To fix rust-lang/trait-system-refactor-initiative#189, we also add a `try_structurally_resolve_*` call to `expr_ty`. r? lcnr
…iaskrgr Rollup of 7 pull requests Successful merges: - rust-lang#123239 (Implement a lint for implicit autoref of raw pointer dereference - take 2) - rust-lang#140215 (transmutability: Support char, NonZeroXxx) - rust-lang#140226 (Update wasm-component-ld to 0.5.13) - rust-lang#140302 (Move inline asm check to typeck, properly handle aliases) - rust-lang#140317 (Remove redundant check) - rust-lang#140318 (Simply try to unpeel AsyncFnKindHelper goal in `emit_specialized_closure_kind_error`) - rust-lang#140325 (Grammar fixes for BufRead::has_data_left docs) r? `@ghost` `@rustbot` modify labels: rollup
f769f42
to
3d7402b
Compare
Some changes occurred in compiler/rustc_codegen_ssa Some changes occurred in compiler/rustc_codegen_cranelift cc @bjorn3 |
lmao some branches got crossed 💀 |
3d7402b
to
f769f42
Compare
f769f42
to
3ab6051
Compare
@bors r+ rollup |
…lcnr Move inline asm check to typeck, properly handle aliases Pull `InlineAsmCtxt` down to `rustc_hir_typeck`, and instead of using things like `Ty::is_copy`, use the `InferCtxt`-aware methods. To fix rust-lang/trait-system-refactor-initiative#189, we also add a `try_structurally_resolve_*` call to `expr_ty`. r? lcnr
…enton Rollup of 9 pull requests Successful merges: - rust-lang#139308 (add autodiff inline) - rust-lang#140276 (Do not compute type_of for impl item if impl where clauses are unsatisfied) - rust-lang#140302 (Move inline asm check to typeck, properly handle aliases) - rust-lang#140323 (Implement the internal feature `cfg_target_has_reliable_f16_f128`) - rust-lang#140374 (Resolve instance for SymFn in global/naked asm) - rust-lang#140391 (Rename sub_ptr to offset_from_unsigned in docs) - rust-lang#140394 (Make bootstrap git tests more self-contained) - rust-lang#140396 (Workaround for windows-gnu rust-lld test failure) - rust-lang#140402 (only return nested goals for `Certainty::Yes`) r? `@ghost` `@rustbot` modify labels: rollup
[DO NOT MERGE] bootstrap with `-Znext-solver=globally` A revival of rust-lang#124812. Current status: ~~`./x.py b --stage 2` passes 🎉~~ `try` builds succeed 🎉 🎉 🎉 ~~[top 100 most downloaded crates on crates.io compile](rust-lang#133502 (comment) [top 1000 most downloaded crates on crates.io compile](rust-lang#133502 (comment)) [first perf run](rust-lang#133502 (comment)) 👻 ### in-flight changes - rust-lang#124852, unsure whether I actually want to land this PR for now - rust-lang#139587 - https://github.com/lcnr/rust/tree/opaque-type-method-call - rust-lang#140302 - rust-lang#140276 - rust-lang#140260 - rust-lang#140405 r? `@ghost`
…lcnr Move inline asm check to typeck, properly handle aliases Pull `InlineAsmCtxt` down to `rustc_hir_typeck`, and instead of using things like `Ty::is_copy`, use the `InferCtxt`-aware methods. To fix rust-lang/trait-system-refactor-initiative#189, we also add a `try_structurally_resolve_*` call to `expr_ty`. r? lcnr
…enton Rollup of 10 pull requests Successful merges: - rust-lang#139308 (add autodiff inline) - rust-lang#139656 (Stabilize `slice_as_chunks` library feature) - rust-lang#140022 (allow deref patterns to move out of boxes) - rust-lang#140276 (Do not compute type_of for impl item if impl where clauses are unsatisfied) - rust-lang#140302 (Move inline asm check to typeck, properly handle aliases) - rust-lang#140323 (Implement the internal feature `cfg_target_has_reliable_f16_f128`) - rust-lang#140391 (Rename sub_ptr to offset_from_unsigned in docs) - rust-lang#140394 (Make bootstrap git tests more self-contained) - rust-lang#140396 (Workaround for windows-gnu rust-lld test failure) - rust-lang#140402 (only return nested goals for `Certainty::Yes`) Failed merges: - rust-lang#139765 ([beta] Delay `hash_extract_if` stabilization from 1.87 to 1.88) r? `@ghost` `@rustbot` modify labels: rollup
…enton Rollup of 10 pull requests Successful merges: - rust-lang#139308 (add autodiff inline) - rust-lang#139656 (Stabilize `slice_as_chunks` library feature) - rust-lang#140022 (allow deref patterns to move out of boxes) - rust-lang#140276 (Do not compute type_of for impl item if impl where clauses are unsatisfied) - rust-lang#140302 (Move inline asm check to typeck, properly handle aliases) - rust-lang#140323 (Implement the internal feature `cfg_target_has_reliable_f16_f128`) - rust-lang#140391 (Rename sub_ptr to offset_from_unsigned in docs) - rust-lang#140394 (Make bootstrap git tests more self-contained) - rust-lang#140396 (Workaround for windows-gnu rust-lld test failure) - rust-lang#140402 (only return nested goals for `Certainty::Yes`) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#140302 - compiler-errors:inline_asm-bug, r=lcnr Move inline asm check to typeck, properly handle aliases Pull `InlineAsmCtxt` down to `rustc_hir_typeck`, and instead of using things like `Ty::is_copy`, use the `InferCtxt`-aware methods. To fix rust-lang/trait-system-refactor-initiative#189, we also add a `try_structurally_resolve_*` call to `expr_ty`. r? lcnr
[DO NOT MERGE] bootstrap with `-Znext-solver=globally` A revival of rust-lang#124812. Current status: ~~`./x.py b --stage 2` passes 🎉~~ `try` builds succeed 🎉 🎉 🎉 ~~[top 100 most downloaded crates on crates.io compile](rust-lang#133502 (comment) [top 1000 most downloaded crates on crates.io compile](rust-lang#133502 (comment)) [first perf run](rust-lang#133502 (comment)) 👻 ### in-flight changes - rust-lang#124852, unsure whether I actually want to land this PR for now - rust-lang#139587 - https://github.com/lcnr/rust/tree/opaque-type-method-call - rust-lang#140302 - rust-lang#140276 - rust-lang#140260 - rust-lang#140405 r? `@ghost`
Pull
InlineAsmCtxt
down torustc_hir_typeck
, and instead of using things likeTy::is_copy
, use theInferCtxt
-aware methods. To fix rust-lang/trait-system-refactor-initiative#189, we also add atry_structurally_resolve_*
call toexpr_ty
.r? lcnr