Logical location of template instantiations
Enamex via Digitalmars-d
digitalmars-d at puremagic.com
Fri Jul 1 05:27:27 PDT 2016
On Friday, 1 July 2016 at 12:08:49 UTC, Lodovico Giaretta wrote:
> On Friday, 1 July 2016 at 11:45:12 UTC, Robert burner Schadek
> wrote:
>> IMO, this is one of these places where theory meets practice.
>> Do what works, write a comment explaining the problem, and
>> move on ;-)
>
> Yes, well, I successfully bypassed my issues with this thing,
> but I wanted to share my thoughts about the need to express
> this kind of thing (i.e. to give a template instantiation the
> privileges of the instantiating module), and to know if someone
> else has some opinion on this matter.
Yeah. I don't know if it's _needed_ by enough people or by the
language, but a way to force templates to be hijacked while being
instantiated (not at point of definition but at instantiation;
though I imagine this might prove troublesome for reflection and
template identity, somehow) if we want to. The default hygienic
behavior is great, but bypassing it when needed is not.
More information about the Digitalmars-d
mailing list