@@ -221,7 +221,7 @@ jsonPathToCstring(StringInfo out, JsonPath *in, int estimated_len)
221221enlargeStringInfo (out ,estimated_len );
222222
223223if (!(in -> header & JSONPATH_LAX ))
224- appendBinaryStringInfo (out ,"strict " , 7 );
224+ appendStringInfoString (out ,"strict " );
225225
226226jspInit (& v ,in );
227227printJsonPathItem (out ,& v , false, true);
@@ -542,9 +542,9 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
542542break ;
543543case jpiBool :
544544if (jspGetBool (v ))
545- appendBinaryStringInfo (buf ,"true" , 4 );
545+ appendStringInfoString (buf ,"true" );
546546else
547- appendBinaryStringInfo (buf ,"false" , 5 );
547+ appendStringInfoString (buf ,"false" );
548548break ;
549549case jpiAnd :
550550case jpiOr :
@@ -585,13 +585,13 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
585585operationPriority (elem .type ) <=
586586operationPriority (v -> type ));
587587
588- appendBinaryStringInfo (buf ," like_regex " , 12 );
588+ appendStringInfoString (buf ," like_regex " );
589589
590590escape_json (buf ,v -> content .like_regex .pattern );
591591
592592if (v -> content .like_regex .flags )
593593{
594- appendBinaryStringInfo (buf ," flag \"" , 7 );
594+ appendStringInfoString (buf ," flag \"" );
595595
596596if (v -> content .like_regex .flags & JSP_REGEX_ICASE )
597597appendStringInfoChar (buf ,'i' );
@@ -623,13 +623,13 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
623623appendStringInfoChar (buf ,')' );
624624break ;
625625case jpiFilter :
626- appendBinaryStringInfo (buf ,"?(" , 2 );
626+ appendStringInfoString (buf ,"?(" );
627627jspGetArg (v ,& elem );
628628printJsonPathItem (buf ,& elem , false, false);
629629appendStringInfoChar (buf ,')' );
630630break ;
631631case jpiNot :
632- appendBinaryStringInfo (buf ,"!(" , 2 );
632+ appendStringInfoString (buf ,"!(" );
633633jspGetArg (v ,& elem );
634634printJsonPathItem (buf ,& elem , false, false);
635635appendStringInfoChar (buf ,')' );
@@ -638,10 +638,10 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
638638appendStringInfoChar (buf ,'(' );
639639jspGetArg (v ,& elem );
640640printJsonPathItem (buf ,& elem , false, false);
641- appendBinaryStringInfo (buf ,") is unknown" , 12 );
641+ appendStringInfoString (buf ,") is unknown" );
642642break ;
643643case jpiExists :
644- appendBinaryStringInfo (buf ,"exists (" , 8 );
644+ appendStringInfoString (buf ,"exists (" );
645645jspGetArg (v ,& elem );
646646printJsonPathItem (buf ,& elem , false, false);
647647appendStringInfoChar (buf ,')' );
@@ -655,10 +655,10 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
655655appendStringInfoChar (buf ,'$' );
656656break ;
657657case jpiLast :
658- appendBinaryStringInfo (buf ,"last" , 4 );
658+ appendStringInfoString (buf ,"last" );
659659break ;
660660case jpiAnyArray :
661- appendBinaryStringInfo (buf ,"[*]" , 3 );
661+ appendStringInfoString (buf ,"[*]" );
662662break ;
663663case jpiAnyKey :
664664if (inKey )
@@ -680,7 +680,7 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
680680
681681if (range )
682682{
683- appendBinaryStringInfo (buf ," to " , 4 );
683+ appendStringInfoString (buf ," to " );
684684printJsonPathItem (buf ,& to , false, false);
685685}
686686}
@@ -692,7 +692,7 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
692692
693693if (v -> content .anybounds .first == 0 &&
694694v -> content .anybounds .last == PG_UINT32_MAX )
695- appendBinaryStringInfo (buf ,"**" , 2 );
695+ appendStringInfoString (buf ,"**" );
696696else if (v -> content .anybounds .first == v -> content .anybounds .last )
697697{
698698if (v -> content .anybounds .first == PG_UINT32_MAX )
@@ -713,25 +713,25 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
713713v -> content .anybounds .last );
714714break ;
715715case jpiType :
716- appendBinaryStringInfo (buf ,".type()" , 7 );
716+ appendStringInfoString (buf ,".type()" );
717717break ;
718718case jpiSize :
719- appendBinaryStringInfo (buf ,".size()" , 7 );
719+ appendStringInfoString (buf ,".size()" );
720720break ;
721721case jpiAbs :
722- appendBinaryStringInfo (buf ,".abs()" , 6 );
722+ appendStringInfoString (buf ,".abs()" );
723723break ;
724724case jpiFloor :
725- appendBinaryStringInfo (buf ,".floor()" , 8 );
725+ appendStringInfoString (buf ,".floor()" );
726726break ;
727727case jpiCeiling :
728- appendBinaryStringInfo (buf ,".ceiling()" , 10 );
728+ appendStringInfoString (buf ,".ceiling()" );
729729break ;
730730case jpiDouble :
731- appendBinaryStringInfo (buf ,".double()" , 9 );
731+ appendStringInfoString (buf ,".double()" );
732732break ;
733733case jpiDatetime :
734- appendBinaryStringInfo (buf ,".datetime(" , 10 );
734+ appendStringInfoString (buf ,".datetime(" );
735735if (v -> content .arg )
736736{
737737jspGetArg (v ,& elem );
@@ -740,7 +740,7 @@ printJsonPathItem(StringInfo buf, JsonPathItem *v, bool inKey,
740740appendStringInfoChar (buf ,')' );
741741break ;
742742case jpiKeyValue :
743- appendBinaryStringInfo (buf ,".keyvalue()" , 11 );
743+ appendStringInfoString (buf ,".keyvalue()" );
744744break ;
745745default :
746746elog (ERROR ,"unrecognized jsonpath item type: %d" ,v -> type );