Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

copy complex numbers/vectors/matrices from R to C++ and viceversa #427

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

pachadotdev
Copy link
Contributor

@pachadotdev pachadotdev commented Dec 20, 2024

Hi @DavisVaughan

I hope you are doing well.

Happy holidays !

Here is a PR to copy complex numbers from R to C++ and viceversa.

I added multiple tests for complex numbers that pass.

> test()
ℹ Testing cpp11test
✔ | F W  S  OK | Context
✔ |         16 | formatted_errors                                                                                                                                           
✔ |         14 | complex                                                                                                                                                    
⠏ |          0 | cpp                                                                                                                                                        Warning: stack imbalance in 'withVisible', 68 then 64
✔ |        142 | as_cpp-C++                                                                                                                                                 
✔ |        123 | complexes-C++                                                                                                                                              
✔ |         28 | data_frame-C++                                                                                                                                             
✔ |        145 | doubles-C++                                                                                                                                                
✔ |         12 | environment-C++                                                                                                                                            
✔ |          5 | external_pointer-C++                                                                                                                                       
✔ |          6 | function-C++                                                                                                                                               
✔ |         77 | integers-C++                                                                                                                                               
✔ |         52 | list-C++                                                                                                                                                   
✔ |         12 | list_of-C++                                                                                                                                                
✔ |         64 | logicals-C++                                                                                                                                               
✔ |         72 | matrix-C++                                                                                                                                                 
✔ |          4 | nas-C++                                                                                                                                                    
✔ |          2 | unwind_protect-nested-C++                                                                                                                                  
✔ |          9 | unwind_protect-C++                                                                                                                                         
✔ |         25 | r_complex-C++                                                                                                                                              
✔ |         36 | r_vector-capabilities-C++                                                                                                                                  
✔ |         90 | r_vector-C++                                                                                                                                               
✔ |         49 | raws-C++                                                                                                                                                   
✔ |          4 | sexp-C++                                                                                                                                                   
✔ |          2 | string-C++                                                                                                                                                 
✔ |         78 | strings-C++                                                                                                                                                
✔ |          9 | doubles                                                                                                                                                    
✔ |          6 | matrix                                                                                                                                                     

══ Results ═════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════════
[ FAIL 0 | WARN 0 | SKIP 0 | PASS 1082 ]

Perhaps @krlmlr and @Antonov548 find this interesting :)

@pachadotdev pachadotdev marked this pull request as draft December 20, 2024 07:52
@pachadotdev pachadotdev marked this pull request as ready for review December 26, 2024 22:11
@pachadotdev pachadotdev changed the title copy complex numbers from R to C++ and viceversa copy complex numbers/vectors/matrices from R to C++ and viceversa Dec 27, 2024
@pachadotdev
Copy link
Contributor Author

it would be good to merge this PR and then adapt the tests here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant