rsmith added inline comments.

================
Comment at: clang/include/clang/AST/DeclTemplate.h:1771-1779
+  void setIsSpecializedMember(bool V = true) { IsSpecializedMember = V; }
+
+  /// If this class template specialization was declared at class scope 
(DR727).
+  /// For example, the specialization G<int> below:
+  ///   struct S {
+  ///     template <class> struct G {};
+  ///     template <> struct G<int> {};
----------------
I think this name is confusing, given that we also have 
`isMemberSpecialization`, which is an entirely different thing.

Maybe `isInstantiatedSpecialization` would capture the essence here? (That is, 
this is a partial or explicit specialization that we instantiated from its 
enclosing template context rather than one that was declared in a non-template 
context.)

That also makes me wonder if we need to store additional state for this at all, 
or if we can determine this by checking whether the (first) declaration 
`isOutOfLine()`.


Repository:
  rC Clang

https://reviews.llvm.org/D52521



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
  • [PATCH] D52521: [... Richard Smith - zygoloid via Phabricator via cfe-commits

Reply via email to