[Rd] [External] Re: non-API SETLENGTH and friends will be dropped soon

iuke-tier@ey m@iii@g oii uiow@@edu iuke-tier@ey m@iii@g oii uiow@@edu
Fri Dec 5 21:27:25 CET 2025


Sounds good. Using xlengthgets is the way to go for your package, and
most others. I think I posted an outline on how I would do that a few
months ago. The resizable framework is mainly for data.table, who seem
convinced that they need it.

Best,

luke

On Thu, 4 Dec 2025, Merlise Clyde, Ph.D. wrote:

> Dear Luke,
> 
> I have implemented changes knowing this was around the corner to address
> this and hopefully can finalize unit tests/comparisons in the next week (I
> also want to take a look at the new resizable option to see how that
> compares to what I did), but it looks like CRAN will be down for submissions
> from Dec 23 through Jan 7.   Hoping the grace period takes into account this
> down time in case early submissions fail on some of the CRAN machines
> despite all efforts to test ahead of time.
> 
> Best,
> Merlise
> 
> From: luke-tierney using uiowa.edu <luke-tierney using uiowa.edu>
> Date: Wednesday, December 3, 2025 at 8:47 PM
> To: R-devel using r-project.org <R-devel using r-project.org>
> Subject: non-API SETLENGTH and friends will be dropped soon
> 
> As part of clarifying and tightening the R API for packages the
> non-API entry points SETLENGTH, TRUELENGTH, SET_TRUELENGTH, and
> SET_GROWABLE_BIT will be removed from installed header files and,
> where possible, hidden from package access. The first step will be to
> turn current check NOTEs into WARNINGs; this will hopefully happen in
> the next few weeks. Hopefully the process can be completed by early
> January.
> 
> 17 CRAN/BIOC packages currently make use of one or more of these entry
> points. Most using SETLENGTH should transition to using xgetlength(),
> which allocates a new vector, usually with a shorter length. There is
> a small amount of overhead, and care is needed to protect the new
> result, but this is a much safer option. R-devel does now include an
> experimental API for creating resizable vectors, but it needs a great
> deal of care to use safely. These options are described in a new
> section "Resizing vectors" in the Writing R Extensions manual.
> 
> [If you are a maintainer of one of the 17 affected packages you should
> receive a separate copy of this note.]
> 
> Best,
> 
> luke
> ~
> 
> --
> Luke Tierney
> Ralph E. Wareham Professor of Mathematical Sciences
> University of Iowa                  Phone:             319-335-3386
> Department of Statistics and        Fax:               319-335-3017
>     Actuarial Science
> 241 Schaeffer Hall                  email:   luke-tierney using uiowa.edu
> Iowa City, IA 52242                 WWW: http://www.stat.u/
> iowa.edu%2F&data=05%7C02%7Cclyde%40duke.edu%7Cba7580378f9541643d8308de32d7
> 0ce1%7Ccb72c54e4a314d9eb14a1ea36dfac94c%7C0%7C0%7C639004096389160865%7CUnk
> nown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4
> zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=ixyactGTcKZWRkHyy
> IAnIf0jV5u8OK2vPywlWRhNkfE%3D&reserved=0
> 
>

-- 
Luke Tierney
Ralph E. Wareham Professor of Mathematical Sciences
University of Iowa                  Phone:             319-335-3386
Department of Statistics and        Fax:               319-335-3017
    Actuarial Science
241 Schaeffer Hall                  email:   luke-tierney using uiowa.edu
Iowa City, IA 52242                 WWW:  http://www.stat.uiowa.edu/


More information about the R-devel mailing list