Allow mir::Place
to be used as a key in hashtables.
This commit is contained in:
parent
e437e499d1
commit
ef64ace8aa
1 changed files with 2 additions and 2 deletions
|
@ -1136,7 +1136,7 @@ impl<'tcx> Debug for Statement<'tcx> {
|
||||||
|
|
||||||
/// A path to a value; something that can be evaluated without
|
/// A path to a value; something that can be evaluated without
|
||||||
/// changing or disturbing program state.
|
/// changing or disturbing program state.
|
||||||
#[derive(Clone, PartialEq, RustcEncodable, RustcDecodable)]
|
#[derive(Clone, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
|
||||||
pub enum Place<'tcx> {
|
pub enum Place<'tcx> {
|
||||||
/// local variable
|
/// local variable
|
||||||
Local(Local),
|
Local(Local),
|
||||||
|
@ -1150,7 +1150,7 @@ pub enum Place<'tcx> {
|
||||||
|
|
||||||
/// The def-id of a static, along with its normalized type (which is
|
/// The def-id of a static, along with its normalized type (which is
|
||||||
/// stored to avoid requiring normalization when reading MIR).
|
/// stored to avoid requiring normalization when reading MIR).
|
||||||
#[derive(Clone, PartialEq, RustcEncodable, RustcDecodable)]
|
#[derive(Clone, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
|
||||||
pub struct Static<'tcx> {
|
pub struct Static<'tcx> {
|
||||||
pub def_id: DefId,
|
pub def_id: DefId,
|
||||||
pub ty: Ty<'tcx>,
|
pub ty: Ty<'tcx>,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue