rusticata / pcap-parser

PCAP/PCAPNG file format parser written in pure Rust. Fast, zero-copy, safe.
Other
103 stars 24 forks source link

Upgrade to nom 5 #1

Closed WildCryptoFox closed 5 years ago

WildCryptoFox commented 5 years ago

Are there any immediate plans to migrate to nom 5? I've found rusticata's set of parsers to be useful examples for using nom. nom 5 moves from macros to function combinators - generally improving the readability and performance at both runtime and compile time.

chifflier commented 5 years ago

All the parsers will be updated to nom 5 I am doing other transitions first (new DER API, rewritten PCAP) first so they can be used in, for ex, Suricata (which has to be compatible with older Rust compilers, and so for now nom 5 cannot be used). After that, I'll start upgrading parsers to nom 5

chifflier commented 5 years ago

Upgrade to nom 5 was done in b25a12b (and released in crate version 0.7.0), so closing this issue

WildCryptoFox commented 5 years ago

That was a less exciting upgrade than expected. I was hoping you'd switch from the (now legacy, though not deprecated) macros to the function combinators. Oh well, what works, works.

chifflier commented 5 years ago

Heh, I did first the API change to bump dependencies (which resulted in a lot of changes in all my parsers). Using the function combinators is still planned, but can be done without breaking the crate API if I'm correct.

WildCryptoFox commented 5 years ago

@chifflier I believe you are correct. Good luck.