From: Hal Fulton Date: 2003-09-17T07:29:04+09:00 Subject: Re: #{} and \" don't like each other Peter wrote: >>From the Programming Ruby book: > > In addition, you can substitute the value of any Ruby expression > into a string using the sequence #{ expr }. > > > Up to about an hour ago, I never doubted this statement. I've stumbled > upon the following example which is not accepted by ruby. Fulton's Third Law says that there is an exception to every rule, except Fulton's Third Law. > Can someone please tell me whether this is a bug, or otherwise why I > shouldn't have done the above. Truthfully, I'm not sure why this happens. But since the warning is accurate and explicit, I don't think it's a bug, but perhaps one of those features that's it's not immediately obvious we need. FWIW, this avoids it: name = "peter" print "" So it evidently has to do specifically with the escaped terminator *inside* the interpolated part. Hal