[PATCH] D25579: [codeview] emit debug info for indirect virtual base classes

David Majnemer via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 13 16:43:16 PDT 2016


majnemer added inline comments.


================
Comment at: lib/CodeGen/CGDebugInfo.cpp:1392
+    auto *BaseTy = getOrCreateType(BI.getType(), Unit);
+    if (SeenTypes.find(BaseTy) != SeenTypes.end())
+      continue;
----------------
ruiu wrote:
> zturner wrote:
> > rnk wrote:
> > > IMO `SeenTypes.count(...)` would be more idiomatic.
> > What a silly function.  I wonder why it isn't called `contains()` and return a `bool`.
> It's probably because std::set doesn't provide `contains()` but `count()` too.
You can use `is_contained` from STLExtras.h, it should be maximally idiomatic :)


https://reviews.llvm.org/D25579





More information about the cfe-commits mailing list