Re: Reviving E4X (H4E)?

On Wed, Oct 19, 2011 at 16:56, Allen Wirfs-Brock <allen@wirfs-brock.com> wrote:
>
> On Oct 19, 2011, at 1:55 PM, ☻Mike Samuel wrote:
>
>>
>> I'm happy with either "string interpolation" or "template".  I can't
>> find "template" in FutureReservedWord, but I thought it was in there.
>> If so it would be odd to have a language feature named "template" but
>> not have any relation to the future reserved word.
>>
>
> There are a lot of concepts in JS that don't have corresponding reserved words.  Object is one that comes immediately to mind. Quasi also isn't a reserved word, but so what.

I wasn't suggesting that it should have a corresponding reserved word,
just that any correspondence in name only might be confusing.

> I also suspect that "string interpolation" would also be scary to significant subset of JS programmers.

Isn't there a significant overlap between Javascript users and (Perl |
PHP | ruby) users?  Each of those languages has string interpolation.

PHP calls them "parsed strings":
http://www.php.net/manual/en/language.types.string.php#language.types.string.parsing
Perl calls it "interpolation":
http://perldoc.perl.org/perlop.html#Quote-and-Quote-like-Operators
Ruby calls it  "interpolation":
http://en.wikibooks.org/wiki/Ruby_Programming/Syntax/Literals#Interpolation

Received on Thursday, 20 October 2011 09:05:00 UTC