Skip to content

Commit da4b88a

Browse files
committed
Review feedback
1 parent 4fe9ae2 commit da4b88a

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

offload/liboffload/include/OffloadImpl.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,9 @@ ErrSetT &errors();
7272
namespace {
7373
ol_errc_t GetErrorCode(std::error_code Code) {
7474
if (Code.category() ==
75-
error::make_error_code(error::ErrorCode::SUCCESS).category()) {
75+
error::make_error_code(error::ErrorCode::SUCCESS).category())
7676
return static_cast<ol_errc_t>(Code.value());
77-
}
77+
7878
return OL_ERRC_UNKNOWN;
7979
}
8080
} // namespace

offload/tools/offload-tblgen/EntryPointGen.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ static void EmitValidationFunc(const FunctionRec &F, raw_ostream &OS) {
4444
OS << formatv(TAB_2 "if ({0}) {{\n", ConditionString);
4545
OS << formatv(TAB_3 "return createOffloadError(error::ErrorCode::{0}, "
4646
"\"validation failure: {1}\");\n",
47-
Return.getEtorValue(), ConditionString);
47+
Return.getUnprefixedValue(), ConditionString);
4848
OS << TAB_2 "}\n\n";
4949
}
5050
}

offload/tools/offload-tblgen/RecordTypes.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ class ReturnRec {
186186
StringRef getValue() const { return rec->getValueAsString("value"); }
187187
// Strip the "OL_ERRC_" from the value, resulting in just "FOO" from
188188
// "OL_ERRC_FOO"
189-
StringRef getEtorValue() const {
189+
StringRef getUnprefixedValue() const {
190190
constexpr const char *ERRC = "ERRC_";
191191
auto Start = getValue().find(ERRC) + strlen(ERRC);
192192
return getValue().substr(Start);

0 commit comments

Comments
 (0)