1
1
mirror of https://github.com/github/semantic.git synced 2024-12-21 22:01:46 +03:00

Merge remote-tracking branch 'origin/master' into floats-scientific

This commit is contained in:
Patrick Thomson 2018-03-07 14:56:10 -05:00
commit 606a1321dd
34 changed files with 145 additions and 102 deletions

View File

@ -382,10 +382,14 @@ importDeclaration :: Assignment
importDeclaration = makeTerm'' <$> symbol ImportDeclaration <*> children (manyTerm (importSpec <|> importSpecList)) importDeclaration = makeTerm'' <$> symbol ImportDeclaration <*> children (manyTerm (importSpec <|> importSpecList))
where where
importSpec = makeTerm <$> symbol ImportSpec <*> children (namedImport <|> plainImport) importSpec = makeTerm <$> symbol ImportSpec <*> children (namedImport <|> plainImport)
namedImport = flip Declaration.Import <$> expression <*> expression <*> pure [] namedImport = flip Declaration.Import <$> expression' <*> expression' <*> pure []
plainImport = Declaration.Import <$> expression <*> emptyTerm <*> pure [] plainImport = Declaration.Import <$> expression' <*> emptyTerm <*> pure []
importSpecList = makeTerm <$> symbol ImportSpecList <*> children (manyTerm (importSpec <|> comment)) importSpecList = makeTerm <$> symbol ImportSpecList <*> children (manyTerm (importSpec <|> comment))
expression' = expression <|> dotImport <|> blankImport
dotImport = makeTerm <$> symbol Dot <*> (Syntax.Identifier <$> source)
blankImport = makeTerm <$> symbol BlankIdentifier <*> (Syntax.Identifier <$> source)
indexExpression :: Assignment indexExpression :: Assignment
indexExpression = makeTerm <$> symbol IndexExpression <*> children (Expression.Subscript <$> expression <*> manyTerm expression) indexExpression = makeTerm <$> symbol IndexExpression <*> children (Expression.Subscript <$> expression <*> manyTerm expression)

View File

@ -20,9 +20,9 @@
( (
(Identifier) (Identifier)
(Identifier)) (Identifier))
(Identifier)
(Identifier)
( (
(Identifier)
(Identifier)
(Identifier) (Identifier)
(Identifier))) (Identifier)))
([])) ([]))
@ -32,8 +32,10 @@
->(Identifier) } ->(Identifier) }
([]) ([])
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
([])) ([]))
(Function (Function
(Empty) (Empty)

View File

@ -20,9 +20,9 @@
( (
(Identifier) (Identifier)
(Identifier)) (Identifier))
(Identifier)
(Identifier)
( (
(Identifier)
(Identifier)
(Identifier) (Identifier)
(Identifier))) (Identifier)))
([])) ([]))
@ -32,8 +32,10 @@
->(Identifier) } ->(Identifier) }
([]) ([])
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
([])) ([]))
(Function (Function
(Empty) (Empty)

View File

@ -18,9 +18,9 @@
( (
(Identifier) (Identifier)
(Identifier)) (Identifier))
(Identifier)
(Identifier)
( (
(Identifier)
(Identifier)
(Identifier) (Identifier)
(Identifier))) (Identifier)))
([])) ([]))
@ -29,8 +29,10 @@
(Identifier) (Identifier)
([]) ([])
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
([])) ([]))
(Function (Function
(Empty) (Empty)

View File

@ -18,9 +18,9 @@
( (
(Identifier) (Identifier)
(Identifier)) (Identifier))
(Identifier)
(Identifier)
( (
(Identifier)
(Identifier)
(Identifier) (Identifier)
(Identifier))) (Identifier)))
([])) ([]))
@ -29,8 +29,10 @@
(Identifier) (Identifier)
([]) ([])
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
([])) ([]))
(Function (Function
(Empty) (Empty)

View File

@ -16,10 +16,12 @@
{ (Identifier) { (Identifier)
->(Identifier) }) ->(Identifier) })
( (
{ (Identifier) (
->(Identifier) } { (Identifier)
{ (Identifier) ->(Identifier) })
->(Identifier) }) (
{ (Identifier)
->(Identifier) }))
(Return (Return
( (
(Integer) (Integer)

View File

@ -16,10 +16,12 @@
{ (Identifier) { (Identifier)
->(Identifier) }) ->(Identifier) })
( (
{ (Identifier) (
->(Identifier) } { (Identifier)
{ (Identifier) ->(Identifier) })
->(Identifier) }) (
{ (Identifier)
->(Identifier) }))
(Return (Return
( (
(Integer) (Integer)

View File

@ -14,8 +14,10 @@
(Identifier) (Identifier)
(Identifier)) (Identifier))
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
(Return (Return
( (
(Integer) (Integer)

View File

@ -14,8 +14,10 @@
(Identifier) (Identifier)
(Identifier)) (Identifier))
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
(Return (Return
( (
(Integer) (Integer)

View File

@ -10,8 +10,9 @@
{ (Identifier) { (Identifier)
->(Identifier) } ->(Identifier) }
(Function (Function
{ (Identifier) (
->(Identifier) } { (Identifier)
->(Identifier) })
{ (Identifier) { (Identifier)
->(Identifier) })) ->(Identifier) }))
(Type (Type
@ -19,13 +20,17 @@
->(Identifier) } ->(Identifier) }
(Function (Function
( (
{-(Identifier)-} {-(
(Identifier) {-(Identifier)-})-}
{+(Identifier)+}) (
( (Identifier))
{+( {+(
{+(Identifier)+})+})
(
(
{+(BidirectionalChannel {+(BidirectionalChannel
{+(Identifier)+})+})+} {+(Identifier)+})+}
{-(Identifier)-} {-(Identifier)-})
(Identifier)) (
(Identifier)))
(Empty)))))) (Empty))))))

