-
Notifications
You must be signed in to change notification settings - Fork 107
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
feat: add byte array type and string conversions #522
Conversation
I think I've JSON rpc related errors, if you have the opportunity to manually trigger the workflow it could be great @xJonathanLEI. Thanks a lot! |
I'm thinking that we should introduce a Bytes31 type to ensure that the EDIT: useless question sorry, will implement it in the PR. 👍 |
955820f
to
0ddf5f4
Compare
@xJonathanLEI here's the updated version of the PR. Few months of blank here, sorry for that. I've added the Happy to address any comment! |
@xJonathanLEI rebased on master, happy to dive in any update as necessary. |
Hey @glihm thanks for the PR. I see you're modelling the types here directly after their Cairo implementations, with the internals exposed. It kinda makes me wonder though: do we really expect users to care about what a particular array's I'm not exactly convinced that it's the case. The exact composition should only matter when crossing the Rust <-> Cairo boundary (i.e. encoding/decoding), which should be mostly opaque to users. Users most likely just want to deal with bytes. So IMO a better design would be a fully encapsulated Then we should have this type implement |
Superseded by #682. |
No way! I was just looking for a ByteArray implementation and turns out it was implemented 5 days ago! Man, we really are on the bleeding edge haha 😅. Thanks for the new feature guys! |
This PR aims at bringing support for ByteArray type.