fix: deserialize LastBlockUtxoRootHash (0xa6) — the bare context-root op form#901
Open
mwaddip wants to merge 1 commit into
Open
fix: deserialize LastBlockUtxoRootHash (0xa6) — the bare context-root op form#901mwaddip wants to merge 1 commit into
mwaddip wants to merge 1 commit into
Conversation
… op form The JVM serializes `LastBlockUtxoRootHash` as a dedicated case-object op code (`OpCodes.LastBlockUtxoRootHashCode` = 54, registered in `ValueSerializer.scala`); the Expr deserializer had no arm for it, so a consensus-legal tree carrying the op form failed to parse where the JVM evaluates (the sibling context globals — e.g. MinerPubkey, 0xac — already dispatch). The new `GlobalVars::LastBlockUtxoRootHash` mirrors the wiring of the other context globals; its eval matches the existing `CONTEXT.LastBlockUtxoRootHash` PropertyCall eval (`values.scala:1490`, `E.context.LastBlockUtxoRootHash`) so the two wire forms of the property agree. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The JVM serializes
LastBlockUtxoRootHashas a dedicated case-object op code (OpCodes.LastBlockUtxoRootHashCode= 54 = 0xa6, registered inValueSerializer.scala), but the Expr deserializer had no arm for it — a consensus-legal tree carrying the bare op form (1000a6) failed to parse where the JVM evaluates. The sibling context globals (e.g. MinerPubkey, 0xac) already dispatch.New
GlobalVars::LastBlockUtxoRootHashmirrors that wiring (op code, parse arm,SAvlTree); the serialize side was already generic overop_code(). Eval matches the existingCONTEXT.LastBlockUtxoRootHashPropertyCall eval (values.scala:1490) so the two wire forms agree.Tests: bare-
0xa6round-trip byte pin + e2e parsing the blessed1000a6tree, asserting op form ≡ PropertyCall form.