Extending library functions

Jacob Carlborg doob at me.com
Thu Oct 18 11:39:32 PDT 2012


On 2012-10-18 15:35, simendsjo wrote:

> I don't think you can overload template methods with non-template methods

You cannot. The usual workaround for this is to make the non-template 
method a dummy template:

void foo () (int a) {} // Note the extra pair of empty parentheses

But this won't work if you're not controlling the non-template method.

-- 
/Jacob Carlborg


More information about the Digitalmars-d-learn mailing list