lib/modules: Add moduleType parameter#147000
Conversation
9bb0030 to
b3178d5
Compare
infinisil
left a comment
There was a problem hiding this comment.
Oh my, this is really neat! Other than the small nit I think this looks good.
b3178d5 to
d464ccf
Compare
|
I guess the only thing I have a slight worry about is name clashes in the module argument namespace. I don't think it's a big problem though |
I've thought about that too. |
|
Whoa this is a highly specific use case, and strangely expressive. Do you have examples where this might be used? |
💯 It is similar to
It is productive recursion though. This is fine as long as you're not trying to compute something over all the data, which is generally not something you do in modules anyway, except in some "data" submodules (which I dislike) and in RFC42 style settings with a freeformType (which are ok).
You'd have to condition the
Besides the NixOS use cases, which use the same functionality via |
Motivation for this change
Follow-up to #143207. Allows the current configuration to be replicated and modified. Summarizing the test:
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)nixos/doc/manual/md-to-db.shto update generated release notes