| 59 | } |
| 60 | |
| 61 | pub(crate) struct CorpusStore<D> { |
| 62 | test_cases: Vec<TestCase<D>>, |
| 63 | /// The number of testcases that we had the last time the corpus was saved. |
| 64 | last_save_cases: usize, |
| 65 | /// When we last saved the input corpus. Used to ensure that the input metadata is saved |
| 66 | /// occasionally even when no new inputs have been found. |
| 67 | last_save_time: Instant, |
| 68 | /// The IDs of inputs that have been replaced in the corpus since last save. |
| 69 | replaced: Vec<InputId>, |
| 70 | /// Keeps track of the inputs that hit each block, this is used for input prioritization. |
| 71 | coverage_hits: HashMap<u32, Vec<InputId>>, |
| 72 | /// Metadata collected about the corpus |
| 73 | pub metadata: CorpusMetadata, |
| 74 | /// The time the corpus was created at. |
| 75 | start_time: Instant, |
| 76 | } |
| 77 | |
| 78 | impl<D> Default for CorpusStore<D> { |
| 79 | fn default() -> Self { |
nothing calls this directly
no outgoing calls
no test coverage detected