View File

@ -10,8 +10,9 @@
{ (Identifier) { (Identifier)
->(Identifier) } ->(Identifier) }
(Function (Function
{ (Identifier) (
->(Identifier) } { (Identifier)
->(Identifier) })
{ (Identifier) { (Identifier)
->(Identifier) })) ->(Identifier) }))
(Type (Type
@ -19,13 +20,17 @@
->(Identifier) } ->(Identifier) }
(Function (Function
( (
{-(Identifier)-}
(Identifier)
{+(Identifier)+})
(
{+(Identifier)+}
{-( {-(
{-(Identifier)-})-}
(
(Identifier))
{+(
{+(Identifier)+})+})
(
(
{+(Identifier)+}
{-(BidirectionalChannel {-(BidirectionalChannel
{-(Identifier)-})-})-} {-(Identifier)-})-})
(Identifier)) (
(Identifier)))
(Empty)))))) (Empty))))))

View File

@ -9,15 +9,20 @@
(Type (Type
(Identifier) (Identifier)
(Function (Function
(Identifier) (
(Identifier))
(Identifier))) (Identifier)))
(Type (Type
(Identifier) (Identifier)
(Function (Function
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
(Empty)))))) (Empty))))))

View File

@ -9,17 +9,21 @@
(Type (Type
(Identifier) (Identifier)
(Function (Function
(Identifier) (
(Identifier))
(Identifier))) (Identifier)))
(Type (Type
(Identifier) (Identifier)
(Function (Function
( (
(Identifier) (
(Identifier)) (Identifier))
(
(Identifier)))
( (
( (
(BidirectionalChannel (BidirectionalChannel
(Identifier))) (Identifier)))
(Identifier)) (
(Identifier)))
(Empty)))))) (Empty))))))

View File

@ -9,7 +9,7 @@
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }
(Empty)) (Identifier))
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }

View File

@ -9,7 +9,7 @@
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }
(Empty)) (Identifier))
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }

View File

@ -7,7 +7,7 @@
(Empty)) (Empty))
(Import (Import
(TextElement) (TextElement)
(Empty)) (Identifier))
(Import (Import
(TextElement) (TextElement)
(Identifier))) (Identifier)))

View File

@ -7,7 +7,7 @@
(Empty)) (Empty))
(Import (Import
(TextElement) (TextElement)
(Empty)) (Identifier))
(Import (Import
(TextElement) (TextElement)
(Identifier))) (Identifier)))

View File

@ -127,8 +127,7 @@
( (
{ (Identifier) { (Identifier)
->(Identifier) } ->(Identifier) }
( { (Identifier)
{ (Identifier) ->(Identifier) }
->(Identifier) } (Identifier))
(Identifier)))
([]))) ([])))

