APL subset interpreter with Unicode glyphs, ASCII aliases, and SIMD-friendly array storage.
- All numeric values are
f64; arrays stored as contiguousVec<f64>for autovectorization - Right-to-left evaluation with strand notation (adjacent values form vectors)
- 17 scalar functions (element-wise with scalar extension), 7 structural functions, 4 operators
- Operators: reduce (
/), scan (\), each (¨), outer product (∘.f) - Unicode APL glyphs and ASCII aliases:
iotafor⍳,rhofor⍴,revfor⌽,mulfor×,divfor÷, etc. - Default instruction limit: 10,000,000 (configurable via
with_instruction_limit())
cargo install --path .
# Inline code
apl "2+3"
apl "+/⍳100"
apl "∘.×⍳5"
# ASCII aliases
apl "+/iota 100"
# From file
apl -f program.apluse otherfunc_apl::AplInterpreter;
use otherfunc_core::Interpreter;
let mut apl = AplInterpreter::new();
let output = apl.execute("+/⍳100", "").unwrap();
assert_eq!(output, "5050");cargo test -p otherfunc-apl # 33 tests