LLVM API Documentation
#include "llvm/Support/YAMLParser.h"#include "llvm/ADT/SmallVector.h"#include "llvm/ADT/StringExtras.h"#include "llvm/ADT/Twine.h"#include "llvm/ADT/ilist.h"#include "llvm/ADT/ilist_node.h"#include "llvm/Support/ErrorHandling.h"#include "llvm/Support/MemoryBuffer.h"#include "llvm/Support/SourceMgr.h"#include "llvm/Support/raw_ostream.h"
Go to the source code of this file.
Classes | |
| struct | llvm::yaml::Token |
| Token - A single YAML token. More... | |
| struct | llvm::ilist_sentinel_traits< Token > |
| struct | llvm::ilist_node_traits< Token > |
| class | llvm::yaml::Scanner |
| Scans YAML tokens from a MemoryBuffer. More... | |
Namespaces | |
| namespace | llvm |
List of target independent CodeGen pass IDs. | |
| namespace | llvm::yaml |
Typedefs | |
| typedef std::pair < UnicodeEncodingForm, unsigned > | EncodingInfo |
| typedef ilist< Token > | TokenQueueT |
| typedef std::pair< uint32_t, unsigned > | UTF8Decoded |
| The Unicode scalar value of a UTF-8 minimal well-formed code unit subsequence and the subsequence's length in code units (uint8_t). A length of 0 represents an error. | |
Enumerations | |
| enum | UnicodeEncodingForm { UEF_UTF32_LE, UEF_UTF32_BE, UEF_UTF16_LE, UEF_UTF16_BE, UEF_UTF8, UEF_Unknown } |
Functions | |
| static EncodingInfo | getUnicodeEncoding (StringRef Input) |
| static UTF8Decoded | decodeUTF8 (StringRef Range) |
| static void | encodeUTF8 (uint32_t UnicodeScalarValue, SmallVectorImpl< char > &Result) |
| encodeUTF8 - Encode UnicodeScalarValue in UTF-8 and append it to result. | |
| static bool | is_ns_hex_digit (const char C) |
| static bool | is_ns_word_char (const char C) |
| static LLVM_ATTRIBUTE_NOINLINE bool | wasEscaped (StringRef::iterator First, StringRef::iterator Position) |
| typedef std::pair<UnicodeEncodingForm, unsigned> EncodingInfo |
EncodingInfo - Holds the encoding type and length of the byte order mark if it exists. Length is in {0, 2, 3, 4}.
Definition at line 39 of file YAMLParser.cpp.
| typedef ilist<Token> TokenQueueT |
Definition at line 177 of file YAMLParser.cpp.
| typedef std::pair<uint32_t, unsigned> UTF8Decoded |
The Unicode scalar value of a UTF-8 minimal well-formed code unit subsequence and the subsequence's length in code units (uint8_t). A length of 0 represents an error.
Definition at line 205 of file YAMLParser.cpp.
| enum UnicodeEncodingForm |
Definition at line 28 of file YAMLParser.cpp.
| static UTF8Decoded decodeUTF8 | ( | StringRef | Range | ) | [static] |
Definition at line 207 of file YAMLParser.cpp.
References llvm::StringRef::begin(), and llvm::StringRef::end().
Referenced by llvm::yaml::escape().
| static void encodeUTF8 | ( | uint32_t | UnicodeScalarValue, |
| SmallVectorImpl< char > & | Result | ||
| ) | [static] |
encodeUTF8 - Encode UnicodeScalarValue in UTF-8 and append it to result.
Definition at line 519 of file YAMLParser.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().
Referenced by llvm::yaml::escape().
| static EncodingInfo getUnicodeEncoding | ( | StringRef | Input | ) | [static] |
getUnicodeEncoding - Reads up to the first 4 bytes to determine the Unicode encoding form of Input.
| Input | A string of length 0 or more. |
Definition at line 47 of file YAMLParser.cpp.
References llvm::StringRef::size(), UEF_Unknown, UEF_UTF16_BE, UEF_UTF16_LE, UEF_UTF32_BE, UEF_UTF32_LE, and UEF_UTF8.
| static bool is_ns_hex_digit | ( | const char | C | ) | [static] |
Definition at line 837 of file YAMLParser.cpp.
| static bool is_ns_word_char | ( | const char | C | ) | [static] |
Definition at line 843 of file YAMLParser.cpp.
| static bool wasEscaped | ( | StringRef::iterator | First, |
| StringRef::iterator | Position | ||
| ) | [static] |
Definition at line 1182 of file YAMLParser.cpp.
References I.