|
LLVM 22.0.0git
|
A scalar node is an opaque datum that can be presented as a series of zero or more Unicode scalar values. More...
#include "llvm/Support/YAMLParser.h"
Public Member Functions | |
| ScalarNode (std::unique_ptr< Document > &D, StringRef Anchor, StringRef Tag, StringRef Val) | |
| StringRef | getRawValue () const |
| StringRef | getValue (SmallVectorImpl< char > &Storage) const |
| Gets the value of this node as a StringRef. | |
| Public Member Functions inherited from llvm::yaml::Node | |
| Node (unsigned int Type, std::unique_ptr< Document > &, StringRef Anchor, StringRef Tag) | |
| Node (const Node &)=delete | |
| void | operator= (const Node &)=delete |
| void * | operator new (size_t Size, BumpPtrAllocator &Alloc, size_t Alignment=16) noexcept |
| void | operator delete (void *Ptr, BumpPtrAllocator &Alloc, size_t Size) noexcept |
| void | operator delete (void *) noexcept=delete |
| StringRef | getAnchor () const |
| Get the value of the anchor attached to this node. | |
| StringRef | getRawTag () const |
| Get the tag as it was written in the document. | |
| std::string | getVerbatimTag () const |
| Get the verbatium tag for a given Node. | |
| SMRange | getSourceRange () const |
| void | setSourceRange (SMRange SR) |
| Token & | peekNext () |
| Token | getNext () |
| Node * | parseBlockNode () |
| BumpPtrAllocator & | getAllocator () |
| void | setError (const Twine &Message, Token &Location) const |
| bool | failed () const |
| virtual void | skip () |
| unsigned int | getType () const |
Static Public Member Functions | |
| static bool | classof (const Node *N) |
Additional Inherited Members | |
| Public Types inherited from llvm::yaml::Node | |
| enum | NodeKind { NK_Null , NK_Scalar , NK_BlockScalar , NK_KeyValue , NK_Mapping , NK_Sequence , NK_Alias } |
| Protected Member Functions inherited from llvm::yaml::Node | |
| ~Node ()=default | |
| Protected Attributes inherited from llvm::yaml::Node | |
| std::unique_ptr< Document > & | Doc |
| SMRange | SourceRange |
A scalar node is an opaque datum that can be presented as a series of zero or more Unicode scalar values.
Example: Adena
Definition at line 214 of file YAMLParser.h.
|
inline |
Definition at line 218 of file YAMLParser.h.
References llvm::StringRef::begin(), D(), llvm::StringRef::end(), llvm::SMLoc::getFromPointer(), llvm::yaml::Node::NK_Scalar, llvm::yaml::Node::Node(), and llvm::yaml::Node::SourceRange.
Definition at line 238 of file YAMLParser.h.
References N, llvm::yaml::Node::NK_Scalar, and llvm::yaml::Node::Node().
|
inline |
Definition at line 229 of file YAMLParser.h.
| StringRef ScalarNode::getValue | ( | SmallVectorImpl< char > & | Storage | ) | const |
Gets the value of this node as a StringRef.
| Storage | is used to store the content of the returned StringRef if it requires any modification from how it appeared in the source. This happens with escaped characters and multi-line literals. |
Definition at line 2032 of file YAMLParser.cpp.