[cfe-commits] Linkage and visibility of parameter list

Rafael EspĂ­ndola rafael.espindola at gmail.com
Fri Jun 1 14:06:39 PDT 2012


ping.

On 29 May 2012 00:00, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote:
> Clang computes the linkage and visibility of both parameter lists and
> arguments lists of templates. As far as I can tell, the parameter list
> computation is currently dead code. It would only have an effect in
> cases where the arguments are less restrictive than the parameters.
> For visibility, this would be something like
>
> struct HIDDEN foo {
> };
> DEFAULT foo x;
> template<foo *z>
> void DEFAULT zed() {
> }
> template void zed<&x>();
>
> But in case like this we currently pick the first explicit visibility
> we find (the one in x). I am not sure if it possible to write an
> equivalent case for linkage.
>
> There are two patches attached. The first one changes the merging so
> that the parameter list linkage and visibility computation is no
> longer dead. The second one simply deletes it. For what it is worth,
> gcc 4.7 agrees with the second patch.
>
> Cheers,
> Rafael




More information about the cfe-commits mailing list