Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
私はこの正規表現を持っています:
/(.*wwa)?#{var}([1-2]?)/
そして、2 つの警告が表示されます: Regexp has invalid interval regexp has '}' without escape
私が行方不明になっていることは明らかですが、それが何であるかを見つけることができません。
これを再現できる唯一の方法は、Ruby 1.8.7 に戻って、オプションで角かっこの間に何かをvar含めることです。#{}
var
#{}
まず、Ruby をアップグレードすると、これらのエラーは発生しなくなります。
var第二に、補間文字列が含まれている場合、バグがあると思われます。