R-alpha: "..." arg.matching [was 'Problems with dimnames and names']

Ross Ihaka ihaka@stat.auckland.ac.nz
Sat, 29 Nov 1997 08:35:06 +1300 (NZDT)

> -- Now to the ``real'' one : --
>     Martyn> 3) I have no idea what's going on here.
>     >> c(r=1,s=2)
>     Martyn> s
>     Martyn> 2
>     >> c(u=100,b=4)
>     Martyn> b
>     Martyn> 4
>     Martyn> This seems to happen only for "r" and "u". Other single-letter
>     Martyn> names are OK. This doesn't happen on my home PC which is still
>     Martyn> running R-0.50-a1.
> Well, we (i.e., Peter and Martyn) have found *why* it happens.
> However, this is a semantic change from older versions of R and from S
> which I consider serious [a bug ?!?] an we should discuss.

This wasn't a deliberate change, just my usual incompetence.
I think it crept in when we changed c() to be a generic function
(which does method dispatch internally).

The problem is in the function "ExtractOptionals" in bind.c.  There the
matching of arguments is done in two places with pmatch using a third
argument which is 0.  This indicates partial matching and should be
changed so that the third argument is 1 indicating exact matching.

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