[Rd] Change in print.function between R 3.4.1 and R 3.4.0
    nicola farina 
    farinan at gmail.com
       
    Thu Jul 20 16:51:54 CEST 2017
    
    
  
Dear all,
I just installed R 3.4.1 and noticed a change in how user-defined functions
are printed. A small example:
string<-"f<-function(x){\n\tx^2\n}"
cat(string,file="tmp00a.R")
source("tmp00a.R")
f
And this is what I see:
#R 3.4.0
function(x){
    x^2
}
#R 3.4.1
function(x){
\tx^2
}
Seems that in 3.4.1 the tab character isn't "rendered". This is rather
annoying since it becomes very difficult to inspect the source code of user
defined functions. This behaviour seems to be present just for the tab
character (\n and \r are displayed correctly).
I'm on Ubuntu 14, 64bit. If you need more details I will gladly provide
what I can. Here is my sessionInfo():
R version 3.4.1 (2017-06-30)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.5 LTS
Matrix products: default
BLAS: /usr/local/R-3.4.1/lib/libRblas.so
LAPACK: /usr/local/R-3.4.1/lib/libRlapack.so
locale:
 [1] LC_CTYPE=it_IT.UTF-8       LC_NUMERIC=C
 [3] LC_TIME=it_IT.UTF-8        LC_COLLATE=it_IT.UTF-8
 [5] LC_MONETARY=it_IT.UTF-8    LC_MESSAGES=it_IT.UTF-8
 [7] LC_PAPER=it_IT.UTF-8       LC_NAME=C
 [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=it_IT.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base
loaded via a namespace (and not attached):
[1] compiler_3.4.1 tools_3.4.1
(the value of sessionInfo() on R 3.4.0 is obviously identical aside from
the versions).
Thank you for your attention and your incredible work.
Nicola Farina
	[[alternative HTML version deleted]]
    
    
More information about the R-devel
mailing list