Source/Packages

Compiler.Parser

packages/compiler/src/Compiler/Parser.alpha

5,902 lines337 declarations199.2 KiBSHA-256 6d135c41813d

def · lines 4337–4355

decodeVariableHead

Full file
Recognize fixed arithmetic heads before speculative decoding of unrelated forms: a compact operand must never enter a universe/byte unary decoder.
4337def decodeVariableHead =
4338  (lambda unrestricted spelling : Bytes .
4339    (lambda unrestricted functionTerm : (family Term) .
4340      (lambda unrestricted argumentTerm : (family Term) .
4341        (lambda unrestricted remaining : (family TermList) .
4342          (eliminate
4343            NaturalOperationLookup
4344            (lambda unrestricted result : (family NaturalOperationLookup) .
4345              (family TermDecodeResult))
4346            (Compiler.NaturalOperation/lookupNaturalOperation spelling)
4347            (branch
4348              NaturalOperationFound
4349              operation
4350              .
4351              (decodeArithmeticArguments operation argumentTerm remaining))
4352            (branch
4353              NaturalOperationMissing
4354              .
4355              (decodeNonArithmeticVariableHead spelling functionTerm argumentTerm remaining)))))))

The compiler supplied declaration spans and resolved links from this source snapshot. This page does not assert that this file belongs to a checked closure.