Suharto Anggono Suharto Anggono
2017-Feb-27 15:23 UTC
[Rd] rep/rep.int: in NEWS, but not yet ported from trunk
For R 3.3.3, if 3.3.3 is really the last in 3.3.x series, I suggest reverting to R 3.3.2 code (and removing the corresponding NEWS entry), if possible. Failure of something like rep(5, list(6)) makes some previously working R code broken in some situation. It is not good to have in an R release that will last long, I think. -------------------------------------------- On Mon, 27/2/17, Martin Maechler <maechler at stat.math.ethz.ch> wrote: Subject: Re: [Rd] rep/rep.int: in NEWS, but not yet ported from trunk Cc: R-devel at r-project.org Date: Monday, 27 February, 2017, 4:20 PM>>>>> Suharto Anggono Suharto Anggono via R-devel <r-devel at r-project.org> >>>>> on Sun, 26 Feb 2017 12:02:44 +0000 writes:> According to "CHANGES IN R 3.3.2 patched" in NEWS, rep(x, > times) and rep.int(x, times) also work when 'times' has > length greater than one and has element larger than the > maximal integer. In fact, it is still not the case in R > 3.3.3 beta r72259. In seq.c > (https://svn.r-project.org/R/branches/R-3-3-branch/src/main/seq.c), > 'times' that is a vector with storage mode "double" and > length greater than one is still changed first to storage > mode "integer". Number in 'times' that represents an > integer that is larger than the maximal integer becomes NA > and error is issued for such 'times'. > I have put a comment, > https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=16932#c30 > . [[elided Yahoo spam]] - I've changed the NEWS entry for R-patched (and moved the more general statement to a new entry for R-devel). - The changes were quite substantial so I did not port them to R-patched at the time.. We could have ported them later, but not now, immediately before code freeze (of R 3.3.3). - I would say rep(5, list(6)) was never "meant to" work and had worked incidentally only. OTOH, you are correct with your comments 11 & 29 in the about bug report, and your proposal to make the simple case rep(s, list(7)) work as previously seems ok to me. However, for all this, we will concentrate on R-devel (to become R 3.4.0). Best regards, Martin Maechler