diff options
Diffstat (limited to 'src/syntax/span.rs')
| -rw-r--r-- | src/syntax/span.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/syntax/span.rs b/src/syntax/span.rs index 10188ed4..e5c6912b 100644 --- a/src/syntax/span.rs +++ b/src/syntax/span.rs @@ -4,7 +4,7 @@ use std::fmt::{self, Display, Formatter}; /// Annotates a value with the part of the source code it corresponds to. -#[derive(Copy, Clone, Eq, PartialEq)] +#[derive(Copy, Clone, Eq, PartialEq, Hash)] pub struct Spanned<T> { pub v: T, pub span: Span, @@ -37,7 +37,7 @@ impl<T> Display for Spanned<T> where T: std::fmt::Debug { debug_display!(Spanned; T where T: std::fmt::Debug); /// Describes a slice of source code. -#[derive(Copy, Clone, Eq, PartialEq)] +#[derive(Copy, Clone, Eq, PartialEq, Hash)] pub struct Span { pub start: Position, pub end: Position, |
