| 5 | namespace ftg { |
| 6 | |
| 7 | std::string CorpusGenerator::generate(const Fuzzer &F) const { |
| 8 | std::string Result; |
| 9 | for (const auto &[ID, Input] : F.getFuzzInputMap()) { |
| 10 | assert(Input && "Unexpected Program State"); |
| 11 | if (Input->getCopyFrom()) |
| 12 | continue; |
| 13 | |
| 14 | const auto &Def = Input->getDef(); |
| 15 | if (Def.ArrayLen) |
| 16 | continue; |
| 17 | |
| 18 | auto CorpusValue = generate(Def); |
| 19 | if (CorpusValue.empty()) |
| 20 | continue; |
| 21 | |
| 22 | Result += CorpusValue + "\n"; |
| 23 | } |
| 24 | return Result; |
| 25 | } |
| 26 | |
| 27 | std::string CorpusGenerator::generate(const Definition &Def) const { |
| 28 |
nothing calls this directly
no test coverage detected