To me this looks like a library error, but I'm not sure.  Any suggestions
import    std.uni;

char    gcCat1    (dchar ch)
{  if    (ch in unicode.L)        return    'L';        //    Letter
    if    (ch in unicode.M)        return    'M';        //    Mask
if (ch in unicode.C) return 'C'; // Control <<== error here!
    if    (ch in unicode.N)        return    'N';        //  Numeric
    if    (ch in unicode.P)        return    'P';        //  Punctuation
    if    (ch in unicode.S)        return    'S';        //  Symbol
    if    (ch in unicode.Z)        return    'Z';        //  Separator

    return    '?';
}

$ rdmd --main -unittest test2.d
/usr/include/dmd/phobos/std/uni.d(6220): Error: slice [0..2] exceeds array bounds [0..1] /usr/include/dmd/phobos/std/uni.d(6220): called from here: comparePropertyName(name[0..2], "In") /usr/include/dmd/phobos/std/uni.d(6119): called from here: findAny("C") /usr/include/dmd/phobos/std/uni.d(6122): Error: static assert "No unicode set by name C was found."
test2.d(7):        instantiated from here: opDispatch!"C"
Failed: ["dmd", "-unittest", "-v", "-o-", "test2.d", "-I."]


$ dmd
DMD64 D Compiler v2.068.2
Copyright (c) 1999-2015 by Digital Mars written by Walter Bright
Documentation: http://dlang.org/
Config file: /etc/dmd.conf
...

Reply via email to