(node *Node, excludeCompoundAssignment bool)
| 114 | } |
| 115 | |
| 116 | func IsAssignmentExpression(node *Node, excludeCompoundAssignment bool) bool { |
| 117 | if node.Kind == KindBinaryExpression { |
| 118 | expr := node.AsBinaryExpression() |
| 119 | return (expr.OperatorToken.Kind == KindEqualsToken || !excludeCompoundAssignment && IsAssignmentOperator(expr.OperatorToken.Kind)) && |
| 120 | IsLeftHandSideExpression(expr.Left) |
| 121 | } |
| 122 | return false |
| 123 | } |
| 124 | |
| 125 | func GetRightMostAssignedExpression(node *Node) *Node { |
| 126 | for IsAssignmentExpression(node, false /*excludeCompoundAssignment*/) { |
no test coverage detected