nixd
Loading...
Searching...
No Matches
NixTU.cpp
Go to the documentation of this file.
2
3using namespace nixd;
4
5NixTU::NixTU(std::vector<nixf::Diagnostic> Diagnostics,
6 std::shared_ptr<nixf::Node> AST,
7 std::optional<util::OwnedRegion> ASTByteCode,
8 std::unique_ptr<nixf::VariableLookupAnalysis> VLA,
9 std::shared_ptr<const std::string> Src)
10 : Diagnostics(std::move(Diagnostics)), AST(std::move(AST)),
11 ASTByteCode(std::move(ASTByteCode)), VLA(std::move(VLA)),
12 Src(std::move(Src)) {
13 assert(this->Src && "Source code should not be null");
14 if (this->AST) {
15 PMA = std::make_unique<nixf::ParentMapAnalysis>();
16 PMA->runOnAST(*this->AST);
17 }
18}
NixTU()=default
bool fromJSON(const llvm::json::Value &Params, Configuration::Diagnostic &R, llvm::json::Path P)