commit | 57dd65382caf1a46525460d9de34952f2a01fcea | [log] [tgz] |
---|---|---|
author | Henri Chataing <[email protected]> | Wed Jun 21 18:37:02 2023 +0000 |
committer | Automerger Merge Worker <[email protected]> | Wed Jun 21 18:37:02 2023 +0000 |
tree | 2df2fcbccd2392d4681c8ae8ff7004a2583a8bd3 | |
parent | 66f5c04520cfe40b08a5ca777ae780de7239cc11 [diff] | |
parent | e6036688e26d7c89885bb51e23d3f03495125bff [diff] |
Update pdl-compiler to 0.1.2 am: e6036688e2 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/pdl-compiler/+/2630734 Change-Id: I68d94cb0df428aefed452c571638866634e8304f Signed-off-by: Automerger Merge Worker <[email protected]>
PDL is a domain specific language for writing the definition of binary protocol packets. Parsing and validating packets from raw bytes is tedious and error prone in any language. PDL generates memory safe and tailored backends for multiple target languages:
- Rust - C++ - Python
Historically PDL was developed as part of the Android Bluetooth stack (bluetooth_packetgen) as a way to generate the parser and serializer for Bluetooth packets, and reduce the number of memory safety issues that come with manipulating and validating raw data.
cargo run my-protocol.pdl --output-format rust > my-protocol.rs
Language specific instructions are provided for all supported backends: