Fix and recommit r339382 based on solution from RSmith:
authorErich Keane <erich.keane@intel.com>
Thu, 9 Aug 2018 21:18:13 +0000 (21:18 +0000)
committerErich Keane <erich.keane@intel.com>
Thu, 9 Aug 2018 21:18:13 +0000 (21:18 +0000)
As sent on cfe-commits:
 "You need to use "friend TrailingObjects;" here, not
 "friend class TrailingObjects;", to avoid breaking MSVC
 (which doesn't implement injected-class-names quite according to spec)."

llvm-svn: 339389

clang/include/clang/Sema/ParsedAttr.h

index 1c7d001..34eb59e 100644 (file)
@@ -118,9 +118,7 @@ class ParsedAttr final
     : private llvm::TrailingObjects<
           ParsedAttr, ArgsUnion, detail::AvailabilityData,
           detail::TypeTagForDatatypeData, ParsedType, detail::PropertyData> {
-  friend class llvm::TrailingObjects<
-      ParsedAttr, ArgsUnion, detail::AvailabilityData,
-      detail::TypeTagForDatatypeData, ParsedType, detail::PropertyData>;
+  friend TrailingObjects;
 
   size_t numTrailingObjects(OverloadToken<ArgsUnion>) const { return NumArgs; }
   size_t numTrailingObjects(OverloadToken<detail::AvailabilityData>) const {