rust/compiler/rustc_middle/src
Dylan DPC 9e70b1a033
Rollup merge of #94827 - RalfJung:offset-from-ub, r=oli-obk
CTFE/Miri: detect out-of-bounds pointers in offset_from

Also I became uneasy with aggressively doing `try_to_int` here -- this will always succeed on Miri, leading to the wrong codepath being taken. We should rather try to convert them both to pointers, and use the integer path as a fallback, so that's what I implemented now.

Hiding whitespaces helps with the diff.

Fixes https://github.com/rust-lang/miri/issues/1950

r? ``@oli-obk``
2022-03-11 20:29:45 +01:00
..
dep_graph Adopt let_else in even more places 2022-02-16 22:43:39 +01:00
hir resolve: Fix incorrect results of opt_def_kind query for some built-in macros 2022-02-24 22:54:36 +03:00
infer Inline UnifyKey::index and UnifyKey::from_index 2022-02-15 19:07:06 +01:00
middle Auto merge of #90253 - Kobzol:hash-stable-sort-index-map, r=cjgillot 2022-03-11 16:37:55 +00:00
mir Rollup merge of #94827 - RalfJung:offset-from-ub, r=oli-obk 2022-03-11 20:29:45 +01:00
query rename ErrorReported -> ErrorGuaranteed 2022-03-02 09:45:25 -06:00
thir mention ignored fields of ExprKind::StaticRef 2022-03-08 15:44:06 +01:00
traits rename ErrorReported -> ErrorGuaranteed 2022-03-02 09:45:25 -06:00
ty Auto merge of #94276 - scottmcm:primitive-clone, r=oli-obk 2022-03-11 01:51:49 +00:00
util Use AddAssign impl 2021-11-09 23:47:36 +01:00
arena.rs Clarify Layout interning. 2022-03-07 13:41:47 +11:00
lib.rs add #[rustc_pass_by_value] to more types 2022-03-08 15:39:52 +01:00
lint.rs Use Vec for expectations to have a constant order (RFC-2383) 2022-03-02 18:10:07 +01:00
macros.rs Rename TypeFolderFallible to FallibleTypeFolder 2021-12-02 16:14:18 +00:00
metadata.rs resolve/metadata: Stop encoding macros as reexports 2022-02-24 22:55:40 +03:00
tests.rs mv compiler to compiler/ 2020-08-30 18:45:07 +03:00
thir.rs treat literals in ExprKind::StaticRef as mir::ConstantKind::Val 2022-03-08 10:04:28 +01:00