Skip to content

Show the snapshot an F# entry is anchored on - #827

Merged
SimonCropp merged 1 commit into
mainfrom
fix-fsharp-expected-pane
Aug 22, 2026
Merged

Show the snapshot an F# entry is anchored on#827
SimonCropp merged 1 commit into
mainfrom
fix-fsharp-expected-pane

Conversation

@SimonCropp

Copy link
Copy Markdown
Member

QueueEntry.Expected decided "new snapshot" from OriginalExpression being null and
never looked at OriginalValue, which is the anchor a producer sends when its
language does not implement CallerArgumentExpression. F# does not, so every F#
entry opened with an empty expected pane and every received line marked as added -
while the applier was anchoring on that same value and the staged expected.txt was
written from it.

It is the snapshot the expression would have parsed to, not source text: the
patcher compares it against what a literal parses to, and against NewContent for an
already-applied patch. So it goes in the pane as it is, under the plain "expected"
header, and only a patch with neither anchor still reads as a new snapshot.

QueueEntry.Expected decided "new snapshot" from OriginalExpression being null and
never looked at OriginalValue, which is the anchor a producer sends when its
language does not implement CallerArgumentExpression. F# does not, so every F#
entry opened with an empty expected pane and every received line marked as added -
while the applier was anchoring on that same value and the staged expected.txt was
written from it.

It is the snapshot the expression would have parsed to, not source text: the
patcher compares it against what a literal parses to, and against NewContent for an
already-applied patch. So it goes in the pane as it is, under the plain "expected"
header, and only a patch with neither anchor still reads as a new snapshot.
@SimonCropp SimonCropp added this to the 20.0.0 milestone Aug 22, 2026
@SimonCropp
SimonCropp merged commit f01c11b into main Aug 22, 2026
10 checks passed
@SimonCropp
SimonCropp deleted the fix-fsharp-expected-pane branch August 22, 2026 13:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant