From owner-cvs-all Fri Feb 9 0:57:10 2001 Delivered-To: cvs-all@freebsd.org Received: from gratis.grondar.za (grouter.grondar.za [196.7.18.65]) by hub.freebsd.org (Postfix) with ESMTP id 491A937B401; Fri, 9 Feb 2001 00:56:38 -0800 (PST) Received: from grondar.za (root@gratis.grondar.za [196.7.18.133]) by gratis.grondar.za (8.11.1/8.11.1) with ESMTP id f198ti905417; Fri, 9 Feb 2001 10:55:47 +0200 (SAST) (envelope-from mark@grondar.za) Message-Id: <200102090855.f198ti905417@gratis.grondar.za> To: Luigi Rizzo Cc: Bruce Evans , Peter Wemm , Mike Heffner , cvs-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG Subject: Re: QUEUE macros considered harmful (was Re: cvs commit: src/usr.bin/lam lam.c) References: <200102090735.IAA31362@info.iet.unipi.it> In-Reply-To: <200102090735.IAA31362@info.iet.unipi.it> ; from Luigi Rizzo "Fri, 09 Feb 2001 08:35:35 +0100." Date: Fri, 09 Feb 2001 10:56:15 +0200 From: Mark Murray Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > Simple example taken from the firewall code: Simple examples don't cut the cake. Complex use of linked list code is _dramatically_ simplified by use of queue(3) macros. The formal structure and consistent use (even if not the most obvious use, nor the most intuitive at first). > the manpage says that LIST_ENTRY(TYPE) "declares a structure", > but 'TYPE' is not really a type, (the real type 'struct TYPE'), > and the macro declares a type, not the actual object. The LIST > macros are then used as follows: Fix the documentation, then! :-) M -- Mark Murray Warning: this .sig is umop ap!sdn To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message