ben lowery

WTF: assertFalse(/foo/.test(null)) fails?

May 29 2009
$ js
Rhino 1.7 release 1 2008 03 06
js> var foo = new RegExp("([a-zA-Z/])+");
/([a-zA-Z/])+/
js> foo.test(null)
true

What? Passing null to a regexp passes?

Related posts:

  1. A Test
  2. Tuesday
  3. Object cannot be created in this context, Code: 9 revisited
  4. The beginning (of the end?)
  5. Crack

Leave a Reply