Teh New Ruby Evil 12 Apr 2009
Found a beauty I don’t know how I missed before:
bar = 'hello world'
foo =~ /#{bar}/
I didn’t realize you could do interpolation into regex literals. I don’t know how I lasted this long without finding out!
Found a beauty I don’t know how I missed before:
bar = 'hello world'
foo =~ /#{bar}/
I didn’t realize you could do interpolation into regex literals. I don’t know how I lasted this long without finding out!