Functions are fine, don’t move to struct impls unless it makes sense (but do if the functions all take the same struct as a param).
You can go pretty far with modules and functions. Group related functions and move them to new modules. You can also hide functions that are only used inside one of the submodules by just not marking them as pub
.
One thing that comes to mind is that if the steps of your algorithm all take and return the same data, you can have a trait that expresses that (possibly one of the Fn
traits if you’re going to just use functions), and you can define and rest each step separately.
It’s hard to give more concrete advice without knowing more about your project
It’s tough to debug issues when you can’t run on the same hardware directly.
There’s a reason that arm support in open source software has exploded in the past few years, and it’s because of apple silicon.
I’ll agree that it’s easier now, with most developers using higher level runtimes, but someone’s got to get those runtimes working, and it’s much easier to develop if you have a laptop running that hardware.