--- id: LANG-27 family: GR-LANG level: core profiles: [runtime] posture: normative-target added: "1.0" changed: "1.0" source: https://flowdrop.io/spec/rules/gr-lang/lang-27 specification: FlowDrop Workflow Specification 1.0-draft licence: CC BY 4.0 --- # LANG-27 — A switch compares its value; it does not evaluate it *GR-LANG (Part I) · level: core · profiles: runtime · added in 1.0* Despite the parameter's name, a switch gateway runs no expression engine. The value is matched against each branch as it stands. ## The rule > **Normative.** This is the rule. > > 1. A switch gateway does not evaluate its `expression`. > > 2. The value is compared unchanged against each branch's `value` in declaration order, with no coercion: a branch matches only where the two are of the same type as well as equal. > > 3. The first matching branch is the sole active branch, and its name is what the gateway reports as active. > > 4. Where no branch matches, the branch named by `default_branch` is active; where no branch matches and no usable default is named, the node fails. --- Rule identifiers are permanent and are never renumbered. This specification carries no implementation status: each implementation publishes its own standing against these rules. Licensed CC BY 4.0.