(node)
| 78360 | return true; |
| 78361 | } |
| 78362 | function checkDeleteExpression(node) { |
| 78363 | checkExpression(node.expression); |
| 78364 | var expr = ts.skipParentheses(node.expression); |
| 78365 | if (!ts.isAccessExpression(expr)) { |
| 78366 | error(expr, ts.Diagnostics.The_operand_of_a_delete_operator_must_be_a_property_reference); |
| 78367 | return booleanType; |
| 78368 | } |
| 78369 | if (ts.isPropertyAccessExpression(expr) && ts.isPrivateIdentifier(expr.name)) { |
| 78370 | error(expr, ts.Diagnostics.The_operand_of_a_delete_operator_cannot_be_a_private_identifier); |
| 78371 | } |
| 78372 | var links = getNodeLinks(expr); |
| 78373 | var symbol = getExportSymbolOfValueSymbolIfExported(links.resolvedSymbol); |
| 78374 | if (symbol) { |
| 78375 | if (isReadonlySymbol(symbol)) { |
| 78376 | error(expr, ts.Diagnostics.The_operand_of_a_delete_operator_cannot_be_a_read_only_property); |
| 78377 | } |
| 78378 | checkDeleteExpressionMustBeOptional(expr, symbol); |
| 78379 | } |
| 78380 | return booleanType; |
| 78381 | } |
| 78382 | function checkDeleteExpressionMustBeOptional(expr, symbol) { |
| 78383 | var type = getTypeOfSymbol(symbol); |
| 78384 | if (strictNullChecks && |
no test coverage detected