www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 17468] New: Internal assertion fails during CTFE

https://issues.dlang.org/show_bug.cgi?id=17468

          Issue ID: 17468
           Summary: Internal assertion fails during CTFE
           Product: D
           Version: D2
          Hardware: x86
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: andrei erdani.com

To repro:

struct S {
    immutable char* path;
     disable this();
    this(immutable(char)* path) {
        this.path = path;
    }
}

immutable S CONST_S = S("/tmp".ptr);

Compiling this yields:

core.exception.AssertError ddmd/ctfeexpr.d(413): Assertion failure

followed by a stack trace.

--
Jun 04