Optimize example/*json*'s indentation output

On a mid-range x86_64 laptop, processing the 181 MiB citylots.json file
from github.com/zemirco/sf-city-lots-json:

$ time gen/bin/example-jsonptr < citylots.json > /dev/null
Before this commit:
real    0m3.612s
After:
real    0m1.949s
Ratio: 1.85x
This commit is contained in:
Nigel Tao committed 2020-08-19 00:02:30 +10:00
1 parent 1864d9c01a
commit 0a0c7d68aa
3 files changed
+72 -41

No files matched your search

+4 -2
View File
@@ -193,9 +193,11 @@ struct {
int remaining_argc;
char** remaining_argv;
uint32_t max_output_depth;
char* query_c_string;
bool strict_json_pointer_syntax;
uint32_t max_output_depth;
char* query_c_string;
} g_flags = {0};
std::string //