Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upThe Refactor #46
Comments
ryankurte
added
enhancement
help wanted
labels
Mar 6, 2018
This comment has been minimized.
This comment has been minimized.
|
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. |
This comment has been minimized.
This comment has been minimized.
|
On thinking more it's probably simpler to interleave PRs without having a new branch, so I agree. |
ryankurte
referenced this issue
Mar 7, 2018
Closed
Added Encode/Decode traits (and new_element helper) #48
This comment has been minimized.
This comment has been minimized.
|
Work on this is now done on https://github.com/japaric/svd/tree/refactor |
Emilgardis
referenced this issue
Mar 18, 2018
Merged
Add a function to produce merged peripheral when derivedFrom is used. #49
This was referenced Mar 20, 2018
This comment has been minimized.
This comment has been minimized.
musitdev
commented
Mar 27, 2018
|
I can help to do the refactor when error and Encode/Decode task is done. |
This comment has been minimized.
This comment has been minimized.
|
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 |
This comment has been minimized.
This comment has been minimized.
|
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. |
This comment has been minimized.
This comment has been minimized.
|
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 |
ryankurte
self-assigned this
Aug 21, 2018
This comment has been minimized.
This comment has been minimized.
|
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 |
This comment has been minimized.
This comment has been minimized.
|
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. |
This comment has been minimized.
This comment has been minimized.
|
#53 is merged |
ryankurte commentedMar 6, 2018
•
edited
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
Errortypes for svd decoding (@Emilgardis?)EncodeandDecodetraits 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.rstosrv/svd/object.rsand addpub mod object;tosrc/svd/mod.rsDecodetrait (and add error handling)Encodetrait (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 arefactorbranch until we reach stability again, then merge back to master in what is bound to be a spectacularly breaking change.