From rossini@u.washington.edu  Fri Nov  8 17:55:34 2002
From: rossini@u.washington.edu (A.J. Rossini)
Date: 08 Nov 2002 09:55:34 -0800
Subject: behavior of =
In-Reply-To: <mirnsugtr7aefod5qfnuuurga6chh1hqtp@4ax.com>
References: <MABBLJDICACNFOLGIHJOOEKIDAAA.phgrosje@ulb.ac.be>
 <Pine.A41.4.44.0211080813030.108822-100000@homer40.u.washington.edu>
 <mirnsugtr7aefod5qfnuuurga6chh1hqtp@4ax.com>
Message-ID: <87hees7xpl.fsf@jeeves.blindglobe.net>

>>>>> "duncan" == Duncan Murdoch <dmurdoch@pair.com> writes:

    duncan> On Fri, 8 Nov 2002 08:17:12 -0800 (PST), you wrote:
    >> On Fri, 8 Nov 2002, Philippe Grosjean wrote:

    >>> foo(a=b)  # Assignment of b to a, and a is passed as first argument to
    >>> function foo()
    >>> foo(a:=b) # b is passed to the named argument 'a' of function foo()
    >>> 
    >> 
    >> Not only would this require rewriting essentially every piece of R code
    >> ever written, but even worse, := is used in other languages (and in the
    >> prehistory of R) as an assignment operator so it would be even less clear
    >> than the current situation.

    duncan> I would say a better change (but not good enough to be worth doing,
    duncan> because it would break so much) would be to drop "=" as an assignment
    duncan> operator, and use ":=" for that purpose.

Why not "<-"  instead of ":="?  I still don't understand why this is
in anyway better (except for pascal and modula programmers, see
Thomas' point from a while back: "If you want those constructs, use
those languages", is application.

best,
-tony

-- 
A.J. Rossini				Rsrch. Asst. Prof. of Biostatistics
U. of Washington Biostatistics		rossini@u.washington.edu	
FHCRC/SCHARP/HIV Vaccine Trials Net	rossini@scharp.org
-------------- http://software.biostat.washington.edu/ ----------------
FHCRC: M: 206-667-7025 (fax=4812)|Voicemail is pretty sketchy/use Email
UW:   Th: 206-543-1044 (fax=3286)|Change last 4 digits of phone to FAX
(my tuesday/wednesday/friday locations are completely unpredictable.)



-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


behavior of =
A.J. Rossini