mirror of
https://github.com/github/semantic.git
synced 2024-11-28 01:47:01 +03:00
Implement Storable for TSLength.
This commit is contained in:
parent
cb08d79464
commit
76e086cf8c
@ -31,6 +31,13 @@ foreign import ccall "prototype/External/tree-sitter/include/tree_sitter/runtime
|
||||
|
||||
data TSLength = TsLength !CSize !CSize
|
||||
deriving (Show, Eq, Generic, CStorable)
|
||||
|
||||
instance Storable TSLength where
|
||||
alignment l = cAlignment l
|
||||
sizeOf l = cSizeOf l
|
||||
peek p = cPeek p
|
||||
poke p l = cPoke p l
|
||||
|
||||
data TSNode = TsNode !(Foreign.Ptr ()) !TSLength
|
||||
deriving (Show, Eq, Generic, CStorable)
|
||||
foreign import ccall "prototype/External/tree-sitter/include/tree_sitter/runtime.h ts_document_root_node" ts_document_root_node :: Foreign.Ptr TSDocument -> IO TSNode
|
||||
|
Loading…
Reference in New Issue
Block a user