diff options
author | Adam Joseph <adam@westernsemico.com> | 2022-10-30T20·42-0700 |
---|---|---|
committer | clbot <clbot@tvl.fyi> | 2022-10-31T12·36+0000 |
commit | 98a981a73718d4d1ed190796c862863514c1b102 (patch) | |
tree | d7e507e0dfc58c2aa751d153247404826d64e5f6 /tvix/eval/docs/builtins.md | |
parent | cc3060ed7cd181a1f44a498673ced8e39acba8ab (diff) |
docs(tvix/eval): builtins.md: note implementation status r/5225
We're getting close to the finish line, folks. I went through the list of builtins and there are only 33 that remain unimplemented. I've marked them, and indicated which are ready to be implemented vs which are waiting for other things. We can delete this column from the table once everything is implemented. Signed-off-by: Adam Joseph <adam@westernsemico.com> Change-Id: Idfaef93283536288b12e59aef5c3e1cd139bd133 Reviewed-on: https://cl.tvl.fyi/c/depot/+/7140 Tested-by: BuildkiteCI Reviewed-by: tazjin <tazjin@tvl.su>
Diffstat (limited to 'tvix/eval/docs/builtins.md')
-rw-r--r-- | tvix/eval/docs/builtins.md | 239 |
1 files changed, 123 insertions, 116 deletions
diff --git a/tvix/eval/docs/builtins.md b/tvix/eval/docs/builtins.md index cb0cc828d29a..89fe45318a95 100644 --- a/tvix/eval/docs/builtins.md +++ b/tvix/eval/docs/builtins.md @@ -10,122 +10,129 @@ without documenting their functionality. See also https://nixos.org/manual/nix/stable/expressions/builtins.html -| name | global | arity | pure | -|-------------------------------|--------|-------|-------| -| abort | true | 1 | | -| add | false | 2 | true | -| addErrorContext | false | ? | | -| all | false | 2 | true | -| any | false | 2 | true | -| appendContext | false | ? | | -| attrNames | false | 1 | true | -| attrValues | false | | true | -| baseNameOf | true | | | -| bitAnd | false | | | -| bitOr | false | | | -| bitXor | false | | | -| builtins | true | | | -| catAttrs | false | | | -| compareVersions | false | | | -| concatLists | false | | | -| concatMap | false | | | -| concatStringsSep | false | | | -| currentSystem | false | | | -| currentTime | false | | false | -| deepSeq | false | | | -| derivation | true | | | -| derivationStrict | true | | | -| dirOf | true | | | -| div | false | | | -| elem | false | | | -| elemAt | false | | | -| false | true | | | -| fetchGit | true | | | -| fetchMercurial | true | | | -| fetchTarball | true | | | -| fetchurl | false | | | -| filter | false | | | -| filterSource | false | | | -| findFile | false | | false | -| foldl' | false | | | -| fromJSON | false | | | -| fromTOML | true | | | -| functionArgs | false | | | -| genList | false | | | -| genericClosure | false | | | -| getAttr | false | | | -| getContext | false | | | -| getEnv | false | | false | -| hasAttr | false | | | -| hasContext | false | | | -| hashFile | false | | false | -| hashString | false | | | -| head | false | | | -| import | true | | | -| intersectAttrs | false | | | -| isAttrs | false | | | -| isBool | false | | | -| isFloat | false | | | -| isFunction | false | | | -| isInt | false | | | -| isList | false | | | -| isNull | true | | | -| isPath | false | | | -| isString | false | | | -| langVersion | false | | | -| length | false | | | -| lessThan | false | | | -| listToAttrs | false | | | -| map | true | | | -| mapAttrs | false | | | -| match | false | | | -| mul | false | | | -| nixPath | false | | | -| nixVersion | false | | | -| null | true | | | -| parseDrvName | false | | | -| partition | false | | | -| path | false | | sometimes | -| pathExists | false | | false | -| placeholder | true | | | -| readDir | false | | false | -| readFile | false | | false | -| removeAttrs | true | | | -| replaceStrings | false | | | -| scopedImport | true | | | -| seq | false | | | -| sort | false | | | -| split | false | | | -| splitVersion | false | | | -| storeDir | false | | | -| storePath | false | | | -| stringLength | false | | | -| sub | false | | | -| substring | false | | | -| tail | false | | | -| throw | true | | | -| toFile | false | | | -| toJSON | false | | | -| toPath | false | | | -| toString | true | | | -| toXML | false | | | -| trace | false | | | -| true | true | | | -| tryEval | false | | | -| typeOf | false | | | -| unsafeDiscardOutputDependency | false | | | -| unsafeDiscardStringContext | false | | | -| unsafeGetAttrPos | false | | | -| valueSize | false | | | +The `impl` column indicates implementation status in tvix: +- implemented: "" (empty cell) +- not yet implemented, but not blocked: `todo` +- not yet implemented, but blocked by other prerequisites: + - `store`: awaiting eval<->store api(s) + - `context`: awaiting support for string contexts + +| name | global | arity | pure | impl | +|-------------------------------|--------|-------|-------|---------| +| abort | true | 1 | | | +| add | false | 2 | true | | +| addErrorContext | false | ? | | context | +| all | false | 2 | true | | +| any | false | 2 | true | | +| appendContext | false | ? | | context | +| attrNames | false | 1 | true | | +| attrValues | false | | true | | +| baseNameOf | true | | | | +| bitAnd | false | | | | +| bitOr | false | | | | +| bitXor | false | | | | +| builtins | true | | | | +| catAttrs | false | | | | +| compareVersions | false | | | | +| concatLists | false | | | | +| concatMap | false | | | | +| concatStringsSep | false | | | | +| currentSystem | false | | | | +| currentTime | false | | false | | +| deepSeq | false | | | | +| derivation | true | | | store | +| derivationStrict | true | | | store | +| dirOf | true | | | | +| div | false | | | | +| elem | false | | | | +| elemAt | false | | | | +| false | true | | | | +| fetchGit | true | | | store | +| fetchMercurial | true | | | store | +| fetchTarball | true | | | store | +| fetchurl | false | | | store | +| filter | false | | | | +| filterSource | false | | | store | +| findFile | false | | false | todo | +| foldl' | false | | | | +| fromJSON | false | | | | +| fromTOML | true | | | | +| functionArgs | false | | | | +| genList | false | | | | +| genericClosure | false | | | todo | +| getAttr | false | | | | +| getContext | false | | | context | +| getEnv | false | | false | | +| hasAttr | false | | | | +| hasContext | false | | | context | +| hashFile | false | | false | todo | +| hashString | false | | | todo | +| head | false | | | | +| import | true | | | | +| intersectAttrs | false | | | | +| isAttrs | false | | | | +| isBool | false | | | | +| isFloat | false | | | | +| isFunction | false | | | | +| isInt | false | | | | +| isList | false | | | | +| isNull | true | | | | +| isPath | false | | | | +| isString | false | | | | +| langVersion | false | | | | +| length | false | | | | +| lessThan | false | | | | +| listToAttrs | false | | | | +| map | true | | | | +| mapAttrs | false | | | | +| match | false | | | | +| mul | false | | | | +| nixPath | false | | | todo | +| nixVersion | false | | | todo | +| null | true | | | | +| parseDrvName | false | | | | +| partition | false | | | | +| path | false | | sometimes | store | +| pathExists | false | | false | | +| placeholder | true | | | context | +| readDir | false | | false | | +| readFile | false | | false | | +| removeAttrs | true | | | | +| replaceStrings | false | | | | +| scopedImport | true | | | | +| seq | false | | | | +| sort | false | | | | +| split | false | | | todo | +| splitVersion | false | | | | +| storeDir | false | | | store | +| storePath | false | | | store | +| stringLength | false | | | | +| sub | false | | | | +| substring | false | | | | +| tail | false | | | | +| throw | true | | | | +| toFile | false | | | store | +| toJSON | false | | | todo | +| toPath | false | | | | +| toString | true | | | | +| toXML | false | | | todo | +| trace | false | | | | +| true | true | | | | +| tryEval | false | | | | +| typeOf | false | | | | +| unsafeDiscardOutputDependency | false | | | context | +| unsafeDiscardStringContext | false | | | context | +| unsafeGetAttrPos | false | | | todo | +| valueSize | false | | | todo | ## Added after C++ Nix 2.3 (without Flakes enabled) -| name | global | arity | pure | -|---------------|--------|-------|-------| -| break | false | 1 | | -| ceil | false | 1 | true | -| fetchTree | true | 1 | | -| floor | false | 1 | true | -| groupBy | false | 2 | true | -| traceVerbose | false | 2 | | -| zipAttrsWith | false | 2 | true | +| name | global | arity | pure | impl | +|---------------|--------|-------|-------|-------| +| break | false | 1 | | todo | +| ceil | false | 1 | true | | +| fetchTree | true | 1 | | todo | +| floor | false | 1 | true | | +| groupBy | false | 2 | true | | +| traceVerbose | false | 2 | | todo | +| zipAttrsWith | false | 2 | true | todo | |