-
Notifications
You must be signed in to change notification settings - Fork 55
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
The Refactor #46
Comments
Looks good, I have some thoughts however. I also believe making the structure of the project Also, just to be clear, when you say SVD object, you mean the structs in I'll make a pr on my branch to help advance this, I do agree that this is what needs to happen. |
On thinking more it's probably simpler to interleave PRs without having a new branch, so I agree. |
Work on this is now done on https://github.com/japaric/svd/tree/refactor |
I can help to do the refactor when error and Encode/Decode task is done. |
Finished splitting the modules out into separate files and throwing the interfaces together. There's also the issue of some types returning arrays of objects, for which we could either introduce an Still need |
ping @ryankurte are you still working on this? I can probably pick this up again this weekend, I'm not 100% however on what exactly is left to do. |
I haven't had a chance recently, but still hoping to. Definitely not this weekend though. Outstanding as far as I can remember:
I just had a skim through and added |
I've done most of the refactoring bits, but a lot of encode work to do still. How would y'all feel about putting encode behind an |
I would be okay with that approach. Having the error handling and getting rust-embedded/svd2rust#193 implemented is something we've been waiting on for a while. |
#53 is merged 🎉 , closing issue. |
We have a few outstanding issues that to move forward with could use a refactor of the existing codebase.
Issues:
Proposal
Things to do and PRs to accept. I'll update this list from any discussion in this issue to reflect our plan and progress.
Project Level
Error
types for svd decoding (@Emilgardis?)Encode
andDecode
traits for svd objects (@ryankurte?)Once we've defined Error types and Encode/Decode traits the refactoring part should be reasonably simple,
and we can accept a PR for each to avoid nightmare refactoring.For each SVD object (ie. object implementing an SVD element)
src/lib.rs
tosrv/svd/object.rs
and addpub mod object;
tosrc/svd/mod.rs
Decode
trait (and add error handling)Encode
trait (svd#37 has many pre-written)I propose that we put a freeze on changes to master while undertaking this and make these changes against arefactor
branch until we reach stability again, then merge back to master in what is bound to be a spectacularly breaking change.The text was updated successfully, but these errors were encountered: