mirror of
https://github.com/github/semantic.git
synced 2024-12-25 07:55:12 +03:00
++haskell-tree-sitter to use halt_on_error
This commit is contained in:
parent
9b3329b41a
commit
c9f69c32b5
@ -40,7 +40,7 @@ treeSitterParser language grammar blob = do
|
||||
ts_document_set_language document grammar
|
||||
withCStringLen (toText (source blob)) $ \ (source, len) -> do
|
||||
ts_document_set_input_string_with_length document source len
|
||||
ts_document_parse document
|
||||
ts_document_parse_halt_on_error document
|
||||
term <- documentToTerm language document blob
|
||||
ts_document_free document
|
||||
pure term
|
||||
@ -55,7 +55,7 @@ parseRubyToAST source = do
|
||||
ts_document_set_language document Ruby.tree_sitter_ruby
|
||||
root <- withCStringLen (toText source) $ \ (source, len) -> do
|
||||
ts_document_set_input_string_with_length document source len
|
||||
ts_document_parse document
|
||||
ts_document_parse_halt_on_error document
|
||||
alloca (\ rootPtr -> do
|
||||
ts_document_root_node_p document rootPtr
|
||||
peek rootPtr)
|
||||
|
2
vendor/haskell-tree-sitter
vendored
2
vendor/haskell-tree-sitter
vendored
@ -1 +1 @@
|
||||
Subproject commit dd1b9f9b827871085dfa58108f570b59890bcaf7
|
||||
Subproject commit 11361887f9d17170293413bf2717b724dc48fac8
|
Loading…
Reference in New Issue
Block a user