Oh, forgot to mention. Using Rf_eval on a promise a second time does not re-evaluate the promise. It simply returns the already calculated promise value. So if that comes up, no need to worry about it.
On Mon, Aug 18, 2025, 14:26 Josiah Parry <josiah.pa...@gmail.com> wrote: > *Question:* what is the best way to access a DOTSXP from R's C API in a > function call. > > Over at extendr (1) we'd like to be able to utilize `...` from the body of > a Rust function—with initial motivation being to support S3 generics like > print(x, ...). > > I don't see any recommendations / or mention of accessing DOTSXP in WRE. > The closest I can find is from R internals (2) repo which says > > "Easiest to get to with findVar(R_DotsSymbol, env) or similar." > > > From R's C API would this mean we would want to use something like: > > findVar(R_DotsSymbol, R_GetCurrentEnv()) to get the dots pairlist from the > function's environment? > > > 1) https://extendr.rs > 2) > > https://github.com/hadley/r-internals/blob/16c1d73b635ccecec8b1f396a8935a8dd96126e4/pairlists.md > > [[alternative HTML version deleted]] > > ______________________________________________ > R-package-devel@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-package-devel > [[alternative HTML version deleted]] ______________________________________________ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel