← garnet-lang.org  ·  Getting Started  ·  Mini-Spec  ·  Source ↗

Stdlib Primitive Registry

The current registry exposes 84 primitive entries. Pure helpers need no capability; time, filesystem, network, environment, process and memory-tier primitives declare one. On main, the 24 entry-gated rows are refused at run time when the program entry does not declare their capability (the v0.8.2 release gates 15 and has no mem capability gate); unbridged rows have no interpreter binding.

This is a registry reference, not a promise of a mature standard library. Higher-level HTTP, package, async, and data APIs remain future library work.

84registry entries
58entries with no capability
24entry-gated entries
2unbridged entries

Primitive Table

NameCapabilityGuard classStability
time::now_mstimeentry-gatedstable
time::wall_clock_mstimeentry-gatedstable
time::sleeptimeentry-gatedstable
str::splitnonenonestable
str::replacenonenonestable
str::to_lowernonenonestable
str::to_uppernonenonestable
str::trimnonenonestable
str::starts_withnonenonestable
str::containsnonenonestable
array::insertnonenonestable
array::removenonenonestable
array::sortnonenonestable
crypto::blake3nonenonestable
crypto::sha256nonenonestable
crypto::hmac_sha256nonenonestable
fs::read_filefsentry-gatedstable
fs::write_filefsentry-gatedstable
fs::read_bytesfsentry-gatedstable
fs::write_bytesfsentry-gatedstable
fs::list_dirfsentry-gatedstable
net::tcp_connectnetentry-gatedstable
net::tcp_listennetunbridgedstable
net::udp_bindnetunbridgedstable
core::iter::mapnonenonestable
core::iter::filternonenonestable
core::iter::foldnonenonestable
core::iter::zipnonenonestable
core::iter::takenonenonestable
core::iter::dropnonenonestable
core::iter::collectnonenonestable
core::iter::chainnonenonestable
core::iter::enumeratenonenonestable
core::result::oknonenonestable
core::result::errnonenonestable
core::result::mapnonenonestable
core::result::and_thennonenonestable
core::result::or_elsenonenonestable
core::result::unwrap_ornonenonestable
core::option::somenonenonestable
core::option::nonenonenonestable
core::option::mapnonenonestable
core::option::and_thennonenonestable
core::option::unwrap_ornonenonestable
core::cmp::minnonenonestable
core::cmp::maxnonenonestable
core::cmp::orderingnonenonestable
core::cmp::clampnonenonestable
core::math::absnonenonestable
core::math::sqrtnonenonestable
core::math::pownonenonestable
core::math::floornonenonestable
core::math::ceilnonenonestable
core::math::roundnonenonestable
std::env::getenventry-gatedexperimental
std::env::setenventry-gatedexperimental
std::env::varsenventry-gatedexperimental
std::process::spawnprocentry-gatedexperimental
std::process::waitprocentry-gatedexperimental
std::process::exit_codeprocentry-gatedexperimental
std::process::spawn_argsprocentry-gatedexperimental
std::process::outputprocentry-gatedexperimental
std::json::parsenonenoneexperimental
std::json::stringifynonenoneexperimental
std::json::getnonenoneexperimental
std::json::setnonenoneexperimental
std::regex::compilenonenoneexperimental
std::regex::matchnonenoneexperimental
std::regex::find_allnonenoneexperimental
std::regex::replacenonenoneexperimental
std::uuid::new_v4timeentry-gatedexperimental
std::uuid::new_v5nonenoneexperimental
std::uuid::new_v7timeentry-gatedexperimental
std::base64::encodenonenoneexperimental
std::base64::decodenonenoneexperimental
std::log::infononenoneexperimental
std::log::warnnonenoneexperimental
std::log::errornonenoneexperimental
std::log::debugnonenoneexperimental
std::log::to_filefsentry-gatedexperimental
memory::workingmementry-gatedexperimental
memory::episodicmementry-gatedexperimental
memory::semanticmementry-gatedexperimental
memory::proceduralmementry-gatedexperimental

What Is Still Missing

A production-feeling language needs more than this registry. The next useful layers are HTTP client/server helpers, datetime, configuration, package manifests, and richer test helpers; JSON, regex, UUID, base64 and logging already have registry rows above. Those should land behind the same capability discipline, with examples and dogfood evidence beside the implementation.