MCPcopy Create free account
hub / github.com/danielaparker/jsoncons / int128_example

Function int128_example

examples/src/json_traits_integer_examples.cpp:22–32  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20
21#if (defined(__GNUC__) || defined(__clang__)) && defined(JSONCONS_HAS_INT128)
22 void int128_example()
23 {
24 json j1("-18446744073709551617", semantic_tag::bigint);
25 std::cout << j1 << "\n\n";
26
27 __int128 val = j1.as<__int128>();
28
29 json j2(val);
30
31 assert(j2 == j1);
32 }
33#endif
34
35int main()

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected