mirror of
https://github.com/github/semantic.git
synced 2024-12-01 09:15:01 +03:00
Merge branch 'master' into copointed
This commit is contained in:
commit
6be5555649
@ -22,6 +22,8 @@ data Category =
|
||||
| IntegerLiteral
|
||||
-- | A symbol literal.
|
||||
| SymbolLiteral
|
||||
-- | An array literal.
|
||||
| ArrayLiteral
|
||||
-- | A non-standard category, which can be used for comparability.
|
||||
| Other String
|
||||
deriving (Eq, Show, Ord)
|
||||
|
@ -43,6 +43,7 @@ styleName category = "category-" ++ case category of
|
||||
StringLiteral -> "string"
|
||||
SymbolLiteral -> "symbol"
|
||||
IntegerLiteral -> "integer"
|
||||
ArrayLiteral -> "array"
|
||||
Other string -> string
|
||||
|
||||
-- | Pick the class name for a split patch.
|
||||
|
@ -40,6 +40,7 @@ defaultCategoryForNodeName name = case name of
|
||||
"string" -> Set.singleton StringLiteral
|
||||
"integer" -> Set.singleton IntegerLiteral
|
||||
"symbol" -> Set.singleton SymbolLiteral
|
||||
"array" -> Set.singleton ArrayLiteral
|
||||
_ -> Set.singleton (Other name)
|
||||
|
||||
-- | Given a constructor and a tree sitter document, return a parser.
|
||||
|
Loading…
Reference in New Issue
Block a user