Re: [Rd] special latin1 do not print as glyphs in current devel on windows

2017-11-12 Thread Patrick Perry
Just following up on this since the associated bug report just got closed (https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17329 ) because my original bug report was incomplete, and did not include sessionInfo() or LC_CTYPE. Admittedly, my original bug report was a little confused. I have s

Re: [Rd] Array changing address unexpectedly

2017-11-12 Thread luke-tierney
A simpler version with annotation: library(pryr) data <- 1:5 # new allocation, referenced from one variable add <- address(data) data[1] <- 6L# only one reference; don't need to duplicate add == address(data) # TRUE print(data) # inside the print call the local vari

Re: [Rd] Array changing address unexpectedly

2017-11-12 Thread lille stor
Hi David,   Thanks for the correction concerning the "else" issue.   Taking your code and removing some lines (to increase readability):   library(pryr)   data <- array(dim = c(5)) for(x in 1:5) {    data[x] <- as.integer(x * 2) }   #print(data)   add = address(data) for(x in 1:5) {    data[x] <-

Re: [Rd] Array changing address unexpectedly

2017-11-12 Thread David Winsemius
> On Nov 12, 2017, at 8:47 AM, lille stor wrote: > > Hi, > > Given the following R code: > > library(pryr) > > data <- array(dim = c(5)) > > for(x in 1:5) > { > data[x] <- as.integer(x * 2) > } > > add = address(data) # save address of "data" > > for(x

[Rd] Array changing address unexpectedly

2017-11-12 Thread lille stor
Hi, Given the following R code: library(pryr) data <- array(dim = c(5)) for(x in 1:5) { data[x] <- as.integer(x * 2) } add = address(data) # save address of "data" for(x in 1:5) { data[x] <- as.integer(0) } if (add == addr