2021-05-22 16:53:47 +03:00
|
|
|
//! Fuzzing for from-scratch parsing.
|
2019-09-30 11:58:53 +03:00
|
|
|
|
2018-09-08 16:55:53 +02:00
|
|
|
#![no_main]
|
2019-03-22 02:05:12 +09:00
|
|
|
use libfuzzer_sys::fuzz_target;
|
2020-08-12 18:26:51 +02:00
|
|
|
use syntax::fuzz::check_parser;
|
2018-09-08 16:55:53 +02:00
|
|
|
|
|
|
|
fuzz_target!(|data: &[u8]| {
|
|
|
|
if let Ok(text) = std::str::from_utf8(data) {
|
2019-03-22 02:05:12 +09:00
|
|
|
check_parser(text)
|
2018-09-08 16:55:53 +02:00
|
|
|
}
|
|
|
|
});
|