[llvm-commits] [llvm] r114280 - /llvm/trunk/include/llvm/Support/Casting.h

Gabor Greif ggreif at gmail.com
Sat Sep 18 05:56:47 PDT 2010


Author: ggreif
Date: Sat Sep 18 07:56:47 2010
New Revision: 114280

URL: http://llvm.org/viewvc/llvm-project?rev=114280&view=rev
Log:
back out r114279 as some darwin buildbots get errors compiling clang:
svn merge -c -114279 llvm/include/llvm/Support/Casting.h

Modified:
    llvm/trunk/include/llvm/Support/Casting.h

Modified: llvm/trunk/include/llvm/Support/Casting.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/Casting.h?rev=114280&r1=114279&r2=114280&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Support/Casting.h (original)
+++ llvm/trunk/include/llvm/Support/Casting.h Sat Sep 18 07:56:47 2010
@@ -232,8 +232,8 @@
 // value is accepted.
 //
 template <class X, class Y>
-inline typename cast_retty<X, Y*>::ret_type dyn_cast_or_null(Y *Val) {
-  return (Val && isa<X>(Val)) ? cast<X>(Val) : 0;
+inline typename cast_retty<X, Y>::ret_type dyn_cast_or_null(const Y &Val) {
+  return (Val && isa<X>(Val)) ? cast<X, Y>(Val) : 0;
 }
 
 } // End llvm namespace





More information about the llvm-commits mailing list