Migrate to cargo_embargo. am: 7994f86262 am: 6f102d68a9 am: 448ecb7a6d

Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/protobuf/+/2856056

Change-Id: I147c65af709a8dbe2af0b8771237ec3512e09dc3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
tree: 5b8f6d934520f205ebf8aa8afe699e30fa8b4b1c
  1. 2.27.1/
  2. benches/
  3. out/
  4. patches/
  5. src/
  6. .cargo_vcs_info.json
  7. Android.bp
  8. build.rs
  9. Cargo.toml
  10. Cargo.toml.orig
  11. cargo2rulesmk.json
  12. cargo_1.out
  13. cargo_embargo.json
  14. LICENSE.txt
  15. METADATA
  16. MODULE_LICENSE_MIT
  17. OWNERS
  18. README.md
  19. regenerate.sh
  20. rules.mk
  21. TEST_MAPPING
README.md

Library to read and write protocol buffers data

Features

This crate has one feature, which is with-bytes.

with-bytes enables protobuf crate support for bytes crate: when parsing bytes or strings from bytes::Bytes, protobuf will be able to reference the input instead of allocating subarrays.

Note, codegen also need to be instructed to generate Bytes or Chars for bytes or string protobuf types instead of default Vec<u8> or String, just enabling option on this crate is not enough.

See Customize struct in protobuf-codegen crate.

Accompanying crates