[Rd] Rscript -e does not accept newlines under Linux?
Voeten, C.C.
c@c@voeten @ending from hum@leidenuniv@nl
Sun Sep 16 10:53:03 CEST 2018
Hello,
I have found what I believe to be a bug in the Linux version of the Rscript binary.
Under Windows (official 64-bit 3.5.1 R distribution running on an up-to-date Win10), I can do the following (e.g. under powershell):
PS H:\Users\Cesko> Rscript -e 'ls()
>> ls()'
character(0)
character(0)
which works as I expect: I am running Rscript with two arguments, namely (1) '-e', and (2) two lines of code to be run, and it indeed executes those two lines of code.
This fails when attempted on a Linux build (amd64, compiled from the official 3.5.1 sources, but also reproducible with today's r-devel snapshot):
$ Rscript -e 'ls()
ls()'
ARGUMENT 'ls()' __ignored__
character(0)
This behavior is not what I expected. Have I found a bug, or am I simply using it wrong?
Regards,
Cesko
More information about the R-devel
mailing list