Summary: ICE on const declaration
           Product: D
           Version: 2.030
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

Try compiling following snippet:

module sound;

import std.math;

struct Sound
    float time;
    float delegate(float) func;

    this(float delegate(float) f, float t)
        time = t;
        func = f;

    Sound opAdd(const(Sound) other)
        return Sound(
        (float t){
            return func(t) + other.func(t);
        }, fmax(time, other.time));

    Sound opCat(const(Sound) other)
        return Sound(
        (float t){
            if(t <= time)
                return func(t);
            return other.func(t - time);
        }, time + other.time);


Gives the error message:
Internal error: ../ztc/cod4.c 353

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to