LLVM: llvm::json::Path::Root Class Reference (original) (raw)
The root is the trivial [Path](classllvm%5F1%5F1json%5F1%5F1Path.html "A "cursor" marking a position within a Value.") to the root value. More...
#include "[llvm/Support/JSON.h](JSON%5F8h%5Fsource.html)"
| Public Member Functions | |
|---|---|
| Root (llvm::StringRef Name="") | |
| Root (Root &&)=delete | |
| Root & | operator= (Root &&)=delete |
| Root (const Root &)=delete | |
| Root & | operator= (const Root &)=delete |
| LLVM_ABI Error | getError () const |
| Returns the last error reported, or else a generic error. | |
| LLVM_ABI void | printErrorContext (const Value &, llvm::raw_ostream &) const |
| Print the root value with the error shown inline as a comment. |
Detailed Description
The root is the trivial [Path](classllvm%5F1%5F1json%5F1%5F1Path.html "A "cursor" marking a position within a Value.") to the root value.
It also stores the latest reported error and the path where it occurred.
Definition at line 715 of file JSON.h.
Constructor & Destructor Documentation
◆ Root() [1/3]
Definition at line 723 of file JSON.h.
Referenced by operator=(), operator=(), Root(), and Root().
◆ Root() [2/3]
| llvm::json::Path::Root::Root ( Root && ) | delete |
|---|
◆ Root() [3/3]
| llvm::json::Path::Root::Root ( const Root & ) | delete |
|---|
Member Function Documentation
◆ getError()
| Error llvm::json::Path::Root::getError | ( | ) | const |
|---|
◆ operator=() [1/2]
◆ operator=() [2/2]
| Root & llvm::json::Path::Root::operator= ( Root && ) | delete |
|---|
◆ printErrorContext()
Print the root value with the error shown inline as a comment.
Unrelated parts of the value are elided for brevity, e.g. { "id": 42, "name": /* expected string */ null, "properties": { ... } }
Definition at line 300 of file JSON.cpp.
References A(), llvm::json::abbreviate(), llvm::json::abbreviateChildren(), llvm::json::OStream::array(), llvm::json::OStream::attributeBegin(), llvm::json::OStream::attributeEnd(), llvm::json::OStream::comment(), llvm::json::OStream::object(), llvm::json::Path::Path(), and llvm::json::sortedElements().
Referenced by llvm::lsp::MessageHandler::parse().
◆ Path::report
The documentation for this class was generated from the following files: