[Article Submission] Have Your Efficiency, and Flexibility Too

Nick Sabalausky a at a.a
Tue May 31 19:57:20 PDT 2011


"bearophile" <bearophileHUGS at lycos.com> wrote in message 
news:is45u7$21vq$1 at digitalmars.com...
> Nick Sabalausky:
>
>> Error: template instance cannot use local 'np' as parameter to non-global
>> template addGizmosTo(int numPorts,bool isSpinnable)
>
> Are you able to reduce this to a minimal test case?
>

If it is indeed a bug then I'll try. But the fact that there's an error 
message for it seems to indicate this is intended for some reason. After 
all, addGizmosTo *is* a non-global template, just like the message says. And 
'np' shouldn't be visible outside the function it's in, ie, it's local.




More information about the Digitalmars-d mailing list