[Issue 13720] Adding trivial destructor to std.datetime causes Internal error: ..\ztc\cgelem.c 2418

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Sat Jun 13 14:50:49 PDT 2015


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

--- Comment #2 from Maxim Fomin <maxim-fomin at outlook.com> ---
module std.datetime;
import core.time;
import std.exception;

struct SysTime
{

    this(in TimeOfDay dateTime, in FracSec fracSec) { }

    /+deprecated+/ unittest
    {
        assertThrown!Exception(SysTime(TimeOfDay.init,
FracSec.from!"hnsecs"(-1)));
    }

}

struct TimeOfDay
{
    public pure nothrow @safe @nogc ~this() { }

    ubyte _hour;
    ubyte _minute;
    ubyte _second;
}

FracSec seems to be important.

--


More information about the Digitalmars-d-bugs mailing list