smeenai added a comment. In https://reviews.llvm.org/D27153#613140, @EricWF wrote:
> In https://reviews.llvm.org/D27153#606296, @smeenai wrote: > > > I'm having some second thoughts about this. Visibility for template > > functions makes my head spin :/ Is there a general policy we've been > > following for these? I didn't find much just scanning through other > > definitions. > > > I would suggest adding the `inline` keyword so that implicit instantiation > are marked hidden when `-fvisibility-inlines-hidden`. That should be > sufficient to hide the implicit instantiations in `libc++.so`. I thought about that as well. It's slightly less intrusive, since it would only change the visibility for clients using `-fvisibility-inlines-hidden`. It also seems like a more roundabout way of going about hiding these symbols though, and we definitely don't want the compiler using the `inline` as a hint to actually perform inlining for this particular function (from what I understand, `inline` is mostly ignored as far as inlining goes, but it might have some effect on the compiler's cost models or something). I feel like, if the goal is to have these symbols hidden (and I think they should be), annotating the visibility explicitly is a better approach than marking as `inline`. What are your thoughts on that? https://reviews.llvm.org/D27153 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits