summaryrefslogtreecommitdiff
path: root/src/backend/access/common/heaptuple.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2002-08-25 17:20:01 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2002-08-25 17:20:01 +0000
commit58de480999da65ec0fbf256f17800cba89e26dd5 (patch)
treeff80d7c93f5836bbdfdc0b3c6a5165423856cb83 /src/backend/access/common/heaptuple.c
parentd46172e4fa930e18768b8b913166108a4909e858 (diff)
Clean up comments to be careful about the distinction between variable-
width types and varlena types, since with the introduction of CSTRING as a more-or-less-real type, these concepts aren't identical. I've tried to use varlena consistently to denote datatypes with typlen = -1, ie, they have a length word and are potentially TOASTable; while the term variable width covers both varlena and cstring (and, perhaps, someday other types with other rules for computing the actual width). No code changes in this commit except for renaming a couple macros.
Diffstat (limited to 'src/backend/access/common/heaptuple.c')
-rw-r--r--src/backend/access/common/heaptuple.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/backend/access/common/heaptuple.c b/src/backend/access/common/heaptuple.c
index 4aa66879feb..5735da26d46 100644
--- a/src/backend/access/common/heaptuple.c
+++ b/src/backend/access/common/heaptuple.c
@@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.79 2002/08/24 15:00:45 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.80 2002/08/25 17:20:00 tgl Exp $
*
* NOTES
* The old interface functions have been converted to macros
@@ -116,7 +116,7 @@ DataFill(char *data,
else if (att[i]->attlen == -1)
{
/* varlena */
- *infomask |= HEAP_HASVARLENA;
+ *infomask |= HEAP_HASVARWIDTH;
if (VARATT_IS_EXTERNAL(value[i]))
*infomask |= HEAP_HASEXTERNAL;
if (VARATT_IS_COMPRESSED(value[i]))
@@ -127,7 +127,7 @@ DataFill(char *data,
else if (att[i]->attlen == -2)
{
/* cstring */
- *infomask |= HEAP_HASVARLENA;
+ *infomask |= HEAP_HASVARWIDTH;
data_length = strlen(DatumGetCString(value[i])) + 1;
memcpy(data, DatumGetPointer(value[i]), data_length);
}
@@ -230,9 +230,9 @@ nocachegetattr(HeapTuple tuple,
/* ----------------
* Three cases:
*
- * 1: No nulls and no variable length attributes.
- * 2: Has a null or a varlena AFTER att.
- * 3: Has nulls or varlenas BEFORE att.
+ * 1: No nulls and no variable-width attributes.
+ * 2: Has a null or a var-width AFTER att.
+ * 3: Has nulls or var-widths BEFORE att.
* ----------------
*/
@@ -326,7 +326,7 @@ nocachegetattr(HeapTuple tuple,
/*
* If slow is false, and we got here, we know that we have a tuple
- * with no nulls or varlenas before the target attribute. If possible,
+ * with no nulls or var-widths before the target attribute. If possible,
* we also want to initialize the remainder of the attribute cached
* offset values.
*/