From 509af15852c5bb05d23a3ea8159aadf2272516ad Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Thu, 17 Aug 2017 12:39:20 -0400 Subject: [PATCH 5/6] Remove endof macro It has not been used in a long time, and it doesn't seem safe anyway, so drop it. --- src/include/c.h | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/include/c.h b/src/include/c.h index c28534bc88..fd0a6ad0c3 100644 --- a/src/include/c.h +++ b/src/include/c.h @@ -30,7 +30,7 @@ * 2) bool, true, false, TRUE, FALSE * 3) standard system types * 4) IsValid macros for system types - * 5) offsetof, lengthof, endof, alignment + * 5) offsetof, lengthof, alignment * 6) assertions * 7) widely useful macros * 8) random stuff @@ -533,7 +533,7 @@ typedef NameData *Name; /* ---------------------------------------------------------------- - * Section 5: offsetof, lengthof, endof, alignment + * Section 5: offsetof, lengthof, alignment * ---------------------------------------------------------------- */ /* @@ -553,12 +553,6 @@ typedef NameData *Name; */ #define lengthof(array) (sizeof (array) / sizeof ((array)[0])) -/* - * endof - * Address of the element one past the last in an array. - */ -#define endof(array) (&(array)[lengthof(array)]) - /* ---------------- * Alignment macros: align a length or address appropriately for a given type. * The fooALIGN() macros round up to a multiple of the required alignment, -- 2.14.1