From c7cc8467ca1835c8f96ccb5be7c976a26d262433 Mon Sep 17 00:00:00 2001 From: "Juan J. Martinez" Date: Wed, 20 Dec 2023 19:53:05 +0000 Subject: Updated to use GHC 9.4.x and floating dependencies --- src/Micro/Parser.hs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/Micro/Parser.hs') diff --git a/src/Micro/Parser.hs b/src/Micro/Parser.hs index 48e1900..6b6fafb 100644 --- a/src/Micro/Parser.hs +++ b/src/Micro/Parser.hs @@ -10,19 +10,17 @@ import Data.Maybe (isJust) import Micro.Ast import Micro.Lexer import Text.Parsec -import qualified Text.Parsec.Expr as E +import Text.Parsec.Expr qualified as E import Text.Parsec.String (Parser) binary :: String -> Op -> E.Assoc -> E.Operator String () Identity Expr -binary s f assoc = +binary s f = E.Infix ( reservedOp s >> do -- FIXME: this is the second operand - pos <- getPosition - return $ BinOp f pos + BinOp f <$> getPosition ) - assoc opTable :: [[E.Operator String () Identity Expr]] opTable = -- cgit v1.2.3