From 96e81584b654e20e9f2ec5801b83b504712a1e98 Mon Sep 17 00:00:00 2001 From: rhiannon morris Date: Wed, 4 May 2022 15:30:37 +0200 Subject: [PATCH] =?UTF-8?q?isCons=20=E2=86=92=20NonEmpty?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Quox/Lexer.idr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Quox/Lexer.idr b/src/Quox/Lexer.idr index 46a1cae..956840d 100644 --- a/src/Quox/Lexer.idr +++ b/src/Quox/Lexer.idr @@ -73,7 +73,7 @@ skip lex = match lex $ const Nothing simple : List String -> a -> Tokenizer (Maybe a) simple str = match (choice $ map exact str) . const . Just -choice : (xs : List (Tokenizer a)) -> {auto 0 _ : So (isCons xs)} -> Tokenizer a +choice : (xs : List (Tokenizer a)) -> {auto 0 _ : NonEmpty xs} -> Tokenizer a choice (t :: ts) = foldl (\a, b => a <|> b) t ts match : Lexer -> (String -> a) -> Tokenizer (Maybe a)