From pdalgd at gmail.com  Mon Feb 18 17:35:21 2013
From: pdalgd at gmail.com (peter dalgaard)
Date: Mon, 18 Feb 2013 17:35:21 +0100
Subject: [Rd] quote() vs quote(expr=)
In-Reply-To: <CABdHhvHQ8uEqZ7AEhhY131=BRaUXByspdoQuc2+c3=gcBfPARw@mail.gmail.com>
References: <CABdHhvGwS1xuOqYLqtJAGjJrm5gGvLW7XJs+4bg3LY_R3Z7oNQ@mail.gmail.com>
	<01CE77E8-6F40-4050-A365-A21DFF933585@gmail.com>
	<CABdHhvHQ8uEqZ7AEhhY131=BRaUXByspdoQuc2+c3=gcBfPARw@mail.gmail.com>
Message-ID: <6860B4BC-FCA9-4A93-8817-8BB99AEA1A0D@gmail.com>


On Feb 18, 2013, at 17:04 , Hadley Wickham wrote:

> quote(expr =) returning missing seems like the right thing to me,
> quote() throwing an error does not, because it violates the usual
> semantics where f(x = ) is equivalent to f().

Except that it isn't:

> (function(...)nargs())()
[1] 0
> (function(...)nargs())(x=)
[1] 1


-- 
Peter Dalgaard, Professor
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: pd.mes at cbs.dk  Priv: PDalgd at gmail.com



[Rd] quote() vs quote(expr=)
peter dalgaard