tvl-depot/third_party
sterni 8709153973 fix(tvix/libexpr): backport fix for functionArgs failing on primops
Nix internally differentiates between lambdas and primops, but their
type in the nix expression language is the same (lambda). The
implementation of builtins.functionArgs only checks if the given
expression is of type tLambda and fails if the type is tPrimop or
tPrimopApp which are also functions. This most notably breaks
lib.generators.toPretty when called on a builtin making for example
yants fail if a primop is typechecked and an error message is
generated.

This fix generates an empty set for primops like for plain lambdas
and is based upstream commit b2748c6e99239ff6803ba0da76c362790c8be192.

Additionally we add to two tests:

* eval-okay-functionargs now includes a few test cases checking that
  builtins.functionArgs always returns an empty set for builtins and
  also works as expected for normal functions.
* eval-okay-types now also checks if builtins are functions.

Future work would be to make builtins.functionArgs work as users would
expect for builtins like builtins.fetchurl, builtins.fetchGit etc. which
take a set as an argument. These currently don't register as formal
arguments, but it would be an usability improvement at least if they
did.

See also https://github.com/NixOS/nix/pull/3626#issuecomment-698546704

Change-Id: I2bf4cb80d44a4b72ade13d3e0dbd7dfb1d049f32
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2477
Tested-by: BuildkiteCI
Reviewed-by: Profpatsch <mail@profpatsch.de>
Reviewed-by: glittershark <grfn@gws.fyi>
2021-02-02 10:52:33 +00:00
..
abseil_cpp merge(3p/absl): subtree merge of Abseil up to e19260f 2020-11-21 15:48:57 +01:00
alsi revert(glittershark): "Temporarily skip grfn's subtree" 2020-08-28 21:24:36 +00:00
apereo-cas chore(apereo-cas): fix up configuration 2020-07-08 17:49:25 +00:00
bat_syntaxes feat(3p/bat_syntaxes): Add a derivation to extend bat syntaxes 2020-06-15 16:52:23 +00:00
bufbuild chore(3p): Bump nixos-unstable channel 2020-08-17 09:54:18 +00:00
cgit fix(3p/cgit): Rename remaining 'sha1' references to 'oid' 2020-11-21 20:09:42 +01:00
cpp/googleapis chore(3p): upgrade llvm to version 11 2020-11-29 03:02:14 +00:00
emacs refactor(3p/exwm): Inline build instructions instead of overriding 2021-01-10 13:32:47 +00:00
farmhash feat(third_party): Add Google's farmhash library 2020-05-08 18:39:43 +01:00
ffmpeg feat(third_party/ffmpeg): Add "libnpp" support to ffmpeg 2020-04-04 02:36:20 +01:00
gerrit fix(3p/gerrit): fix left padding on account chip 2020-12-20 16:10:40 +00:00
gerrit_plugins chore(3p/gerrit_plugins): fix fixed-output sha256 of check 2021-02-01 23:14:49 +00:00
git merge(3p/git): Merge git subtree at v2.29.2 2020-11-21 19:45:56 +01:00
git-bug chore: Add meta.ci=false to various broken projects 2020-08-26 23:49:32 +00:00
gitignoreSource feat(3p): Add gitignoreSource 2020-06-29 17:23:52 +00:00
glog fix(3p/nix): Link to glog built by Nix 2020-07-05 16:54:12 +00:00
gopkgs chore: simplify buildGo expressions 2020-08-04 07:43:25 +00:00
grpc fix(3p/grpc): Bump to 1.30.0 and build with precompiled Abseil 2020-07-05 17:51:31 +00:00
gtest chore(3p): Bump nixpkgs to nixos-unstable from 2020-11-21 2020-11-21 23:18:27 +00:00
haskell-language-server chore(3p): Bump nixpkgs channels 2020-08-06 00:15:33 +00:00
irccat feat(3p/irccat): init at '06a985y4' 2020-11-08 18:38:08 +00:00
kernelPatches/trx40_usb_audio feat(3p/kernelPatches): Add kernel audio patch for ASUS TRX40 Pro 2020-06-20 22:27:03 +00:00
lieer chore(3p/lieer): Upgrade to lieer 1.3 2020-12-14 19:41:30 +00:00
lisp chore(3p): Bump nixpkgs to nixos-unstable from 2020-11-21 2020-11-21 23:18:27 +00:00
naersk chore(3p/naersk): Update to latest 'master' 2020-05-25 23:36:20 +01:00
nix fix(tvix/libexpr): backport fix for functionArgs failing on primops 2021-02-02 10:52:33 +00:00
nixery chore: Rename pkgs->depot in all Nix file headers 2020-02-21 13:54:53 +00:00
nixpkgs-exposed chore(3p|nix): Remove typed Go 2021-01-30 08:20:45 +00:00
notmuch fix(3p/notmuch): Rebase dottime patch on notmuch 0.31 2020-12-14 19:41:30 +00:00
nsfv feat(3p/nsfv): Add derivation for NSFV 2020-06-25 02:27:38 +00:00
openldap feat(3p/openldap): Enable slapd-passwd-argon2 module 2020-07-01 19:10:13 +00:00
protobuf feat(3p/protobuf): Check in derivation for proto 3.12 with libcxx 2020-06-07 14:56:56 +01:00
python/broadlink feat(3p/python/broadlink): Add max_devices discovery parameter 2020-04-26 14:50:04 +01:00
rapidcheck feat(3p): Add rapidcheck 2020-07-19 16:26:52 +00:00
rr chore(3p/rr): Upgrade to latest master with Zen workarounds 2020-09-23 15:23:25 +00:00
smtprelay feat(nixos/smtprelay): Add derivation & module for SMTP relay 2020-06-13 01:23:01 +00:00
telega feat(3p/telega): Pin tdlib version used for telega 2021-01-26 13:25:43 +00:00
terraform-gcp chore: Rename pkgs->depot in all Nix file headers 2020-02-21 13:54:53 +00:00
default.nix chore(3p|nix): Remove typed Go 2021-01-30 08:20:45 +00:00
README.md docs(third_party): Add README 2019-06-29 14:12:38 +01:00

Third-Party Code

Code under this folder is one of the following:

  1. Externally developed dependencies which have been imported ("vendored") into this repository. These dependencies come with their own licenses and whatever else.

  2. Code that is developed inside of this repository, but released to an external repository via Copybara.