summaryrefslogtreecommitdiff
path: root/src/syntax
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2020-10-05 16:34:20 +0200
committerLaurenz <laurmaedje@gmail.com>2020-10-05 16:44:35 +0200
commit5a7a32a9bafbcc69077e7766451310ab5ece62bf (patch)
tree29d5fc9ec380c2bd1b63bff1fd605408e8f53eea /src/syntax
parent93eaafb236bba73cd72c8cd142279366b8afa0be (diff)
Streamline generic layouting primitives 🛫
Diffstat (limited to 'src/syntax')
-rw-r--r--src/syntax/ident.rs2
-rw-r--r--src/syntax/mod.rs2
-rw-r--r--src/syntax/span.rs8
3 files changed, 6 insertions, 6 deletions
diff --git a/src/syntax/ident.rs b/src/syntax/ident.rs
index 5ab7c73c..f8c38cfb 100644
--- a/src/syntax/ident.rs
+++ b/src/syntax/ident.rs
@@ -10,7 +10,7 @@ use unicode_xid::UnicodeXID;
/// `-` and `_` as starting and continuing characters.
///
/// [Unicode Standard]: http://www.unicode.org/reports/tr31/
-#[derive(Debug, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
+#[derive(Debug, Clone, Eq, PartialEq, Ord, PartialOrd)]
pub struct Ident(pub String);
impl Ident {
diff --git a/src/syntax/mod.rs b/src/syntax/mod.rs
index a6ae9267..a85b06a9 100644
--- a/src/syntax/mod.rs
+++ b/src/syntax/mod.rs
@@ -12,7 +12,7 @@ pub use span::*;
pub use token::*;
/// Decorations for semantic syntax highlighting.
-#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
+#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd)]
#[cfg_attr(feature = "serialize", derive(serde::Serialize))]
#[cfg_attr(feature = "serialize", serde(rename_all = "camelCase"))]
pub enum Deco {
diff --git a/src/syntax/span.rs b/src/syntax/span.rs
index 6ba9c44a..5f51d157 100644
--- a/src/syntax/span.rs
+++ b/src/syntax/span.rs
@@ -40,7 +40,7 @@ impl<T> Offset for SpanVec<T> {
}
/// A value with the span it corresponds to in the source code.
-#[derive(Default, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
+#[derive(Default, Copy, Clone, Eq, PartialEq, Ord, PartialOrd)]
#[cfg_attr(feature = "serialize", derive(serde::Serialize))]
pub struct Spanned<T> {
/// The spanned value.
@@ -108,7 +108,7 @@ impl<T: Debug> Debug for Spanned<T> {
}
/// Locates a slice of source code.
-#[derive(Copy, Clone, Ord, PartialOrd, Hash)]
+#[derive(Copy, Clone, Ord, PartialOrd)]
#[cfg_attr(feature = "serialize", derive(serde::Serialize))]
pub struct Span {
/// The inclusive start position.
@@ -209,7 +209,7 @@ impl Debug for Span {
}
/// A byte position in source code.
-#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
+#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd)]
#[cfg_attr(feature = "serialize", derive(serde::Serialize))]
pub struct Pos(pub u32);
@@ -254,7 +254,7 @@ impl Debug for Pos {
}
/// A one-indexed line-column position in source code.
-#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
+#[derive(Copy, Clone, Eq, PartialEq, Ord, PartialOrd)]
#[cfg_attr(feature = "serialize", derive(serde::Serialize))]
pub struct Location {
/// The one-indexed line.