Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Lifetimes are anon #8

Closed
gilescope opened this issue Nov 8, 2022 · 1 comment · Fixed by #11
Closed

Lifetimes are anon #8

gilescope opened this issue Nov 8, 2022 · 1 comment · Fixed by #11

Comments

@gilescope
Copy link
Contributor

gilescope commented Nov 8, 2022

The liftimes to the str and the &[u8;32] are all anon. If they were 'scale (i.e. linked back to the original scale &'scale [u8] slice) then people could use the visitor to do zero copy decodes.

pub fn as_str(&self) -> Result<&'a str, DecodeError> {

fn visit_i256(self, value: &[u8; 32], type_id: TypeId) -> Result<Self::Value, Self::Error>;

@jsdw
Copy link
Collaborator

jsdw commented Feb 2, 2023

This will be closed by #11, which uses a touch og GATs to allow zero copy decoding.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants