Skip to content
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

use scale Encoder in trie code #2755

Closed
qdm12 opened this issue Aug 16, 2022 · 0 comments · Fixed by #2930
Closed

use scale Encoder in trie code #2755

qdm12 opened this issue Aug 16, 2022 · 0 comments · Fixed by #2930

Comments

@qdm12
Copy link
Contributor

qdm12 commented Aug 16, 2022

Trie code uses scale.Marshal in a few places and then copies the resulting scale encoded byte slice to another io.Writer (usually a bytes buffer). We could save those copying operations by using the scale Encoder (merged in #2741) so write directly to the target io.Writer.

That would also make the trie code more 'stream oriented'.

@danforbes danforbes changed the title Enhancement: use scale Encoder in trie code use scale Encoder in trie code Aug 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants