generated,rust-analyzer: Handle objects with defined properties

They are implemented as submodules instead of an attrset of anything
This commit is contained in:
Quentin Boyer 2024-08-11 10:34:07 +02:00
parent f823d01002
commit ad704ddba7
3 changed files with 146 additions and 4 deletions

View file

@ -37,6 +37,16 @@ let
lib.types.int
else if kind == "object" then
lib.types.attrsOf lib.types.anything
else if kind == "submodule" then
lib.types.submodule {
options = lib.mapAttrs (
_: ty:
lib.mkOption {
type = mkRustAnalyzerType ty;
description = "";
}
) typeInfo.options;
}
else if kind == "string" then
lib.types.str
else if kind == "boolean" then