-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Right now, JSON3.write stores
julia> JSON3.write(stdout, @be sleep(.01));
{"samples":[{"evals":1.0,"time":0.011088246000000001,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011092579,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011094829,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011086371000000001,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011106663000000001,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011090704,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011087704,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011086996,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011083413,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0},{"evals":1.0,"time":0.011085288,"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0}]}I'd prefer
julia> JSON3.write(stdout, @be sleep(.01));
{"evals":1.0,"time":[0.011088246000000001,0.011092579,0.011094829,0.011086371000000001,0.011106663000000001,0.011090704,0.011087704,0.011086996,0.011083413,0.011085288],"allocs":4.0,"bytes":112.0,"gc_fraction":0.0,"compile_fraction":0.0,"recompile_fraction":0.0,"warmup":1.0}
This would involve a StructTypes package extension
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request