Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: JRuby 1.6
-
Fix Version/s: JRuby 1.6.4, JRuby 1.7.0.pre1
-
Component/s: None
-
Labels:None
-
Environment:osx snow leopard
-
Testcase included:yes
-
Number of attachments :
Description
String interpolation into regexes appears to break unicode property names.
This script works under MRI 1.9.2.
{{# encoding: UTF-8
- The following two scenarios work
puts /[\p {L}]/u
puts /[#{"
p{L}"}]/u
- this one raises an exception
- RegexpError: (RegexpError) invalid character property name
{L}: /\p{L}
/
{L}
b = "
p"
{b}
puts /[#]/u}}
This is currently preventing datamapper from running on jruby 1.9, because it uses this technique in dm-validations to validate email addresses.
Activity
Nick Sieger
made changes -
| Field | Original Value | New Value |
|---|---|---|
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Assignee | Thomas E Enebo [ enebo ] | Nick Sieger [ nsieger ] |
| Fix Version/s | JRuby 1.6.4 [ 17472 ] | |
| Fix Version/s | JRuby 1.7 [ 17049 ] | |
| Resolution | Fixed [ 1 ] |
Charles Oliver Nutter
made changes -
| Status | Resolved [ 5 ] | Closed [ 6 ] |
I fail at formatting .... here is a gist with the test case:
https://gist.github.com/5dd56997b3e5a8b9eee6