[PATCH] D60291: [llvm] Add isa_and_nonnull
Don Hinton via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 4 16:46:39 PDT 2019
hintonda marked an inline comment as done.
hintonda added inline comments.
================
Comment at: llvm/docs/ProgrammersManual.rst:167
+``isa_and_nonnull<>``:
+ The ``isa_and_nonnull<>`` operator works just like the ``isa<>`` operator,
----------------
hubert.reinterpretcast wrote:
> The name seems backwards. What does it mean to check "isa" on null? That question would not arise if the name was `nonnull_and_isa`.
Btw, there's been 4 naming comments so far, and each one is different. So, I hope we can come to a consensus soon. I originally thought `isa_or_null` was a good idea because it matches `(cast|dyn_cast)_or_null`, but since we're returning a bool and not a pointer, I no longer think that's a good name either.
So, I'm open to whatever is decided.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D60291/new/
https://reviews.llvm.org/D60291
More information about the llvm-commits
mailing list