This project is archived and is in readonly mode.

#783 ✓resolved
Stefan Kaes

AUTOLINK_RE ruby 1.9 compatibility fix

Reported by Stefan Kaes | August 8th, 2008 @ 10:23 AM | in 2.x

ruby 1.9 complains about some regexp being too complex:


activesupport/lib/active_support/dependencies.rb:510: warning: nested repeat operator + and ? was replaced with '*'

not very helpful, eh?

after tracing the requires I simplified


(?:/(?:(?:[~\w\+@%=\(\)-]|(?:[,.;:'][^\s$]))+)?)* # path

to


(?:/(?:[~\w\+@%=\(\)-]|(?:[,.;:'][^\s$]))*)* # path

this stops the warning, and should be equivalent (I think so and there no test failures).

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments

Tags

Referenced by

Pages