Issue #11038 has been reported by Norberto Martins.

----------------------------------------
Bug #11038: regular expression fail
https://bugs.ruby-lang.org/issues/11038

* Author: Norberto Martins
* Status: Open
* Priority: Low
* Assignee: 
* ruby -v: ruby 2.0.0p598 (2014-11-13 revision 48408) [x86_64-linux]
* Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN
----------------------------------------
the following regexp seems to loop
/^([A-Z0-9_%+-]+\.?)+[^.]@([A-Z0-9-]+\.)+[A-Z]{2,4}$/i

with "ec-mat-charles-perrault-voves-28@ac-orleans-tours"

you can test with: 
'ec-mat-charles-perrault-voves-28@ac-orleans-tours' =~ /^([A-Z0-9_%+-]+\.?)+[^.]@([A-Z0-9-]+\.)+[A-Z]{2,4}$/i



-- 
https://bugs.ruby-lang.org/