From: jan.h.xie@... Date: 2009-01-17T00:53:34+09:00 Subject: Re: String interpolation at a later stage --Bu8it7iiRSEf40bY Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Raj Singh [2009-01-17 00:41:54 +0900]: > x =3D 'hello' > y =3D '#{x} world' >=20 > desired result =3D 'hello world' >=20 >=20 > Please note that variable y has the string interpolation code under > single quotes. >=20 > I have these two values x and y. And with that I need to get to the > desired result. Any suggestion on how to do that. >=20 > I tried eval y but that won't work because world is not a variable. eval %Q["#{y}"] Jan > --=20 > Posted via http://www.ruby-forum.com/. --=20 jan=3Dcallcc{|jan|jan};jan.call(jan) --Bu8it7iiRSEf40bY Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iQEcBAEBAgAGBQJJcK21AAoJEBcDvo3O83d6LQMH/3NrRZzHPQ0u0LCfo7W4TnXW Z0S9K/8fU0z7jUUI6bvsPUy81MHLZg68h97OXuFMiBf5fvYd4b5F/ef0nQluxqY0 CaYF7IsM886gKl3ICLMHOVf5bHqB1/ZgqrxQPEVCp93hVe5OZlJI1FrQZmdFs3PD 2Pf9j/TMx8Fevm/DYltnqGuhSR5lQS5ApY72OxYBqf3tFIYqoukOHPQC1uIiQlFT rs1vxO6bM85OfOiOsgaNE0Riec97z3R5Ehi+R82bb0+6RxW1KvizeWqpB9EDSfVw hExLUZdkDv6lYxhU6KTpi+KlcuGQRdyPeDZNbDVhzs6EPYeRZ8gZQadDba8VPsA= =Rq6e -----END PGP SIGNATURE----- --Bu8it7iiRSEf40bY--