Skip to content
Prev 57038 / 63424 Next

[External] Re: R C API resize matrix

On Mon, 17 Jun 2019, Simon Urbanek wrote:

            
Don't do that. SET_LENGTH isn't part of the API and using it outside
specific internal code confuses the garbage collector.

There is support for a growable vector but it's not a at a point where
the interface is stable enough to be used in packages. So again please
don't go there.

Also for a matrix unless you are just dropping trailing columns you
would have to move data in memory.

Best,

luke