nixd
|
Classes | |
struct | DynamicNameException |
The attrpath has a dynamic name, thus it cannot be trivially transformed to "static" selector. More... | |
struct | IdiomException |
struct | IdiomSelectorException |
Exceptions scoped in nixd::mkIdiomSelector. More... | |
struct | NoLocationForBuiltinVariable |
struct | NoSuchVarException |
No such variable. More... | |
struct | NotAnIdiomException |
The pattern of this variable cannot be recognized by known idioms. More... | |
struct | NotVariableSelect |
struct | UndefinedVarException |
struct | VLAException |
Functions | |
Selector | mkVarSelector (const nixf::ExprVar &Var, const nixf::VariableLookupAnalysis &VLA, const nixf::ParentMapAnalysis &PM) |
Construct a nixd::Selector from Var . | |
Selector | mkSelector (const nixf::AttrPath &AP, Selector BaseSelector) |
Construct a nixd::Selector from AP . | |
Selector | mkSelector (const nixf::ExprSelect &Select, Selector BaseSelector) |
Construct a nixd::Selector from Select . | |
Selector | mkSelector (const nixf::ExprSelect &Select, const nixf::VariableLookupAnalysis &VLA, const nixf::ParentMapAnalysis &PM) |
Construct a nixd::Selector from Select . | |
Variables | |
constexpr std::string_view | Pkgs = "pkgs" |
Hardcoded name for "pkgs.xxx", or "with pkgs;". | |
constexpr std::string_view | Lib = "lib" |
Hardcoded name for nixpkgs "lib". | |
nixd::Selector nixd::idioms::mkSelector | ( | const nixf::AttrPath & | AP, |
Selector | BaseSelector ) |
Construct a nixd::Selector from AP
.
Definition at line 249 of file AST.cpp.
References nixf::AttrPath::names().
Referenced by mkSelector(), and mkSelector().
nixd::Selector nixd::idioms::mkSelector | ( | const nixf::ExprSelect & | Select, |
const nixf::VariableLookupAnalysis & | VLA, | ||
const nixf::ParentMapAnalysis & | PM ) |
Construct a nixd::Selector from Select
.
Definition at line 260 of file AST.cpp.
References nixf::ExprSelect::expr(), nixf::Node::kind(), mkSelector(), and mkVarSelector().
nixd::Selector nixd::idioms::mkSelector | ( | const nixf::ExprSelect & | Select, |
nixd::Selector | BaseSelector ) |
Construct a nixd::Selector from Select
.
Definition at line 189 of file AST.cpp.
References mkSelector(), and nixf::ExprSelect::path().
nixd::Selector nixd::idioms::mkVarSelector | ( | const nixf::ExprVar & | Var, |
const nixf::VariableLookupAnalysis & | VLA, | ||
const nixf::ParentMapAnalysis & | PM ) |
Construct a nixd::Selector from Var
.
Try to heuristically find a selector of a variable, based on some known idioms.
Definition at line 199 of file AST.cpp.
References nixf::ExprVar::id(), nixf::Node::kind(), nixf::Identifier::name(), nixf::ParentMapAnalysis::query(), nixf::VariableLookupAnalysis::query(), and nixf::Definition::syntax().
Referenced by mkSelector().
|
inlineconstexpr |