Giter Club home page Giter Club logo

Comments (2)

dgkf avatar dgkf commented on July 17, 2024

Great question!

do I understand correctly that we want to implement paste() as a primitive (written in Rust?) function

Quick answer first - then more discussion:

Yep, that's what I was thinking. If your goal is to use this as an opportunity to implement some R concepts in rust, I would say go for it.


But this also brings up a good question about what our goals should be. My original goal was to use this little exercise to learn some rust and experiment with what I thought would be cool enhancements to R, but the project has gotten a bit of momentum now and if others want to see it as a practical replacement, we might need to go back to the drawing board in terms of how we approach the problem.

A more pragmatic approach would be to call into R's internal implementations to bootstrap a new implementation, allowing for a slow migration from C to rust. In this case, we can find R's paste code here. Probably this would involve first building a rust interface to the libR shared library.

Interfacing with R's internals would be a big shift in the project, though. It would mean that the rust representations of R objects need to be more direct analogs of the C implementations, or at least add a translation layer to and from rust representations.

from r.

armenic avatar armenic commented on July 17, 2024

Thanks Doug!

Since I want to learn Rust, I will go with pure Rust for now :) I can not believe that paste() is 757 lines of code in C, let's see if Rust can do it with a shorter logic.

I was thinking to grab the unit test from R source code and I could not find a test for paste(), my search.

from r.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.