Skip to content

Commit 2b85b4f

Browse files
committed
Apply suggestions
1 parent b969f88 commit 2b85b4f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

options_compile.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,8 +287,9 @@ std::string EffectiveOptionsFilter::processOptions(const OpenCLArgList &args,
287287

288288
auto parseClExt = [&](const std::string &clExtStr) {
289289
llvm::StringRef clExtRef(clExtStr);
290-
if (!clExtRef.consume_front("-cl-ext="))
291-
return;
290+
bool hasPrefix = clExtRef.consume_front("-cl-ext=");
291+
assert(hasPrefix && "clExtRef doesn't start with \"-cl-ext\" prefix");
292+
(void)hasPrefix;
292293
llvm::SmallVector<llvm::StringRef, 32> parsedExt;
293294
clExtRef.split(parsedExt, ',');
294295
for (auto &ext : parsedExt) {

0 commit comments

Comments
 (0)