[PATCH] D90928: [OpenCL] Add assertions to extension lookup

Anastasia Stulova via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 10 09:33:13 PST 2020


Anastasia added a comment.

In D90928#2382111 <https://reviews.llvm.org/D90928#2382111>, @erik2020 wrote:

> In D90928#2379322 <https://reviews.llvm.org/D90928#2379322>, @Anastasia wrote:
>
>> Ok, it would still segfault but perhaps it is acceptable as this is an internal frontend only option for now.
>
> Would it be better if these functions returned `false` for unknown extensions? I think it would be consistent with the function names (e.g., `isEnabled()` returns `false` for an unknown extensions, because an unknown extension cannot be enabled).

Yes, this makes more sense indeed.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D90928/new/

https://reviews.llvm.org/D90928



More information about the cfe-commits mailing list