Compare with nlohmann/json
This commit is contained in:
@@ -36,6 +36,13 @@ FetchContent_Declare(
|
||||
)
|
||||
FetchContent_MakeAvailable(nanobench)
|
||||
|
||||
FetchContent_Declare(
|
||||
nlohmann_json
|
||||
GIT_REPOSITORY https://github.com/nlohmann/json.git
|
||||
GIT_TAG bc889afb4c5bf1c0d8ee29ef35eaaf4c8bef8a5d # v3.11.2
|
||||
)
|
||||
FetchContent_MakeAvailable(nlohmann_json)
|
||||
|
||||
include_directories(src)
|
||||
|
||||
find_package(weaseljson REQUIRED)
|
||||
@@ -65,7 +72,14 @@ add_executable(bench_commit_request benchmarks/bench_commit_request.cpp
|
||||
target_link_libraries(bench_commit_request nanobench weaseljson)
|
||||
target_include_directories(bench_commit_request PRIVATE src)
|
||||
|
||||
add_executable(bench_parser_comparison benchmarks/bench_parser_comparison.cpp
|
||||
src/commit_request.cpp)
|
||||
target_link_libraries(bench_parser_comparison nanobench weaseljson
|
||||
nlohmann_json::nlohmann_json)
|
||||
target_include_directories(bench_parser_comparison PRIVATE src)
|
||||
|
||||
add_test(NAME arena_allocator_tests COMMAND test_arena_allocator)
|
||||
add_test(NAME commit_request_tests COMMAND test_commit_request)
|
||||
add_test(NAME arena_allocator_benchmarks COMMAND bench_arena_allocator)
|
||||
add_test(NAME commit_request_benchmarks COMMAND bench_commit_request)
|
||||
add_test(NAME parser_comparison_benchmarks COMMAND bench_parser_comparison)
|
||||
|
||||
Reference in New Issue
Block a user