diff options
author | Nadrieril | 2019-03-11 19:33:51 +0100 |
---|---|---|
committer | Nadrieril | 2019-03-11 19:43:19 +0100 |
commit | b916bc896851557e63b46af9aa46793472b97da7 (patch) | |
tree | fa690c2daa14fe148f708042f4a4046d80b5358b /dhall/src | |
parent | f88596e2591a143ffb82c1dc8ba0bc4a5249697e (diff) |
Fix List/fold implementation
Diffstat (limited to '')
-rw-r--r-- | dhall/src/normalize.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/dhall/src/normalize.rs b/dhall/src/normalize.rs index c8ec310..8948443 100644 --- a/dhall/src/normalize.rs +++ b/dhall/src/normalize.rs @@ -132,10 +132,10 @@ where let e2: Expr<_, _> = xs .into_iter() .rev() - .fold((**nil).clone(), |y, ys| { - let y = bx(y); - let ys = bx(ys); - dhall_expr!(cons y ys) + .fold((**nil).clone(), |acc, x| { + let x = bx(x); + let acc = bx(acc); + dhall_expr!(cons x acc) }); normalize_whnf(&e2) } |