Re: Combining template parameters deduction with default template parameters

2014-03-23 Thread Uranuz
On Sunday, 23 March 2014 at 12:43:35 UTC, Philippe Sigaud wrote: On Sun, Mar 23, 2014 at 12:23 PM, Uranuz wrote: Yes. I like it more that ivoking one function from another. But this trick not working in DMD 2.063 as I understand. Is there any reason to still use 2.063 (honest question)? Th

Re: Combining template parameters deduction with default template parameters

2014-03-23 Thread Philippe Sigaud
On Sun, Mar 23, 2014 at 12:23 PM, Uranuz wrote: > Yes. I like it more that ivoking one function from another. But this trick > not working in DMD 2.063 as I understand. Is there any reason to still use 2.063 (honest question)? The current one is 2.065 with .066 in alpha state. .063 is almost a y

Re: Combining template parameters deduction with default template parameters

2014-03-23 Thread Uranuz
On Sunday, 23 March 2014 at 11:15:13 UTC, Andrej Mitrovic wrote: On 3/23/14, Uranuz wrote: I have a question how I could combine template parameters deduction with setting default values for template parameters. I will start directly from a piece of code. You can use eponymous templates for

Re: Combining template parameters deduction with default template parameters

2014-03-23 Thread Andrej Mitrovic
On 3/23/14, Uranuz wrote: > I have a question how I could combine template parameters > deduction with setting default values for template parameters. I > will start directly from a piece of code. You can use eponymous templates for this. E.g.: - template decodeURICustom(string allowedSpecCh

Re: Combining template parameters deduction with default template parameters

2014-03-23 Thread Uranuz
string decodeURIHost(T)(T source) { } But I like it less and I still don't know how to combine template params deduction with setting second param. string decodeURIHost(T, bool formEncoding)(T source) {}

Combining template parameters deduction with default template parameters

2014-03-23 Thread Uranuz
I have a question how I could combine template parameters deduction with setting default values for template parameters. I will start directly from a piece of code. string decodeURICustom(string allowedSpecChars = null, bool formEncoding = false, T)(T source) pure { //Some processing } I