Skip to content

Conversation

urlyy
Copy link
Contributor

@urlyy urlyy commented Oct 13, 2025

What does this PR do?

  • simply refactor error.rs
  • replace panic/expect/unwrap with Result
  • replace assert with ensure
  • change Serialize api to return Result

Related issues

close #2706

Does this PR introduce any user-facing change?

  1. user should use unwrap/? when se/de.
  2. when they customize serializer, will return Result.
  • Does this PR introduce any public API change?
  • Does this PR introduce any binary protocol compatibility change?

@urlyy
Copy link
Contributor Author

urlyy commented Oct 13, 2025

There are still some unsafe code not return Result. Mainly about SIMD. But this pr is enough to merge.

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 this pull request may close these issues.

[Rust] return Error instead of panic when deserialize/serialize failed

1 participant