11 #include "llvm/Support/raw_ostream.h"
16 FailureOr<std::tuple<StringRef, int64_t, int64_t>>
24 diag(
"error: initializing FileLineColLocBreakpoint with empty file name");
30 auto [fileLine, colStr] = str.rsplit(
':');
31 auto [file, lineStr] = fileLine.rsplit(
':');
33 int64_t line = -1, col = -1;
34 if (lineStr.empty()) {
38 if (!colStr.empty() && colStr.getAsInteger(0, line))
41 if (lineStr.getAsInteger(0, line)) {
45 if (colStr.getAsInteger(0, line))
50 if (colStr.getAsInteger(0, col)) {
56 return std::tuple<StringRef, int64_t, int64_t>{file, line, col};
static std::string diag(const llvm::Value &value)
static FailureOr< std::tuple< StringRef, int64_t, int64_t > > parseFromString(StringRef str, llvm::function_ref< void(Twine)> diag=[](Twine) {})
Parse a string representation in the form of "<file>:<line>:<col>".
Include the generated interface declarations.