[Issue 6240] New: [GSoC] ICE - Assertion failure: 'next' on line 254 in file 'toctype.c'

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Jul 2 06:16:52 PDT 2011


http://d.puremagic.com/issues/show_bug.cgi?id=6240

           Summary: [GSoC] ICE - Assertion failure: 'next' on line 254 in
                    file 'toctype.c'
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Severity: major
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: cristi.cobzarenco at gmail.com


--- Comment #0 from Cristi Cobzarenco <cristi.cobzarenco at gmail.com> 2011-07-02 06:11:52 PDT ---
== File 1: imported.d ==
struct MixinAlias( T ) {
    private T m_;
    auto front() { return 1; }
}

mixin template Mixin( T ) {    
    alias MixinAlias!(typeof(this)) LocalAlias;
}

struct Mixer( T ) {
    mixin Mixin!( T );
}

== File 2: main.d ==
import imported;

int main() {
    alias Mixer!int Failure;
    return 0;
}

Compiled with: dmd imported.d main.d
Output: Assertion failure: 'next' on line 254 in file 'toctype.c'
Platform: Windows 7 x86_64
DMD: 2.053

The following things fix the error:
- Changing the order of the files.
- Moving everything in one module.
- Changing auto to int in the declaration of MixinAlias.front
- Moving the alias from Mixin to Mixer.
- Removing the member m_ from MixinAlias.

This bug might not seem major, but it's very hard to avoid in the design I've
chosen for my GSoC project.

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


More information about the Digitalmars-d-bugs mailing list