Be clearer about when jsonapi's need_escapes is needed
authorAndrew Dunstan <andrew@dunslane.net>
Sun, 19 Jan 2025 14:09:58 +0000 (09:09 -0500)
committerAndrew Dunstan <andrew@dunslane.net>
Sun, 19 Jan 2025 14:09:58 +0000 (09:09 -0500)
commitea5ff5833c7d4ae727a5acfc590c848b520775d0
tree8c08c15dfcccd02c2286bb9f5dd951783c96e2ab
parentd3d0983169130a9b81e3fe48d5c2ca4931480956
Be clearer about when jsonapi's need_escapes is needed

Most operations beyond pure json parsing need to set need_escapes to
true to get access to field names and string scalars. Document this
fact more explicitly.

Slightly tweaked patch from:

Author: Corey Huinker <corey.huinker@gmail.com>

Discussion: https://postgr.es/m/CADkLM=c49Vkfg2+A8ubSuEtaGEjuaKZXCA6SrXA8kdwHjx3uxQ@mail.gmail.com
src/common/jsonapi.c
src/include/common/jsonapi.h