Generate test functions using the RegExp prototype.

  var testForA = RegExp.prototype.test.bind(/[aA]/);
  // function () { [native code] }

  testForA('hello');
  // false

  testForA('hella');
  // true

  ['hello', 'hella', 'holla'].filter(testForA);
  // ['hella', 'holla']

Oh the lengths we'll go to avoid typing 'function'