From efe4b340bebaa7ef8bce6e69194959b126c5fade Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Fri, 10 Apr 2020 12:10:53 +0100 Subject: Deserialize `Prelude.Map` and `toMap` to a map instead of a list --- dhall/src/syntax/ast/label.rs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'dhall/src/syntax') diff --git a/dhall/src/syntax/ast/label.rs b/dhall/src/syntax/ast/label.rs index 43c3f53..2abde80 100644 --- a/dhall/src/syntax/ast/label.rs +++ b/dhall/src/syntax/ast/label.rs @@ -24,6 +24,12 @@ impl From<&Label> for String { } } +impl std::borrow::Borrow for Label { + fn borrow(&self) -> &str { + self.0.as_ref() + } +} + impl Label { pub fn from_str(s: &str) -> Label { Label(s.into()) -- cgit v1.2.3