File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3232 - name : Ensure docs is OK
3333 run : v check-md ~/.vmodules/msgpack/README.md
3434
35- - name : Run example with -Wimpure-v
35+ - name : Ensure all examples compile with -W
36+ run : v -W should-compile-all ~/.vmodules/msgpack/examples/
37+
38+ - name : Run basic example with -Wimpure-v
3639 run : v -Wimpure-v crun ~/.vmodules/msgpack/examples/basic.v
3740
41+ - name : Run bench example
42+ run : v run ~/.vmodules/msgpack/examples/bench_msgpack_json_vs_json2.v
43+
3844 - name : Run example with -prod -cstrict -Wimpure-v -cc clang
3945 run : |
4046 cd ~/.vmodules/msgpack
Original file line number Diff line number Diff line change @@ -58,4 +58,13 @@ fn main() {
5858 }
5959 }
6060 b.measure ('msgpack.encode' )
61+
62+ encoded := msgpack.encode[Person](p)
63+ dump (encoded#[0 ..10 ])
64+ mut decoder := msgpack.new_decoder ()
65+ for _ in 0 .. max_iterations {
66+ // TODO: investigate why decoder.decode does not return a result at all :-|
67+ decoder.decode (encoded)!
68+ }
69+ b.measure ('msgpack.decode' )
6170}
You can’t perform that action at this time.
0 commit comments