The following should support type inferencing:
("" =~ /pattern/).hasGroup()
("" ==~ /pattern/).booleanValue()
Please disregard the second example as this works
Actually, the second expression works by accident. The type of the expression is String (should be boolean). String has a booleanValue method as well.
Oops. I was wrong. The second example was indeed working properly (booleanValue is not a method on String).
Anyway, the first one is fixed now as well.
I notice this still isn't working in 2.5.2.xx-20110729-1800-e37. Should it?
A build hasn't gone through in the past few days. It is working with the code as it is in version control, but there is not yet a snapshot available.