[llvm-commits] [dragonegg] r96350 - /dragonegg/trunk/llvm-types.cpp

Duncan Sands baldrick at free.fr
Tue Feb 16 07:15:11 PST 2010


Author: baldrick
Date: Tue Feb 16 09:15:11 2010
New Revision: 96350

URL: http://llvm.org/viewvc/llvm-project?rev=96350&view=rev
Log:
Use isOpaqueTy rather than isa<OpaqueType>.

Modified:
    dragonegg/trunk/llvm-types.cpp

Modified: dragonegg/trunk/llvm-types.cpp
URL: http://llvm.org/viewvc/llvm-project/dragonegg/trunk/llvm-types.cpp?rev=96350&r1=96349&r2=96350&view=diff

==============================================================================
--- dragonegg/trunk/llvm-types.cpp (original)
+++ dragonegg/trunk/llvm-types.cpp Tue Feb 16 09:15:11 2010
@@ -742,7 +742,7 @@
       // of the vector.  Remove this entry from the PointersToReresolve list and
       // get the pointee type.  Note that this order is important in case the
       // pointee type uses this pointer.
-      assert(isa<OpaqueType>(PTy->getElementType()) && "Not a deferred ref!");
+      assert(PTy->getElementType()->isOpaqueTy() && "Not a deferred ref!");
 
       // We are actively resolving this pointer.  We want to pop this value from
       // the stack, as we are no longer resolving it.  However, we don't want to
@@ -1165,7 +1165,7 @@
   for (; Args && TREE_VALUE(Args) != void_type_node; Args = TREE_CHAIN(Args)){
     tree ArgTy = TREE_VALUE(Args);
     if (!isPassedByInvisibleReference(ArgTy) &&
-        isa<OpaqueType>(ConvertType(ArgTy))) {
+        ConvertType(ArgTy)->isOpaqueTy()) {
       // If we are passing an opaque struct by value, we don't know how many
       // arguments it will turn into.  Because we can't handle this yet,
       // codegen the prototype as (...).
@@ -1927,7 +1927,7 @@
   if (const Type *Ty = GET_TYPE_LLVM(type)) {
     // If we already compiled this type, and if it was not a forward
     // definition that is now defined, use the old type.
-    if (!isa<OpaqueType>(Ty) || TYPE_SIZE(type) == 0)
+    if (!Ty->isOpaqueTy() || TYPE_SIZE(type) == 0)
       return Ty;
   }
 





More information about the llvm-commits mailing list