← All docs

ord() — internals

Compiler internals for ord(): lowering path, type checks, and runtime helpers.

ord() — internals

Where it lives

Lowering notes

  • Lowers ord() by returning the first byte of a string or zero for empty input.

Runtime helpers

No direct __rt_* helpers captured — the lowering is inlined or routes through another builtin.

Signature summary

function ord(string $character): int

What the type checker enforces

  • Arity: takes exactly 1 argument.

Eval interpreter (magician)

Cross-references