Skip to content

Make DecodeRaw accept ReadOnlyMemory<byte> #63

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

Open
Crauzer opened this issue Jan 16, 2023 · 2 comments
Open

Make DecodeRaw accept ReadOnlyMemory<byte> #63

Crauzer opened this issue Jan 16, 2023 · 2 comments

Comments

@Crauzer
Copy link

Crauzer commented Jan 16, 2023

DecodeRaw is currently a wrapper for DecodeRawInternal which itself accepts ReadOnlyMemory<byte>.
There is no reason why the public function shouldn't also accept ReadOnlyMemory/ReadOnlySpan.

@Crauzer Crauzer changed the title Make DecodeRaw accept ReadOnlySpan<byte> Make DecodeRaw accept ReadOnlyMemory<byte> Jan 16, 2023
@Crauzer
Copy link
Author

Crauzer commented Jan 16, 2023

I think issue also applies to the whole library, it would be much better to use the Memory/Span types for public APIs

@Nominom
Copy link
Owner

Nominom commented May 4, 2025

Hi,

Apologies for the late answer, but thanks for the suggestion!

I am actually reworking the public API for the next major version, because I'm not entirely happy with the current iteration either. The new API will definitely include methods for simple memory or span inputs as well.

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

No branches or pull requests

2 participants