3
0
mirror of https://github.com/larvit/adf-codec.git synced 2026-11-16 05:20:25 +01:00

Answer prose round 2: 0 🔴, 2 🟡 (0 misread); the memo comments say what they hold, the PR body names destinationEnds

This commit is contained in:
2026-10-28 12:48:28 +01:00
committed by Lillem4n
parent 935012d475
commit 744476658c
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -433,7 +433,7 @@ function resolveTarget(scan: Scan, start: number, index: number): InlineTarget |
const after = index + 1
if (scan.source.charAt(after) === '(') {
const inline = readInlineTarget(scan.targets, scan.offset + after)
// A target read in the outermost content holds in a directive's content exactly when it ends inside it.
// The memo reads the outermost content; a target it reads holds here exactly when the target ends inside `source`.
if (inline !== undefined && after + inline.length <= scan.source.length) return inline
}
const label = scan.source.charAt(after) === '[' ? readLabel(scan.source, after) : undefined