~jojo/Carth

2219ea535f4a0fd0afd9000ba5c6918c6b276210 — JoJo 3 months ago bf37062
remove no longer applicable TODOs
3 files changed, 1 insertions(+), 13 deletions(-)

M src/Check.hs
M src/Parser.hs
M src/SrcPos.hs
M src/Check.hs => src/Check.hs +1 -7
@@ 113,13 113,7 @@ builtinDataTypes' =
      )
    , ("Unit", [], [unit'])
    , ("RealWorld", [], [("UnsafeRealWorld", [])])
    , ( "Bool"
      , []
      , [("False", []), ("True", [])]
      )
    -- TODO: Since Carth is not otherwise a lazy language, our IO computations should
    --       maybe not be either. Diverge from Haskell and just make IO a sort of
    --       marker without the realworld function shebang.
    , ("Bool", [], [("False", []), ("True", [])])
    , ( "IO"
      , [TVImplicit "a"]
      , [ ( "IO"

M src/Parser.hs => src/Parser.hs +0 -5
@@ 21,11 21,6 @@ import Pretty
data Err = Err { errLength :: Word, errPos :: SrcPos, errExpecteds :: Set String }
    deriving (Show, Eq)

-- TODO: Semigroup instance for the error type should select the one with the longest
--       match. We need to keep track of how long the match is.
--
--       If two matches are of the same / no length, combine the sets of "expected"s of
--       both. So it's like "expected keyword extern or keyword data".
instance Semigroup Err where
    (<>) e1 e2
        | e2 == mempty = e1

M src/SrcPos.hs => src/SrcPos.hs +0 -1
@@ 6,7 6,6 @@ import Text.Megaparsec.Pos
import Data.Data


-- TODO: macro invocation stack
data SrcPos =
    SrcPos { srcName :: FilePath
           , srcLine :: Word