(textValue: string | number)
| 115 | } |
| 116 | |
| 117 | function parseStringToNum(textValue: string | number): number { |
| 118 | if (typeof textValue === 'string') { |
| 119 | let val = parseInt(textValue) |
| 120 | if (textValue.includes('.')) { |
| 121 | val = parseFloat(textValue) |
| 122 | } |
| 123 | return val |
| 124 | } |
| 125 | return textValue |
| 126 | } |
| 127 | |
| 128 | export class NumericLiteral extends JavaScriptSplootNode { |
| 129 | constructor(parentReference: ParentReference, value: number) { |
no outgoing calls
no test coverage detected