[flang-commits] [flang] [llvm] [flang] Improve runtime SAME_TYPE_AS() (PR #135670)

Andre Kuhlenschmidt via flang-commits flang-commits at lists.llvm.org
Mon Apr 14 14:09:13 PDT 2025


================
@@ -155,7 +133,7 @@ bool RTDEF(ExtendsTypeOf)(const Descriptor &a, const Descriptor &mold) {
     // dynamic type of MOLD.
     for (const typeInfo::DerivedType *derivedTypeA{GetDerivedType(a)};
          derivedTypeA; derivedTypeA = derivedTypeA->GetParentType()) {
-      if (CompareDerivedType(derivedTypeA, derivedTypeMold)) {
+      if (derivedTypeA == derivedTypeMold) {
----------------
akuhlens wrote:

I was kinda expecting you to call `SameTypeAs` here? Is `==` for derived type structural or pointer equality?

https://github.com/llvm/llvm-project/pull/135670


More information about the flang-commits mailing list