_d_switch_dstring

Same thing, but for wide chars.

extern (C)
int
_d_switch_dstring
(
dchar[][] table
,
dchar[] ca
)
out (result) { int i; int c; if (result == -1) { for ( i = 0; i < table.length; i++) { if (table[i].length == ca.length) { c = memcmp(table[i].ptr, ca.ptr, ca.length * dchar.sizeof); assert (c != 0); } } } else { assert (0 <= result && result < table.length); for ( i = 0; 1; i++) { assert (i < table.length); if (table[i].length == ca.length) { c = memcmp(table[i].ptr, ca.ptr, ca.length * dchar.sizeof); if (c == 0) { assert (i == result); break; } } } } }

Meta