rust/compiler/rustc_const_eval/src/const_eval
bors dd2559e08e Auto merge of #116167 - RalfJung:structural-eq, r=lcnr
remove StructuralEq trait

The documentation given for the trait is outdated: *all* function pointers implement `PartialEq` and `Eq` these days. So the `StructuralEq` trait doesn't really seem to have any reason to exist any more.

One side-effect of this PR is that we allow matching on some consts that do not implement `Eq`. However, we already allowed matching on floats and consts containing floats, so this is not new, it is just allowed in more cases now. IMO it makes no sense at all to allow float matching but also sometimes require an `Eq` instance. If we want to require `Eq` we should adjust https://github.com/rust-lang/rust/pull/115893 to check for `Eq`, and rule out float matching for good.

Fixes https://github.com/rust-lang/rust/issues/115881
2024-01-26 00:17:00 +00:00
..
error.rs Rename TyCtxt::emit_spanned_lint as TyCtxt::emit_node_span_lint. 2024-01-23 08:09:05 +11:00
eval_queries.rs const-eval interner: from-scratch rewrite using mutability information from provenance rather than types 2024-01-22 09:28:00 +01:00
fn_queries.rs Move some methods from tcx.hir() to tcx 2023-12-12 06:40:29 -08:00
machine.rs Auto merge of #119911 - NCGThompson:is-statically-known, r=oli-obk 2024-01-25 05:16:53 +00:00
mod.rs Remove Session methods that duplicate DiagCtxt methods. 2023-12-24 08:05:28 +11:00
valtrees.rs remove StructuralEq trait 2024-01-24 07:56:23 +01:00