extendr / extendr/extendr

Document i32 and f64 as copied values from R

Open
#901 0 comments 0 reactions 0 assignees View on GitHub
question
Dominant language
Rust
Stars
528
Forks
58
PR merge metrics
No merged PRs in 30d

Description

Hi, actually when we use a function like:

```R
rust_function("fn add(a:f64, b:f64) -> f64 { a + b }")
```

The values ```a``` and ```b``` are copied, but if we interpret it from Rust, we would think the library moved the values from R to Rust, so they should not be available now.

An option would be document this behavior, other one, which I think is a lot more clear is use ```&i32``` and ```&f64```.

Thx!

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.