(node, sortedFileDiagnostics)
| 129350 | } |
| 129351 | ts.isDiagnosticWithLocation = isDiagnosticWithLocation; |
| 129352 | function findDiagnosticForNode(node, sortedFileDiagnostics) { |
| 129353 | var span = createTextSpanFromNode(node); |
| 129354 | var index = ts.binarySearchKey(sortedFileDiagnostics, span, ts.identity, ts.compareTextSpans); |
| 129355 | if (index >= 0) { |
| 129356 | var diagnostic = sortedFileDiagnostics[index]; |
| 129357 | ts.Debug.assertEqual(diagnostic.file, node.getSourceFile(), "Diagnostics proided to 'findDiagnosticForNode' must be from a single SourceFile"); |
| 129358 | return ts.cast(diagnostic, isDiagnosticWithLocation); |
| 129359 | } |
| 129360 | } |
| 129361 | ts.findDiagnosticForNode = findDiagnosticForNode; |
| 129362 | function getDiagnosticsWithinSpan(span, sortedFileDiagnostics) { |
| 129363 | var _a; |
nothing calls this directly
no test coverage detected