(a, b)
| 104 | } |
| 105 | |
| 106 | function firstDiffIndex(a, b) { |
| 107 | const n = Math.min(a.length, b.length); |
| 108 | for (let i = 0; i < n; i++) if (a[i] !== b[i]) return i; |
| 109 | return n; // sequences agree up to the shorter one's length |
| 110 | } |
| 111 | |
| 112 | function describeHeading(h) { |
| 113 | if (!h) return "no heading (document ends)"; |
no outgoing calls
no test coverage detected