diff --git a/src/Data/Language/Ruby/AST.hs b/src/Data/Language/Ruby/AST.hs index 121b6d3..8eadf63 100644 --- a/src/Data/Language/Ruby/AST.hs +++ b/src/Data/Language/Ruby/AST.hs @@ -58,7 +58,7 @@ instance FromJSON Begin where (Aeson.String "begin":xs) -> Begin <$> traverse parseJSON xs _ -> Begin . pure <$> parseJSON (Aeson.Array as) --- Should be 'expression' +-- Maybe should be 'expression'. data Statement = StmtModule Module | StmtDef Def @@ -198,9 +198,6 @@ instance FromJSON Block where <*> parseJSON begin _ -> empty --- | It's super confusing that I've already defined a node in my AST --- called args. This one correspond to the AST node with the label --- "args" as reported by `ruby-parse`. newtype Args = Args [Arg] deriving stock instance Show Args @@ -339,7 +336,7 @@ instance FromJSON Def where <*> parseMaybe begin _ -> empty --- | N.B.: 'Defs' is not meant to be the plural form of 'Def'! +-- | N.B.: 'Defs' is *not* meant to be the plural form of 'Def'! data Defs = Defs -- Is it really possible to put an arbitrary expression here? The -- parser certainly allows it. E.g. defining @@ -486,7 +483,6 @@ instance FromJSON Self where [Aeson.String "self"] -> pure Self _ -> empty - data Cbase = Cbase deriving stock instance Show Cbase @@ -500,7 +496,6 @@ instance FromJSON Cbase where [Aeson.String "cbase"] -> pure Cbase _ -> empty - data Nil = Nil deriving stock instance Show Nil