www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 4311] New: Applying a template to a variadic template parameter in a templated function's parameter list breaks compilation

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4311

           Summary: Applying a template to a variadic template parameter
                    in a templated function's parameter list breaks
                    compilation
           Product: D
           Version: D2
          Platform: x86_64
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: simen.kjaras gmail.com


--- Comment #0 from Simen Kjaeraas <simen.kjaras gmail.com> 2010-06-14 06:39:51
PDT ---
Test case:

template foo( T... ) {
    alias T[0] foo; // Does not matter what is in here
}

auto bar( T... )( foo!T arg ) {
}

bar!( int, float )( 2 );



Error: template bar(T...) does not match any function template declaration
Error: template bar(T...) cannot deduce template function from argument types
!(1,2)()
Error: template instance errors instantiating template

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 14 2010
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4311



--- Comment #1 from Simen Kjaeraas <simen.kjaras gmail.com> 2010-06-14 06:42:13
PDT ---
Also, this works:

alias bar!( int, float ) baz;
baz( 2, 3 );

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 14 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4311



--- Comment #2 from Simen Kjaeraas <simen.kjaras gmail.com> 2010-10-26 15:26:36
PDT ---
(In reply to comment #1)
 Also, this works:
 
 alias bar!( int, float ) baz;
 baz( 2, 3 );
Apparently, this either no longer works, or I was a bit drunk when I wrote it. remove the 3, and things work: alias bar!( int, float ) baz; baz( 2 ); -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Oct 26 2010
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4311


Brad Roberts <braddr puremagic.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Platform|x86_64                      |x86


--- Comment #3 from Brad Roberts <braddr puremagic.com> 2011-02-06 15:39:49 PST
---
Mass migration of bugs marked as x86-64 to just x86.  The platform run on isn't
what's relevant, it's if the app is a 32 or 64 bit app.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 06 2011
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4311


SomeDude <lovelydear mailmetrash.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |lovelydear mailmetrash.com


--- Comment #4 from SomeDude <lovelydear mailmetrash.com> 2012-04-21 15:03:40
PDT ---
Compiles on 2.059.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Apr 21 2012
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=4311


Simen Kjaeraas <simen.kjaras gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


--- Comment #5 from Simen Kjaeraas <simen.kjaras gmail.com> 2012-05-13 12:27:11
PDT ---
Indeed.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 13 2012