maybeValidateInternal in src/transpilation/WFFunction.js carries three T413840-tagged design questions (lines 28, 39, 44) about argument validation correctness:
- The function only runs validation when the argument is a WFObject; other WFBase subclasses are silently skipped. Unclear whether WFList, WFFunctionCall, etc. should also flow through.
- When the validation function on a type is not a Z9/reference, the function returns silently. Unclear whether this should be an error (definitely user-defined, but not in a form we can run) or whether silent skip is correct.
- The "is this a built-in validator we can skip" check is a heuristic on numeric ZID ranges (< 400, or 500 <= ZID < 10000). Brittle; should consult the actual built-in registry.
This is correctness/design work, not performance.
Desired behavior/Acceptance criteria
- Decide and document which WFBase subclasses need validation; widen the gate or document the omission.
- Decide and document non-Z9 validation function behaviour; convert silent skip to a proper Z5 if appropriate.
- Replace the numeric-ZID heuristic with a lookup against the actual builtin/validator registry.
- All existing tests pass; new tests for any behavioural changes.