Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions compiler/rustc_middle/src/ty/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1031,6 +1031,8 @@ pub struct ParamEnvAnd<'tcx, T> {
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash, HashStable)]
#[derive(TypeVisitable, TypeFoldable)]
pub struct TypingEnv<'tcx> {
#[type_foldable(identity)]
#[type_visitable(ignore)]
pub typing_mode: TypingMode<'tcx>,
pub param_env: ParamEnv<'tcx>,
}
Expand Down
1 change: 0 additions & 1 deletion compiler/rustc_type_ir/src/canonical.rs
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,6 @@ impl<I: Interner> CanonicalVarKind<I> {
/// usize or f32). In order to faithfully reproduce a type, we need to
/// know what set of types a given type variable can be unified with.
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
#[derive(TypeVisitable_Generic, TypeFoldable_Generic)]
#[cfg_attr(
feature = "nightly",
derive(Decodable_NoContext, Encodable_NoContext, HashStable_NoContext)
Expand Down
7 changes: 1 addition & 6 deletions compiler/rustc_type_ir/src/const_kind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,10 @@ rustc_index::newtype_index! {

/// An inference variable for a const, for use in const generics.
#[derive(Copy, Clone, Eq, PartialEq, PartialOrd, Ord, Hash)]
#[derive(TypeVisitable_Generic, TypeFoldable_Generic)]
#[cfg_attr(feature = "nightly", derive(Encodable_NoContext, Decodable_NoContext))]
pub enum InferConst {
/// Infer the value of the const.
Var(
#[type_foldable(identity)]
#[type_visitable(ignore)]
ConstVid,
),
Var(ConstVid),
/// A fresh const variable. See `infer::freshen` for more details.
Fresh(u32),
}
Expand Down
2 changes: 0 additions & 2 deletions compiler/rustc_type_ir/src/infer_ctxt.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
use derive_where::derive_where;
#[cfg(feature = "nightly")]
use rustc_macros::{Decodable_NoContext, Encodable_NoContext, HashStable_NoContext};
use rustc_type_ir_macros::{TypeFoldable_Generic, TypeVisitable_Generic};

use crate::fold::TypeFoldable;
use crate::inherent::*;
Expand All @@ -20,7 +19,6 @@ use crate::{self as ty, Interner};
/// If neither of these functions are available, feel free to reach out to
/// t-types for help.
#[derive_where(Clone, Copy, Hash, PartialEq, Eq, Debug; I: Interner)]
#[derive(TypeVisitable_Generic, TypeFoldable_Generic)]
#[cfg_attr(
feature = "nightly",
derive(Encodable_NoContext, Decodable_NoContext, HashStable_NoContext)
Expand Down
Loading