libpromises/evalfunction.c: let mergedata() use VarRefValueToJson