Icr
Constants
Class methods
irb-style braille banner: the art is tinted blue, the text stays in the terminal's default color (no escapes at all when not a TTY)
Where the live backend's compiler comes from, in order:
- ICR_CRYSTAL env var (explicit override)
- CRYSTAL_INTERPRETER_PATH env var (checked from Crystal code at startup via ENV — no Rakefile needed)
- ~/.local/share/icr/crystal/bin/crystal (scripts/build-interpreter.sh)
crystalfrom PATH (usually lacks interpreter support; the CLI then falls back to replay mode)
Library-friendly entry point: open the best available session — a LiveSession when interpreter_bin resolved to an interpreter- capable crystal (env vars → ~/.local/share/icr → PATH), a ReplaySession otherwise. This is the same logic the CLI uses, so shard consumers always get the live interpreter by default when one is present. Env vars are read at call time: host apps can set ENV["CRYSTAL_INTERPRETER_PATH"] (or ICR_CRYSTAL) in their own code before calling this.
Macros
Opt into the baked completion table without requiring anything.
Expands to a marker def carrying the annotation; macro finished
below looks for those markers. (Duplicate defs are legal in Crystal;
repeated calls simply re-mark, and the harvest dedupes.)