Closed rikhuijzer closed 9 months ago
Once this is done, it should make other things such as plotting and handling the browser DOM easier, so then it's a net win?
Exactly!
The code looks fine. But since we are rewriting this in Rust, could we add documentation to the new function and modules.
The code looks fine. But since we are rewriting this in Rust, could we add documentation to the new function and modules.
I did that apart from the module. With module, the call would become pnt::pnt::pnt
which is a bit too nested IMO
Yes, what you did with the //!
is what I've meant with module.
Thanks!
Works towards fixing #24.
This is a way in which we could get rid of C and, hence, emscripten. We just incrementally port the C code to Rust. It's a lot of work, but not super difficult. Once this is done, it should make other things such as plotting and handling the browser DOM easier, so then it's a net win?
The code tries to stay as close as possible to the original implementation. This should make it easier to find bugs in our port.
I've also tried
c2rust
. Apart from some warnings, it seemed to work after generatingcompile_commands.json
withintercept-build
. The generated code was not very pretty, however, and relied heavily on libc, so I think a manual rewrite is more future proof.