mirror of
https://github.com/github/semantic.git
synced 2024-12-28 09:21:35 +03:00
Readability
This commit is contained in:
parent
f272d604ca
commit
64f052eea8
@ -804,8 +804,16 @@ shorthandPropertyIdentifier :: Assignment Term
|
|||||||
shorthandPropertyIdentifier = makeTerm <$> symbol Grammar.ShorthandPropertyIdentifier <*> (TypeScript.Syntax.ShorthandPropertyIdentifier <$> source)
|
shorthandPropertyIdentifier = makeTerm <$> symbol Grammar.ShorthandPropertyIdentifier <*> (TypeScript.Syntax.ShorthandPropertyIdentifier <$> source)
|
||||||
|
|
||||||
requiredParameter :: Assignment Term
|
requiredParameter :: Assignment Term
|
||||||
requiredParameter = makeRequiredParameter <$> symbol Grammar.RequiredParameter <*> children ((,,,,) <$> (term accessibilityModifier' <|> emptyTerm) <*> (term readonly' <|> emptyTerm) <*> term (identifier <|> destructuringPattern <|> this) <*> (term typeAnnotation' <|> emptyTerm) <*> (term expression <|> emptyTerm))
|
requiredParameter = makeRequiredParameter
|
||||||
where makeRequiredParameter loc (modifier, readonly, identifier, annotation, initializer) = makeTerm loc (TypeScript.Syntax.RequiredParameter [modifier, readonly, annotation] (makeTerm loc (Statement.Assignment [] identifier initializer)))
|
<$> symbol Grammar.RequiredParameter
|
||||||
|
<*> children ( (,,,,)
|
||||||
|
<$> (term accessibilityModifier' <|> emptyTerm)
|
||||||
|
<*> (term readonly' <|> emptyTerm)
|
||||||
|
<*> term (identifier <|> destructuringPattern <|> this)
|
||||||
|
<*> (term typeAnnotation' <|> emptyTerm)
|
||||||
|
<*> (term expression <|> emptyTerm))
|
||||||
|
where
|
||||||
|
makeRequiredParameter loc (modifier, readonly, identifier, annotation, initializer) = makeTerm loc (TypeScript.Syntax.RequiredParameter [modifier, readonly, annotation] (makeTerm loc (Statement.Assignment [] identifier initializer)))
|
||||||
|
|
||||||
restParameter :: Assignment Term
|
restParameter :: Assignment Term
|
||||||
restParameter = makeRestParameter <$> symbol Grammar.RestParameter <*> children ((,) <$> term identifier <*> (term typeAnnotation' <|> emptyTerm))
|
restParameter = makeRestParameter <$> symbol Grammar.RestParameter <*> children ((,) <$> term identifier <*> (term typeAnnotation' <|> emptyTerm))
|
||||||
|
Loading…
Reference in New Issue
Block a user