From 711164a7a24ab832006b72cac162e78cf434861a Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Sun, 4 Aug 2019 11:11:37 +0200 Subject: Remove old-style optional literals --- dhall/src/phase/normalize.rs | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'dhall/src/phase/normalize.rs') diff --git a/dhall/src/phase/normalize.rs b/dhall/src/phase/normalize.rs index 35d32cb..f3684d1 100644 --- a/dhall/src/phase/normalize.rs +++ b/dhall/src/phase/normalize.rs @@ -611,9 +611,9 @@ fn apply_binop<'a>(o: BinOp, x: &'a Thunk, y: &'a Thunk) -> Option> { pub fn normalize_one_layer(expr: ExprF) -> Value { use Value::{ - BoolLit, DoubleLit, EmptyListLit, EmptyOptionalLit, IntegerLit, Lam, - NEListLit, NEOptionalLit, NaturalLit, Pi, RecordLit, RecordType, - TextLit, UnionConstructor, UnionLit, UnionType, + BoolLit, DoubleLit, EmptyListLit, IntegerLit, Lam, NEListLit, + NEOptionalLit, NaturalLit, Pi, RecordLit, RecordType, TextLit, + UnionConstructor, UnionLit, UnionType, }; let ret = match expr { @@ -639,10 +639,6 @@ pub fn normalize_one_layer(expr: ExprF) -> Value { ExprF::NaturalLit(n) => Ret::Value(NaturalLit(n)), ExprF::IntegerLit(n) => Ret::Value(IntegerLit(n)), ExprF::DoubleLit(n) => Ret::Value(DoubleLit(n)), - ExprF::OldOptionalLit(None, t) => { - Ret::Value(EmptyOptionalLit(TypeThunk::from_thunk(t))) - } - ExprF::OldOptionalLit(Some(e), _) => Ret::Value(NEOptionalLit(e)), ExprF::SomeLit(e) => Ret::Value(NEOptionalLit(e)), ExprF::EmptyListLit(t) => { Ret::Value(EmptyListLit(TypeThunk::from_thunk(t))) -- cgit v1.2.3