1
1
mirror of https://github.com/github/semantic.git synced 2024-12-29 01:42:43 +03:00

maybe introduce a separate datatype for formats?

This commit is contained in:
Ayman Nadeem 2019-10-03 18:12:04 -04:00
parent 40844a6c16
commit eaa38b3736

View File

@ -26,6 +26,9 @@ generateAST :: SemanticAST -> IO ()
generateAST (SemanticAST file _) = do
bytestring <- Data.ByteString.readFile file
print =<< parseByteString @TreeSitter.Python.AST.Module @(Range, Span) tree_sitter_python bytestring
-- TODO: Define formats for json, sexpression, etc.
data Format = Show
data SemanticAST = SemanticAST
{ sourceFilePath :: Prelude.String
, format :: Prelude.String