@@ -104,10 +104,9 @@ typedef struct JsonbValue JsonbValue;
104
104
* To encode the length and offset of the variable-length portion of each
105
105
* node in a compact way, the JEntry stores only the end offset within the
106
106
* variable-length portion of the container node. For the first JEntry in the
107
- * container's JEntry array, that equals to the length of the node data. For
108
- * convenience, the JENTRY_ISFIRST flag is set. The begin offset and length
109
- * of the rest of the entries can be calculated using the end offset of the
110
- * previous JEntry in the array.
107
+ * container's JEntry array, that equals to the length of the node data. The
108
+ * begin offset and length of the rest of the entries can be calculated using
109
+ * the end offset of the previous JEntry in the array.
111
110
*
112
111
* Overall, the Jsonb struct requires 4-bytes alignment. Within the struct,
113
112
* the variable-length portion of some node types is aligned to a 4-byte
@@ -124,7 +123,7 @@ typedef struct JsonbValue JsonbValue;
124
123
* The least significant 28 bits store the end offset of the entry (see
125
124
* JBE_ENDPOS, JBE_OFF, JBE_LEN macros below). The next three bits
126
125
* are used to store the type of the entry. The most significant bit
127
- * is set on the first entry in an array of JEntrys .
126
+ * is unused, and should be set to zero .
128
127
*/
129
128
typedef uint32 JEntry ;
130
129
@@ -140,7 +139,6 @@ typedef uint32 JEntry;
140
139
#define JENTRY_ISCONTAINER 0x50000000 /* array or object */
141
140
142
141
/* Note possible multiple evaluations */
143
- #define JBE_ISFIRST (je_ ) (((je_) & JENTRY_ISFIRST) != 0)
144
142
#define JBE_ISSTRING (je_ ) (((je_) & JENTRY_TYPEMASK) == JENTRY_ISSTRING)
145
143
#define JBE_ISNUMERIC (je_ ) (((je_) & JENTRY_TYPEMASK) == JENTRY_ISNUMERIC)
146
144
#define JBE_ISCONTAINER (je_ ) (((je_) & JENTRY_TYPEMASK) == JENTRY_ISCONTAINER)
0 commit comments