* Returns the node more strictly typed iff it is of the given type. Otherwise, * returns null.
(node)
| 6027 | */ |
| 6028 | |
| 6029 | function assertSymbolNodeType(node) { |
| 6030 | const typedNode = checkSymbolNodeType(node); |
| 6031 | |
| 6032 | if (!typedNode) { |
| 6033 | throw new Error(`Expected node of symbol group type, but got ` + (node ? `node of type ${node.type}` : String(node))); |
| 6034 | } |
| 6035 | |
| 6036 | return typedNode; |
| 6037 | } |
| 6038 | /** |
| 6039 | * Returns the node more strictly typed iff it is of the given type. Otherwise, |
| 6040 | * returns null. |
no test coverage detected