From 929db5780ceff67a042d6417d08d224da59efc7a Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Sun, 5 May 2019 01:12:19 +0200 Subject: Fix Integer equality --- dhall/src/normalize.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'dhall') diff --git a/dhall/src/normalize.rs b/dhall/src/normalize.rs index c11dd82..85df5e2 100644 --- a/dhall/src/normalize.rs +++ b/dhall/src/normalize.rs @@ -1305,9 +1305,9 @@ fn normalize_whnf(ctx: NormalizationContext, expr: InputSubExpr) -> Value { fn normalize_one_layer(expr: ExprF) -> Value { use Value::{ - BoolLit, EmptyListLit, EmptyOptionalLit, Lam, NEListLit, NEOptionalLit, - NaturalLit, Pi, RecordLit, RecordType, TextLit, UnionConstructor, - UnionLit, UnionType, + BoolLit, EmptyListLit, EmptyOptionalLit, IntegerLit, Lam, NEListLit, + NEOptionalLit, NaturalLit, Pi, RecordLit, RecordType, TextLit, + UnionConstructor, UnionLit, UnionType, }; // Small helper enum to avoid repetition @@ -1338,7 +1338,8 @@ fn normalize_one_layer(expr: ExprF) -> Value { ExprF::Const(c) => RetValue(Value::Const(c)), ExprF::BoolLit(b) => RetValue(BoolLit(b)), ExprF::NaturalLit(n) => RetValue(NaturalLit(n)), - ExprF::IntegerLit(_) | ExprF::DoubleLit(_) => RetExpr(expr), + ExprF::IntegerLit(n) => RetValue(IntegerLit(n)), + ExprF::DoubleLit(_) => RetExpr(expr), ExprF::OldOptionalLit(None, t) => { RetValue(EmptyOptionalLit(TypeThunk::from_thunk(t))) } -- cgit v1.2.3