(str: string | null)
| 611 | } |
| 612 | |
| 613 | function getStringID(str: string | null): number { |
| 614 | if (str === null) { |
| 615 | return 0; |
| 616 | } |
| 617 | const existingID = pendingStringTable.get(str); |
| 618 | if (existingID !== undefined) { |
| 619 | return existingID; |
| 620 | } |
| 621 | const stringID = pendingStringTable.size + 1; |
| 622 | pendingStringTable.set(str, stringID); |
| 623 | // The string table total length needs to account |
| 624 | // both for the string length, and for the array item |
| 625 | // that contains the length itself. Hence + 1. |
| 626 | pendingStringTableLength += str.length + 1; |
| 627 | return stringID; |
| 628 | } |
| 629 | |
| 630 | let currentlyInspectedElementID: number | null = null; |
| 631 | let currentlyInspectedPaths: Object = {}; |
no test coverage detected