Skip to content

Commit 2a4992e

Browse files
Fix mistake in comment regarding dyn_cast_or_null (#108026)
There was a mistake in a comment regarding dyn_cast_or_null deprication. It was suggested to use cast_if_present instead of dyn_cast_or_null, but that was probably a copy paste mistake, and dyn_cast_if_present is the function that should be used instead of dyn_cast_or_null. Authored-by: Ofri Frishman <[email protected]>
1 parent ccc52a8 commit 2a4992e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/include/llvm/Support/Casting.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -755,7 +755,7 @@ template <class X, class Y> auto dyn_cast_if_present(Y *Val) {
755755

756756
// Forwards to dyn_cast_if_present to avoid breaking current users. This is
757757
// deprecated and will be removed in a future patch, use
758-
// cast_if_present instead.
758+
// dyn_cast_if_present instead.
759759
template <class X, class Y> auto dyn_cast_or_null(const Y &Val) {
760760
return dyn_cast_if_present<X>(Val);
761761
}

0 commit comments

Comments
 (0)