Builtin Helpers
Several new builtin functions are proposed to address issues and inconsistencies.
Replacing _|_ (bottom):
errorto enable user defined messagesisconcreteandexistsfor testing or comparisons
Validators:
must(expr)passes ifexprevaluates totrueand fails otherwisenot(expr)passes if unified with a valuexfor whichexpr&xfails andfalseotherwise.numexist(count, ...expr)passes if the number of expressions for whichexists(x)evaluates totrueunifies withcount.numconcrete(count, ...expr)passes if the number of expressions for whichisconcrete(x)evaluates totrueunifies withcount.numvalid(count, ...expr)passes if the number of expressions for whichisvalid(x)evaluates totrueunifies withcount.
Others:
manifest(x)evaluatesxstripping it of any optional fields and definitions and disambiguating disjunctions after their removal.range(from, to, by)creates a stream of values like found in other languageshead([...])returns the first element of a list- Package
stdwould namespace all core builtins under thestdpackage name.
You can find more details on GitHub issue: core builtin extensions