Make regexp 15 and regexp 16 work.

Also, introduce a helper function to test regexps.