Skip to content

Commit 5f15c17

Browse files
authored
[llvm][Docs] _or_null -> _if_present in Programmer's Manual (#98586)
`cast_or_null` is deprecated. https://github.com/llvm/llvm-project/blob/062844615db5e141da118c1ad780bf102537f40a/llvm/include/llvm/Support/Casting.h#L717-L722
1 parent 1415365 commit 5f15c17

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

llvm/docs/ProgrammersManual.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -164,20 +164,20 @@ rarely have to include this file directly).
164164
efficient to use the ``InstVisitor`` class to dispatch over the instruction
165165
type directly.
166166

167-
``isa_and_nonnull<>``:
168-
The ``isa_and_nonnull<>`` operator works just like the ``isa<>`` operator,
167+
``isa_and_present<>``:
168+
The ``isa_and_present<>`` operator works just like the ``isa<>`` operator,
169169
except that it allows for a null pointer as an argument (which it then
170170
returns false). This can sometimes be useful, allowing you to combine several
171171
null checks into one.
172172

173-
``cast_or_null<>``:
174-
The ``cast_or_null<>`` operator works just like the ``cast<>`` operator,
173+
``cast_if_present<>``:
174+
The ``cast_if_present<>`` operator works just like the ``cast<>`` operator,
175175
except that it allows for a null pointer as an argument (which it then
176176
propagates). This can sometimes be useful, allowing you to combine several
177177
null checks into one.
178178

179-
``dyn_cast_or_null<>``:
180-
The ``dyn_cast_or_null<>`` operator works just like the ``dyn_cast<>``
179+
``dyn_cast_if_present<>``:
180+
The ``dyn_cast_if_present<>`` operator works just like the ``dyn_cast<>``
181181
operator, except that it allows for a null pointer as an argument (which it
182182
then propagates). This can sometimes be useful, allowing you to combine
183183
several null checks into one.

0 commit comments

Comments
 (0)