mirror of
https://github.com/nix-community/noogle.git
synced 2024-11-23 00:33:12 +03:00
improve functor tracking
This commit is contained in:
parent
50e35a47eb
commit
9283bc08e6
@ -1,10 +1,7 @@
|
||||
{
|
||||
# import (builtins.fetchTree {
|
||||
# repo = "nixpkgs";
|
||||
# ref = "migrate-doc-comments";
|
||||
# owner = "hsjobeki";
|
||||
# type = "github";
|
||||
# }) {},
|
||||
#
|
||||
# All these arguments can be overriden in production build
|
||||
#
|
||||
nixpkgs ? (builtins.fetchTree {
|
||||
repo = "nixpkgs";
|
||||
ref = "master";
|
||||
|
@ -4,6 +4,7 @@ let
|
||||
|
||||
dropBack = l: lib.reverseList (lib.drop 1 (lib.reverseList l));
|
||||
|
||||
unwrapFunctor = f: f.__functor f;
|
||||
/* *
|
||||
# Returns
|
||||
|
||||
@ -23,7 +24,10 @@ let
|
||||
let
|
||||
lambda =
|
||||
if lib.isFunction parent.${name} then
|
||||
builtins.lambdaMeta parent.${name}
|
||||
if parent.${name} ? __functor then
|
||||
builtins.lambdaMeta (unwrapFunctor parent.${name})
|
||||
else
|
||||
builtins.lambdaMeta parent.${name}
|
||||
else
|
||||
null;
|
||||
attr = { position = builtins.unsafeGetAttrPos name parent; };
|
||||
|
Loading…
Reference in New Issue
Block a user