From 96192b07807fb6afbbcac3166401b6795b214ff9 Mon Sep 17 00:00:00 2001 From: Jechol Lee Date: Fri, 14 Aug 2020 19:53:50 +0900 Subject: gleam format --- src/gleam/iterator.gleam | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/gleam/iterator.gleam b/src/gleam/iterator.gleam index 7283c15..2365317 100644 --- a/src/gleam/iterator.gleam +++ b/src/gleam/iterator.gleam @@ -168,7 +168,11 @@ pub fn to_list(iterator: Iterator(element)) -> List(element) { |> list.reverse } -fn do_take(continuation: fn() -> Action(e), desired: Int, acc: List(e)) -> List(e) { +fn do_take( + continuation: fn() -> Action(e), + desired: Int, + acc: List(e), +) -> List(e) { case desired > 0 { True -> case continuation() { Continue( @@ -262,7 +266,10 @@ pub fn map(over iterator: Iterator(a), with f: fn(a) -> b) -> Iterator(b) { |> Iterator } -fn do_filter(continuation: fn() -> Action(e), predicate: fn(e) -> Bool) -> fn() -> Action(e) { +fn do_filter( + continuation: fn() -> Action(e), + predicate: fn(e) -> Bool, +) -> fn() -> Action(e) { fn() { case continuation() { Continue(e, iterator) -> case predicate(e) { -- cgit v1.2.3