mirror of
https://github.com/google/benchmark.git
synced 2024-12-27 13:00:36 +08:00
Deprecate CSVReporter - A first step to overhauling reporting. (#488)
As @dominichamon and I have discussed, the current reporter interface is poor at best. And something should be done to fix it. I strongly suspect such a fix will require an entire reimagining of the API, and therefore breaking backwards compatibility fully. For that reason we should start deprecating and removing parts that we don't intend to replace. One of these parts, I argue, is the CSVReporter. I propose that the new reporter interface should choose a single output format (JSON) and traffic entirely in that. If somebody really wanted to replace the functionality of the CSVReporter they would do so as an external tool which transforms the JSON. For these reasons I propose deprecating the CSVReporter.
This commit is contained in:
parent
16703ff83c
commit
7b8d0249d8
@ -130,7 +130,6 @@ else()
|
|||||||
|
|
||||||
# Turn compiler warnings up to 11
|
# Turn compiler warnings up to 11
|
||||||
add_cxx_compiler_flag(-Wall)
|
add_cxx_compiler_flag(-Wall)
|
||||||
|
|
||||||
add_cxx_compiler_flag(-Wextra)
|
add_cxx_compiler_flag(-Wextra)
|
||||||
add_cxx_compiler_flag(-Wshadow)
|
add_cxx_compiler_flag(-Wshadow)
|
||||||
add_cxx_compiler_flag(-Werror RELEASE)
|
add_cxx_compiler_flag(-Werror RELEASE)
|
||||||
@ -141,6 +140,9 @@ else()
|
|||||||
add_cxx_compiler_flag(-Wshorten-64-to-32)
|
add_cxx_compiler_flag(-Wshorten-64-to-32)
|
||||||
add_cxx_compiler_flag(-Wfloat-equal)
|
add_cxx_compiler_flag(-Wfloat-equal)
|
||||||
add_cxx_compiler_flag(-fstrict-aliasing)
|
add_cxx_compiler_flag(-fstrict-aliasing)
|
||||||
|
# Disable warnings regarding deprecated parts of the library while building
|
||||||
|
# and testing those parts of the library.
|
||||||
|
add_cxx_compiler_flag(-Wno-deprecated-declarations)
|
||||||
if (NOT BENCHMARK_ENABLE_EXCEPTIONS)
|
if (NOT BENCHMARK_ENABLE_EXCEPTIONS)
|
||||||
add_cxx_compiler_flag(-fno-exceptions)
|
add_cxx_compiler_flag(-fno-exceptions)
|
||||||
endif()
|
endif()
|
||||||
|
@ -1414,7 +1414,8 @@ class JSONReporter : public BenchmarkReporter {
|
|||||||
bool first_report_;
|
bool first_report_;
|
||||||
};
|
};
|
||||||
|
|
||||||
class CSVReporter : public BenchmarkReporter {
|
class BENCHMARK_DEPRECATED_MSG("The CSV Reporter will be removed in a future release")
|
||||||
|
CSVReporter : public BenchmarkReporter {
|
||||||
public:
|
public:
|
||||||
CSVReporter() : printed_header_(false) {}
|
CSVReporter() : printed_header_(false) {}
|
||||||
virtual bool ReportContext(const Context& context);
|
virtual bool ReportContext(const Context& context);
|
||||||
|
Loading…
Reference in New Issue
Block a user