Skip to content

Conversation

@jdhoffa
Copy link
Member

@jdhoffa jdhoffa commented Jan 10, 2025

In this PR, I update sum_with_threads to handle type-casting already in the R session. That way, we can already ensure that Rust only has to deal with Real numbers, simplifying the complexity of the program. This also allows us to leverage the friendly error messages from R.

As explained in #31, this seems to be more idiomatic of the savvy package.

📦 gains a dependency on the vctrs package
⚠️ while I was there, I also removed add.R (I think this was an artifact of the "first commit")

Maybe supersedes #30
Closes #31

@jdhoffa jdhoffa requested a review from jibarozzo January 10, 2025 15:04
@jdhoffa
Copy link
Member Author

jdhoffa commented Jan 10, 2025

FYI @asbates , as it relates to #30

@jdhoffa jdhoffa changed the title 🏗️ handle types in r 🏗️ handle types in R; expect only RealSexp in Rust Jan 10, 2025
@asbates
Copy link

asbates commented Jan 10, 2025

FYI @asbates , as it relates to #30

Thanks! I closed #30

@jdhoffa jdhoffa requested a review from asbates January 11, 2025 09:28
Copy link
Contributor

@jibarozzo jibarozzo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like a simple and great approach.

@jdhoffa jdhoffa merged commit 470b002 into main Jan 11, 2025
14 checks passed
@jdhoffa jdhoffa deleted the 31-handle_types_in_r branch January 11, 2025 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

🏗️ handle types in R; expect only RealSexp in Rust

4 participants