From 2020d41874f7681ba948a40d8e8f8993d651a81c Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Thu, 9 May 2019 12:48:41 +0200 Subject: Detect duplicate record fields in typecheck --- dhall/src/core/value.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'dhall/src/core/value.rs') diff --git a/dhall/src/core/value.rs b/dhall/src/core/value.rs index 72949be..8fa24c7 100644 --- a/dhall/src/core/value.rs +++ b/dhall/src/core/value.rs @@ -1,4 +1,4 @@ -use std::collections::BTreeMap; +use std::collections::HashMap; use dhall_proc_macros as dhall; use dhall_syntax::{ @@ -49,11 +49,11 @@ pub(crate) enum Value { NEOptionalLit(Thunk), EmptyListLit(TypeThunk), NEListLit(Vec), - RecordLit(BTreeMap), - RecordType(BTreeMap), - UnionType(BTreeMap>), - UnionConstructor(Label, BTreeMap>), - UnionLit(Label, Thunk, BTreeMap>), + RecordLit(HashMap), + RecordType(HashMap), + UnionType(HashMap>), + UnionConstructor(Label, HashMap>), + UnionLit(Label, Thunk, HashMap>), // Invariant: this must not contain interpolations that are themselves TextLits, and // contiguous text values must be merged. TextLit(Vec>), -- cgit v1.2.3