x-lang

prim-reg!

File an x-lang value into the catalog under ns/method.

The producer half of the registry protocol: library implementations register

under the same stable identities as C prims. Registration prepends, so a

re-registration shadows the older entry on lookup. Returns nil.

Parameters:

Examples:

(do (prim-reg! 'demo 'twice (fn (_ n) (* n 2))) ((prim-ref 'demo 'twice) 21)) => 42

See also: prim-ref