← All docs
arsort() — internals
Compiler internals for arsort(): lowering path, type checks, and runtime helpers.
arsort() — internals
Where it lives
- Signature:
src/builtins/array/arsort.rs - Lowering:
src/codegen/lower_inst/builtins/arrays.rs:1094 (lower_arsort) - Function symbol:
lower_arsort()
Lowering notes
- Lowers
arsort()for indexed integer arrays through the descending value-sort wrapper.
Runtime helpers
The following runtime helpers are referenced:
__rt_arsort__rt_krsort__rt_ksort__rt_natcasesort__rt_natsort
Signature summary
function arsort(array $array): bool
What the type checker enforces
- Arity: takes exactly 1 argument.
- By-reference parameters:
$array.
Eval interpreter (magician)
- Declaration:
crates/elephc-magician/src/interpreter/builtins/array/arsort.rs(eval_builtin!) - Dispatch hooks:
values - By-reference parameters:
$array.