35 "Unsupported file format.");
54 return Contents.takeError();
56 return std::optional<StringRef>{};
59Remark &RemarkLinker::keep(std::unique_ptr<Remark>
Remark) {
61 auto Inserted = Remarks.insert(std::move(
Remark));
62 return **Inserted.first;
66 PrependPath = std::string(PrependPathIn);
73 PrependPath ? std::make_optional<StringRef>(*PrependPath)
92 if (shouldKeepRemark(**Next))
93 keep(std::move(*Next));
104 if (std::optional<StringRef> Section = *SectionOrErr)
105 return link(*Section, RemarkFormat);
113 if (!MaybeSerializer)
116 std::unique_ptr<remarks::RemarkSerializer> Serializer =
117 std::move(*MaybeSerializer);
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
Lightweight error class with error context and mandatory checking.
static ErrorSuccess success()
Create a success value.
Tagged union holding either a T or a Error.
Error takeError()
Take ownership of the stored error.
StringRef - Represent a constant reference to a string, i.e.
This class is the base class for all object file types.
section_iterator_range sections() const
This is a value type class that represents a single section in the list of sections in the object fil...
This class implements an extremely fast bulk output stream that can only output to a stream.
This is an optimization pass for GlobalISel generic memory operations.
cl::opt< std::string > RemarksFormat("lto-pass-remarks-format", cl::desc("The format used for serializing remarks (default: YAML)"), cl::value_desc("format"), cl::init("yaml"))
Error createStringError(std::error_code EC, char const *Fmt, const Ts &... Vals)
Create formatted StringError object.
void consumeError(Error Err)
Consume a Error without doing anything.