[Lldb-commits] [lldb] [DRAFT][lldb] Upgrade CompilerType::GetIndexOfFieldWithName to return llvm::Expected (PR #135963)
Michael Buch via lldb-commits
lldb-commits at lists.llvm.org
Wed Apr 16 07:22:17 PDT 2025
================
@@ -909,7 +909,7 @@ uint32_t CompilerType::GetIndexOfFieldWithName(
return index;
}
}
- return UINT32_MAX;
+ return llvm::createStringError("Invalid name: Cannot find index");
----------------
Michael137 wrote:
Could we include the name of the field? This should work:
```
llvm::createStringError("Cannot find index of field '%s'", name);
```
https://github.com/llvm/llvm-project/pull/135963
More information about the lldb-commits
mailing list