libfuzzer
libfuzzer copied to clipboard
Add multiple variables implementing the `Arbitrary` type to `fuzz_target!`
A possible upgrade would be the ability for creating multiple variables that are to be fuzzed from the same data in the fuzz_target macro.
Something like this?
fuzz_target!(|rgb: Rgb, other: Other| {})
That, or have another macro named fuzz_targets
As a short term fix you can wrap both variables in a tuple
Relevant: https://github.com/rust-fuzz/cargo-fuzz/issues/252
fuzz_target!(|(rgb, other): (Rgb, Other)| {})
Unexpectely the above syntax also doesn't work.
I used this to work around the issue:
fuzz_target!(|data: (Rgb, Other)| {
let (rbg, other) = data;
})