mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 22:02:23 +01:00
Currently ParseAndExecute-style logic is done in main.cpp and a test. #2799 is adding another test that needs it, as is #2811. Also more clearly marks fuzzing as testing. This is being extracted out of #2799 in order to try unblocking progress while review continues.
15 lines
499 B
C++
15 lines
499 B
C++
// Part of the Carbon Language project, under the Apache License v2.0 with LLVM
|
|
// Exceptions. See /LICENSE for license information.
|
|
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
|
|
|
|
#include <libfuzzer/libfuzzer_macro.h>
|
|
|
|
#include "common/error.h"
|
|
#include "explorer/fuzzing/fuzzer_util.h"
|
|
#include "llvm/Support/raw_ostream.h"
|
|
|
|
DEFINE_TEXT_PROTO_FUZZER(const Carbon::Fuzzing::Carbon& input) {
|
|
// Only verifying it doesn't crash.
|
|
(void)Carbon::Testing::ParseAndExecuteProto(input);
|
|
}
|