Dispatch SBox accessor method-forms (PropertyCall 99:2..6)#905
Open
mwaddip wants to merge 1 commit into
Open
Conversation
The JVM catalogues the SBox accessors as PropertyCall methods in commonBoxMethods (present from v5Methods, no version gate) and MethodCall.eval evaluates any catalogued FixedCost method via invokeFixed reflection, so a hand-crafted PropertyCall(99,N) tree evaluates JVM-side with no bespoke eval-fn. sigma-rust registered only value (99:1), getReg (7) and tokens (8), so the propositionBytes/bytes/ bytesWithoutRef/id/creationInfo method-forms (99:2..6) failed to resolve at parse (UnknownMethodId) and surfaced as errored — an us-vs-JVM fork on method-form trees (compilers emit the op-forms, which already work). Register the five descriptors (methods.scala SBoxMethods: SFunc(SBox, Coll[Byte]) for 2..5, (Int, Coll[Byte]) for creationInfo) and dispatch each through the existing op-form value helper (ExtractScriptBytes / ExtractBytes / ExtractBytesWithNoRef / ExtractId / ExtractCreationInfo), exactly as value (99:1) already does, so each method-form returns the same value as its op-form twin. 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 catalogues the SBox accessors as PropertyCall methods in
commonBoxMethods(from v5Methods, no gate), andMethodCall.evalevaluates any cataloguedFixedCostmethod viainvokeFixedreflection — so a hand-craftedPropertyCall(99,N)evaluates JVM-side. sigma-rust registered onlyvalue(1),getReg(7),tokens(8), sopropositionBytes/bytes/bytesWithoutRef/id/creationInfo(ids 2..6) failed to resolve at parse (UnknownMethodId) — an us-vs-JVM divergence on method-form trees.Registers the five
commonBoxMethodsdescriptors (methods.scalaSBoxMethods) and dispatches each through its op-form helper (ExtractScriptBytes/ExtractBytes/ExtractBytesWithNoRef/ExtractId/ExtractCreationInfo), asvaluealready does, so each returns its op-form twin value.