Gabriel Dos Reis wrote:
Mark Mitchell <[EMAIL PROTECTED]> writes:
| I'm just not comfortable with the idea of #pragmas affecting
| instantiations.  (I'm OK with them affecting specializations, though; in
| that case, the original template has basically no impact, so I think
| it's fine to treat the specialization case as if it were any other
| function.)

I'm undecided whether #pragmas should not affect explicit
instantiations.  They really are not like implicit instantiations
(which, I agree with you, should not be affected). Explicit instantiations behave more like real declarations than implicit instantiations.

Yep. I'm sympathetic to Mark's position, but still tend to believe that the #pragma should affect explicit instantiations. Explicit instantiations are a way to make template instantiations conform more to the traditional declaration/definition model. We ignore the #pragmas for implicit instantiations because the user doesn't control the point of instantiation; with explicit instantiations, they do.

Explicit instantiations don't behave just like implicit instantiations; there are other differences.

Jason

Reply via email to