From 0991bcdadcf6c9e07382ea619edc8af56cbc58e1 Mon Sep 17 00:00:00 2001 From: joshvera Date: Fri, 16 Feb 2018 16:32:32 -0500 Subject: [PATCH] Replace member expression with nested identifier --- src/Language/TypeScript/Assignment.hs | 6 +----- src/Language/TypeScript/Syntax.hs | 7 ------- 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/src/Language/TypeScript/Assignment.hs b/src/Language/TypeScript/Assignment.hs index eab7404cd..8ed6c81a9 100644 --- a/src/Language/TypeScript/Assignment.hs +++ b/src/Language/TypeScript/Assignment.hs @@ -144,7 +144,6 @@ type Syntax = '[ , TypeScript.Syntax.JsxClosingElement , TypeScript.Syntax.JsxExpression , TypeScript.Syntax.JsxAttribute - , TypeScript.Syntax.JsxMemberExpression , TypeScript.Syntax.JsxFragment , TypeScript.Syntax.JsxNamespaceName , TypeScript.Syntax.OptionalParameter @@ -376,14 +375,11 @@ jsxOpeningElement' :: Assignment jsxOpeningElement' = makeTerm <$> symbol Grammar.JsxOpeningElement <*> children (TypeScript.Syntax.JsxOpeningElement <$> term jsxElementName <*> manyTerm jsxAttribute') jsxElementName :: Assignment -jsxElementName = choice [ identifier, jsxMemberExpression, jsxNamespaceName ] +jsxElementName = choice [ identifier, nestedIdentifier, jsxNamespaceName ] jsxNamespaceName :: Assignment jsxNamespaceName = makeTerm <$> symbol Grammar.JsxNamespaceName <*> children (TypeScript.Syntax.JsxNamespaceName <$> identifier <*> identifier) -jsxMemberExpression :: Assignment -jsxMemberExpression = makeTerm <$> symbol Grammar.JsxMemberExpression <*> children (TypeScript.Syntax.JsxMemberExpression <$> manyTerm identifier) - jsxExpression' :: Assignment jsxExpression' = makeTerm <$> symbol Grammar.JsxExpression <*> children (TypeScript.Syntax.JsxExpression <$> term (expressions <|> spreadElement <|> emptyTerm)) diff --git a/src/Language/TypeScript/Syntax.hs b/src/Language/TypeScript/Syntax.hs index dc16a9fe3..347f2e597 100644 --- a/src/Language/TypeScript/Syntax.hs +++ b/src/Language/TypeScript/Syntax.hs @@ -507,10 +507,3 @@ data JsxNamespaceName a = JsxNamespaceName a a instance Eq1 JsxNamespaceName where liftEq = genericLiftEq instance Ord1 JsxNamespaceName where liftCompare = genericLiftCompare instance Show1 JsxNamespaceName where liftShowsPrec = genericLiftShowsPrec - -data JsxMemberExpression a = JsxMemberExpression [a] - deriving (Diffable, Eq, Foldable, Functor, GAlign, Generic1, Mergeable, Ord, Show, Traversable) - -instance Eq1 JsxMemberExpression where liftEq = genericLiftEq -instance Ord1 JsxMemberExpression where liftCompare = genericLiftCompare -instance Show1 JsxMemberExpression where liftShowsPrec = genericLiftShowsPrec