From 9f9e7ec6353fc66c40d7950fc7a5f36547eec727 Mon Sep 17 00:00:00 2001 From: there# <84727708+ForgottenGensym@users.noreply.github.com> Date: Tue, 1 Jun 2021 09:26:35 -0400 Subject: [PATCH] Potential fix (#1107) --- src/List.elm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/List.elm b/src/List.elm index 83f411c0..ac59e144 100644 --- a/src/List.elm +++ b/src/List.elm @@ -62,7 +62,11 @@ singleton value = -} repeat : Int -> a -> List a repeat n value = - repeatHelp [] n value + if isInfinite n then + [] + + else + repeatHelp [] n value repeatHelp : List a -> Int -> a -> List a