View File

@ -127,8 +127,7 @@
( (
{ (Identifier) { (Identifier)
->(Identifier) } ->(Identifier) }
( { (Identifier)
{ (Identifier) ->(Identifier) }
->(Identifier) } (Identifier))
(Identifier)))
([]))) ([])))

View File

@ -92,7 +92,6 @@
(Identifier) (Identifier)
( (
(Identifier) (Identifier)
( (Identifier)
(Identifier) (Identifier))
(Identifier)))
([]))) ([])))

View File

@ -106,7 +106,6 @@
(Identifier) (Identifier)
( (
(Identifier) (Identifier)
( (Identifier)
(Identifier) (Identifier))
(Identifier)))
([]))) ([])))

View File

@ -8,7 +8,7 @@
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }
(Empty)) (Identifier))
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }

View File

@ -8,7 +8,7 @@
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }
(Empty)) (Identifier))
(Import (Import
{ (TextElement) { (TextElement)
->(TextElement) } ->(TextElement) }

View File

@ -6,7 +6,7 @@
(Empty)) (Empty))
(Import (Import
(TextElement) (TextElement)
(Empty)) (Identifier))
(Import (Import
(TextElement) (TextElement)
(Identifier)) (Identifier))

View File

@ -6,7 +6,7 @@
(Empty)) (Empty))
(Import (Import
(TextElement) (TextElement)
(Empty)) (Identifier))
(Import (Import
(TextElement) (TextElement)
(Identifier)) (Identifier))

View File

@ -6,11 +6,12 @@
(Identifier) (Identifier)
([]) ([])
( (
(TypeConversion (Pointer
(Pointer (Call
(Identifier)) (Identifier)
{ (Identifier) { (Identifier)
->(Identifier) }) ->(Identifier) }
(Empty)))
(Call (Call
(Pointer (Pointer
(Identifier)) (Identifier))

View File

@ -6,11 +6,12 @@
(Identifier) (Identifier)
([]) ([])
( (
(TypeConversion (Pointer
(Pointer (Call
(Identifier)) (Identifier)
{ (Identifier) { (Identifier)
->(Identifier) }) ->(Identifier) }
(Empty)))
(Call (Call
(Pointer (Pointer
(Identifier)) (Identifier))

View File

@ -6,10 +6,11 @@
(Identifier) (Identifier)
([]) ([])
( (
(TypeConversion (Pointer
(Pointer (Call
(Identifier)) (Identifier)
(Identifier)) (Identifier)
(Empty)))
(Call (Call
(Pointer (Pointer
(Identifier)) (Identifier))

View File

@ -6,10 +6,11 @@
(Identifier) (Identifier)
([]) ([])
( (
(TypeConversion (Pointer
(Pointer (Call
(Identifier)) (Identifier)
(Identifier)) (Identifier)
(Empty)))
(Call (Call
(Pointer (Pointer
(Identifier)) (Identifier))

View File

@ -28,7 +28,8 @@
{ (Identifier) { (Identifier)
->(Identifier) } ->(Identifier) }
( (
(Identifier) (
(Identifier))
(Variadic (Variadic
(Identifier) (Identifier)
(Empty))) (Empty)))

View File

@ -28,7 +28,8 @@
{ (Identifier) { (Identifier)
->(Identifier) } ->(Identifier) }
( (
(Identifier) (
(Identifier))
(Variadic (Variadic
(Identifier) (Identifier)
(Empty))) (Empty)))

View File

@ -25,7 +25,8 @@
(Empty) (Empty)
(Identifier) (Identifier)
( (
(Identifier) (
(Identifier))
(Variadic (Variadic
(Identifier) (Identifier)
(Empty))) (Empty)))

View File

@ -25,7 +25,8 @@
(Empty) (Empty)
(Identifier) (Identifier)
( (
(Identifier) (
(Identifier))
(Variadic (Variadic
(Identifier) (Identifier)
(Empty))) (Empty)))

@ -1 +1 @@
Subproject commit a7c77ef5459e4f610bd82ce203984f408bc106c2 Subproject commit 19fd8594796a26b26c0545897fd46f547f316be8