MCPcopy Create free account
hub / github.com/alibaba/open-code-review / firstDiffIndex

Function firstDiffIndex

scripts/github-actions/check-translation-sync.js:106–110  ·  view source on GitHub ↗
(a, b)

Source from the content-addressed store, hash-verified

104}
105
106function 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
112function describeHeading(h) {
113 if (!h) return "no heading (document ends)";

Callers 1

compareReadmeStructuresFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected