Lines Matching refs:Expected

27   assert(Ctx && "Expected non-null Ctx in diagnostic handler.");
29 assert(Message.empty() && "Expected an empty string.");
62 static Expected<bool> parseMagic(StringRef &Buf) {
72 static Expected<uint64_t> parseVersion(StringRef &Buf) {
88 static Expected<uint64_t> parseStrTabSize(StringRef &Buf) {
98 static Expected<ParsedStringTable> parseStrTab(StringRef &Buf,
107 return Expected<ParsedStringTable>(std::move(Result));
110 Expected<std::unique_ptr<YAMLRemarkParser>> remarks::createYAMLParserFromMeta(
114 Expected<bool> isMeta = parseMagic(Buf);
120 Expected<uint64_t> Version = parseVersion(Buf);
124 Expected<uint64_t> StrTabSize = parseStrTabSize(Buf);
133 Expected<ParsedStringTable> MaybeStrTab = parseStrTab(Buf, *StrTabSize);
188 Expected<std::unique_ptr<Remark>>
208 Expected<Type> T = parseType(*Root);
216 Expected<StringRef> MaybeKey = parseKey(RemarkField);
222 if (Expected<StringRef> MaybeStr = parseStr(RemarkField))
227 if (Expected<StringRef> MaybeStr = parseStr(RemarkField))
232 if (Expected<StringRef> MaybeStr = parseStr(RemarkField))
237 if (Expected<unsigned> MaybeU = parseUnsigned(RemarkField))
242 if (Expected<RemarkLocation> MaybeLoc = parseDebugLoc(RemarkField))
252 if (Expected<Argument> MaybeArg = parseArg(Arg))
271 Expected<Type> YAMLRemarkParser::parseType(yaml::MappingNode &Node) {
285 Expected<StringRef> YAMLRemarkParser::parseKey(yaml::KeyValueNode &Node) {
292 Expected<StringRef> YAMLRemarkParser::parseStr(yaml::KeyValueNode &Node) {
311 Expected<unsigned> YAMLRemarkParser::parseUnsigned(yaml::KeyValueNode &Node) {
322 Expected<RemarkLocation>
333 Expected<StringRef> MaybeKey = parseKey(DLNode);
339 if (Expected<StringRef> MaybeStr = parseStr(DLNode))
344 if (Expected<unsigned> MaybeU = parseUnsigned(DLNode))
349 if (Expected<unsigned> MaybeU = parseUnsigned(DLNode))
365 Expected<Argument> YAMLRemarkParser::parseArg(yaml::Node &Node) {
375 Expected<StringRef> MaybeKey = parseKey(ArgEntry);
387 if (Expected<RemarkLocation> MaybeLoc = parseDebugLoc(ArgEntry)) {
399 if (Expected<StringRef> MaybeStr = parseStr(ArgEntry))
416 Expected<std::unique_ptr<Remark>> YAMLRemarkParser::next() {
420 Expected<std::unique_ptr<Remark>> MaybeResult = parseRemark(*YAMLIt);
432 Expected<StringRef> YAMLStrTabRemarkParser::parseStr(yaml::KeyValueNode &Node) {
446 if (Expected<unsigned> MaybeStrID = parseUnsigned(Node))
451 if (Expected<StringRef> Str = (*StrTab)[StrID])