Read/write JSON to/from TObject

Thanks @linev. (I incorrectly thought I could import any arbitrary JSON and it would get populated into a blank TObject, but this is wrong, my bad).

BTW when using nlohmann::json, I get this error on Windows with VS 2022 + root_v6.32.12:

In file included from libtest dictionary payload:5:
In file included from E:/projects/src\Instrument.h:4:
In file included from C:/Program Files/root_v6.32.12\include\nlohmann/json.hpp:2440:
In file included from C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.43.34808\include\cassert:9:
In file included from C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\ucrt\assert.h:12:
C:\Program Files (x86)\Windows Kits\10\Include\10.0.19041.0\ucrt\corecrt.h:205:12: error: redefinition of '_CrtEnableIf<true, _Ty>'
    struct _CrtEnableIf<true, _Ty>
           ^~~~~~~~~~~~~~~~~~~~~~~

and lots of

==========================================
=============== STACKTRACE ===============
==========================================


================ Thread 0 ================
  libCore!TWinNTSystem::DispatchSignals()
  ucrtbase!seh_filter_exe()
  test!??
  VCRUNTIME140!_C_specific_handler()
  ntdll!_chkstk()
  ntdll!RtlRaiseException()

I found a temporary fix by editing nlohmann json.hpp around line 2440 into:

// allow overriding assert
#if !defined(JSON_ASSERT)
    //#include <cassert> // assert
    //#define JSON_ASSERT(x) assert(x)
    #define JSON_ASSERT(x)
#endif

Is there another way than this temporary fix?

Thank you again!