← All docs
ltrim() — internals
Compiler internals for ltrim(): lowering path, type checks, and runtime helpers.
ltrim() — internals
Where it lives
- Signature:
src/builtins/string/ltrim.rs - Lowering:
src/codegen/lower_inst/builtins/strings.rs:129 (lower_trim_like) - Function symbol:
lower_trim_like()
Lowering notes
- Lowers
trim()/ltrim()/rtrim()/chop()for default and explicit masks.
Runtime helpers
No direct __rt_* helpers captured — the lowering is inlined or routes through another builtin.
Signature summary
function ltrim(string $string, string $characters = ' \n\r\t\x0b\x0c\x00'): string
What the type checker enforces
- Arity: takes 1–2 arguments (1 optional).
Eval interpreter (magician)
- Declaration:
crates/elephc-magician/src/interpreter/builtins/string/ltrim.rs(eval_builtin!) - Dispatch hooks:
direct,values