ello


can someone tell me why this seemingly simple reg ex to look for any single hebrew char in a string doesn't work?

Code:
var rtl_match: RegExp = new RegExp('[\u0590–\u05FF]', 'g');
http://unicode.org/charts/PDF/U0590.pdf

I've tried both with and without the global flag, I've tried using the short-hand syntax I've tried resetting lastIndex to 0 before and after use. If I loop through the text and inspect each char using charCodeAt(x) hebrew characters always return a number within the range defined in the reg ex.

No matter what I try however whenever I test a string:

rtl_match.test(str);

it always returns false and it's driving me up the wall.

I'm new to reg ex's so there's the chance I'm doing something fundamentally wrong however I'm using more complex patterns in more complex ways elsewhere without problem


Thanks