From hadley at rice.edu  Wed Jul  6 14:58:02 2011
From: hadley at rice.edu (Hadley Wickham)
Date: Wed, 6 Jul 2011 08:58:02 -0400
Subject: [Rd] Syntactically valid names
In-Reply-To: <99993C2E-69F9-4AD9-8484-38C1CF765944@gmail.com>
References: <BANLkTimg=TM0hYA1=Obknb+486Hv8T7Fdw@mail.gmail.com>
	<2698F67A-DDF9-4EAF-B7A8-A4FAAE9CCC6B@gmail.com>
	<CABdHhvHmRP6XOkTq+4Z1NjvW1SRwqt1AUwga_ovbMOfi3zi5oA@mail.gmail.com>
	<CAFFLneRp4YY7U+Nn26C+hFhX-4PWaHZMFizBmgEtNg2jjK93qg@mail.gmail.com>
	<CABdHhvEhKGZjSX_fRAAi6_PjHgnhOra_f7w8Y+R8Pw8gGm92OQ@mail.gmail.com>
	<A16B0AB7-C30E-482D-B91A-EC3CC2C70CB9@gmail.com>
	<CABdHhvGAP7+0FeDtyBiKFtdnP6+oAnYjkEUpBQVChY5toVqHCA@mail.gmail.com>
	<99993C2E-69F9-4AD9-8484-38C1CF765944@gmail.com>
Message-ID: <CABdHhvFVrGi4HORYSc=naX3cGjOWr7b3npYEJE75H-OcgX033A@mail.gmail.com>

> That's two different issues:
>
>> y <- list()
>> y$... <- 2
>> y$..2 <- 3
>> y$break <- 4
> Error: unexpected 'break' in "y$break"
>
> Notice that there is nothing _syntactically_ wrong with ... & friends as names:
>
>> quote(...<-4)
> ... <- 4
>
> It's the _evaluator_ that throws the error because the ...-name has a special interpretation.

Oh good point.  Thanks for the clarification.

Hadley


-- 
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/



[Rd] Syntactically valid names
Hadley Wickham