www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 2435] New: Assertion failure: 'i < parameters->dim' on line 784 in file 'template.c'

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

           Summary: Assertion failure: 'i < parameters->dim' on line 784 in
                    file 'template.c'
           Product: D
           Version: 2.020
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: ice-on-invalid-code
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla digitalmars.com
        ReportedBy: samukha voliacable.com


Foo foo(A...)()
{
}

enum a = foo!(1, 2)();


-- 
Oct 31 2008
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2435


clugdbug yahoo.com.au changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Assertion failure: 'i <     |ICE when undefined type used
                   |parameters->dim' on line 784|in tuple function
                   |in file 'template.c'        |declaration
            Version|2.020                       |1.036




------- Comment #1 from clugdbug yahoo.com.au  2009-01-09 09:14 -------
Actually applies to D1 as well. Here's a slightly simplified test case:

Foo foo(A...)()
{
}

static assert(foo!(1, 2)());
--------
On DMD2:
Assertion failure: 'i < parameters->dim' on line 784 in file 'template.c'

On DMD1, it segfaults.
If there is only one parameter is passed to the tuple, it works correctly,
producing the error:
bug.d(1): Error: identifier 'Foo' is not defined

And another example shows that it's not the return value, it's any parameter:
--------
int foo(A...)(Foo x)
{
}

static assert(foo!(1,2)());


-- 
Jan 09 2009
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2435





------- Comment #2 from samukha voliacable.com  2009-01-09 10:05 -------
Looks like the same as http://d.puremagic.com/issues/show_bug.cgi?id=2229


-- 
Jan 09 2009
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=2435


dsimcha yahoo.com changed:

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




------- Comment #3 from dsimcha yahoo.com  2009-01-09 14:20 -------


*** This bug has been marked as a duplicate of 2229 ***


-- 
Jan 09 2009