-
Notifications
You must be signed in to change notification settings - Fork 18
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
Rewrite for 1.0 #39
Comments
91e98a9 is the first stable large reorganization matching all the above criteria. A few modules have been dropped for now (unfortunately including the some macro support). Slowly working on reintroducing these. the program and wrap_fn/invert_fn macros really need to be rewritten as procedural macros now to properly deal with generics and the stronger type constraints introduced by no longer using the dyn keyword. |
After some thought it seems the I am slowly learning how to write procedural macros to add these back in, since they are a cornerstone of QOL for this project. |
1ab3a11 is the bulk of the program! rewrite, it is now a procedural macro living in a package adjacent to the core qip code. It can be enabled via the "macros" feature. Some of the previously supported modules are gated by this now since they make heavy use of program! The syntax changed a bit (mostly just additional semicolons and now longer requiring vertical bars where we would have preferred parens or square brackets), I'll update docs soon. |
Much of this library isn't idiomatic rust - nor is it really well written to be honest with myself.
The numerics under the hood are fine and fairly well optimized, the issue is that the UnitaryBuilder trait and pipeline constructor heavily uses dynamic dispatch. Switching over to generics and traits would allow for much more flexibility from a type system perspective.
This would require a large reorganization, and much of the responsibility of the classes would need to be moved around.
The text was updated successfully, but these errors were encountered: