[PATCH] D26657: [Sema] Respect DLL attributes more faithfully

Hans Wennborg via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 29 15:48:20 PST 2016


hans added inline comments.


================
Comment at: include/clang/Sema/Sema.h:7495
+  /// \brief Make an existing DLL attribute on a class take effect.
+  void ActOnDLLAttr(ClassTemplateSpecializationDecl *Def,
+                    InheritableAttr *Attr);
----------------
hans wrote:
> I'd suggest making the function name more specific. It obviously doesn't apply to all DLL attributes, but only class templates.
> 
> Also, the "ActOn" methods in Sema are used as an interface to be called by the parser, so I would avoid that prefix.
> 
> Naming is hard :-/
> 
> Maybe `checkDllExportedTemplateSpecialization`
also it should be in the `private:` section since it's just a helper. And maybe the "check" part is unnecessary? `dllExportClassTemplateSpecialization` might work.


https://reviews.llvm.org/D26657





More information about the cfe-commits mailing list