aboutsummaryrefslogtreecommitdiff
path: root/src/backend/parser/parse_relation.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/parser/parse_relation.c')
-rw-r--r--src/backend/parser/parse_relation.c20
1 files changed, 3 insertions, 17 deletions
diff --git a/src/backend/parser/parse_relation.c b/src/backend/parser/parse_relation.c
index f5324cb3735..e1d49842fd2 100644
--- a/src/backend/parser/parse_relation.c
+++ b/src/backend/parser/parse_relation.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/parser/parse_relation.c,v 1.54 2001/04/18 17:04:24 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/backend/parser/parse_relation.c,v 1.55 2001/05/07 00:43:23 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -75,7 +75,7 @@ static struct
}
};
-#define SPECIALS ((int) (sizeof(special_attr)/sizeof(special_attr[0])))
+#define SPECIALS ((int) lengthof(special_attr))
/*
@@ -670,7 +670,7 @@ isForUpdate(ParseState *pstate, char *relname)
foreach(l, pstate->p_forUpdate)
{
- char *rname = lfirst(l);
+ char *rname = strVal(lfirst(l));
if (strcmp(relname, rname) == 0)
return true;
@@ -1020,20 +1020,6 @@ attnameIsSet(Relation rd, char *name)
#endif
-#ifdef NOT_USED
-/*
- * This should only be used if the relation is already
- * heap_open()'ed. Use the cache version
- * for access to non-opened relations.
- */
-int
-attnumAttNelems(Relation rd, int attid)
-{
- return rd->rd_att->attrs[attid - 1]->attnelems;
-}
-
-#endif
-
/* given attribute id, return type of that attribute */
/*
* This should only be used if the relation is already