[Rd] [Bug Fix] Default values not applied to ... arguments

Sahil Kang sahil.kang at asilaycomputing.com
Thu Jul 6 16:40:23 CEST 2017


Hi Duncan, Martin

Here's a small patch that fixes bug 15199 reported at:
https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15199

I was able to reproduce the bug as Duncan had outlined just fine, but I 
did notice that when we debug(f), the problem went away.
I later realized that f(1,,3) behaved correctly the first time it was 
executed, but misbehaved as documented on subsequent calls.
This narrowed the problem down to the byte-compilation that occurs on 
subsequent function calls.

This patch prevents byte-compilation on closure objects.
Although it's a less than ideal solution, this patch fixes the bug at 
least until the underlying byte-compilation issue can be found (I'm 
currently scrutinizing the promiseArgs function at eval.c:2771).

Thanks,
Sahil
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-patch
Size: 531 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-devel/attachments/20170706/9c1a55db/attachment.bin>


More information about the R-devel mailing list