commit | 1a2e0664250eaea51d67a77e6cf7ed0c21b74d73 | [log] [tgz] |
---|---|---|
author | Joel Galenson <jgalenson@google.com> | Mon Nov 29 14:05:13 2021 -0800 |
committer | Joel Galenson <jgalenson@google.com> | Fri Dec 10 15:33:23 2021 -0800 |
tree | cfae57bccaa32b6ac56b3c6eec93404b973c5c10 | |
parent | 1a0cb4be2d41b27ab0f7dfff0a06887c33221beb [diff] |
Refresh Android.bp, cargo2android.json, TEST_MAPPING. Test: None Change-Id: Idf18a23945d4dd9a96bc14abb57f2ac4671e7ff5
Helper macros for the rusticata project.
This crate contains some additions to nom.
For example, the error_if!
macro allows to test a condition and return an error from the parser if the condition fails:
use rusticata_macros::error_if; let r : IResult<&[u8],()> = do_parse!( s, l: be_u8 >> error_if!(l < 4, ErrorKind::Verify) >> data: take!(l - 4) >> (()) );
See the documentation for more details and examples.
Different versions of this crate are available, depending on nom version.
rusticata-macros
4.x depends on nom 7rusticata-macros
3.x depends on nom 6rusticata-macros
2.x depends on nom 5Crate is documented, do running cargo doc
will crate the offline documentation.
Reference documentation can be found here
be_var_u64
and le_var_u64
Serialize
for structures serializationq
(quote) and align32
upgrade_error
and upgrade_error_to
custom_check
flat_take
newtype_enum
parse_uint24
as deprecatedLicensed under either of
at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.