r-lib / vctrs

Generic programming with typed R vectors
https://vctrs.r-lib.org
Other
289 stars 66 forks source link

Non-API calls #1933

Open lionel- opened 6 months ago

lionel- commented 6 months ago

Easy:

Unknown:

Problematic:

DavisVaughan commented 6 months ago

I think STDVEC_DATAPTR() can be replaced with DATAPTR() but I may be wrong

MichaelChirico commented 5 months ago

Commenting to follow here. @ben-schwen already linked our corresponding issue.

MichaelChirico commented 5 months ago

SET_S4_OBJECT()/UNSET_S4_OBJECT(): Used for proxying / unproxying S4 objects. Can we do better?

Looked at this a little bit. I think we can replace unset_s4() with asS3().

I gave up on r_mark_s4(), the goal would be to handle that with asS4() on the R side.

Alternatively, we might be able to use the C routine asS4() (untested, and not clear we're allowed to use it anyway)?

https://github.com/r-devel/r-svn/blob/main/src/main/objects.c#L1840

Jean-Romain commented 5 months ago

I think STDVEC_DATAPTR() can be replaced with DATAPTR() but I may be wrong

@DavisVaughan tested in my package. It passes all unit tests with no NOTE on devel