import std.uni;
void main() {
isUniAlpha(' ');//crash
}
Reason:
isUniAlpha uses a binary search, with end condition "while (low<=high)", low and high being uints. At some point the only table entry to test is [0], low and high are both 0, mid will be 0 and since entry [0] is still not OK, high=mid-1 => ~0.
Fix:
make low,high,end "int".
dmd\src\phobos\std\uni.c, line 461-463
int mid;
int low;
int high;
(The fix was tested and works)
Comment #1 by benoit — 2006-06-18T13:53:07Z
*** This bug has been marked as a duplicate of 202 ***