Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id ; Mon, 30 Sep 2002 15:32:12 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id ; Mon, 30 Sep 2002 15:32:11 -0400 Received: from dsl-213-023-038-108.arcor-ip.net ([213.23.38.108]:38292 "EHLO starship") by vger.kernel.org with ESMTP id ; Mon, 30 Sep 2002 15:32:09 -0400 Content-Type: text/plain; charset=US-ASCII From: Daniel Phillips To: Zach Brown , Linux Kernel Mailing List Subject: Re: [PATCH][2.5] Single linked lists for Linux, overly complicated v2 Date: Mon, 30 Sep 2002 21:37:53 +0200 X-Mailer: KMail [version 1.3.2] References: <20020926205727.T13817@bitchcake.off.net> In-Reply-To: <20020926205727.T13817@bitchcake.off.net> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Message-Id: Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 728 Lines: 22 On Friday 27 September 2002 02:57, Zach Brown wrote: > #define tslist_add(_head, _elem) \ > do { \ > BUG_ON(tslist_on_list(_head, _elem)); \ > (_elem)->_slist_next = (_head); \ > (_head) = (_elem); \ > } while(0) This evaluates _head and _elem twice each, or three times if you count the BUG_ON. Smaller point: why bother obfuscating the parameter names? You will need to do that for locals in macros but parameters should cause no name conflicts. -- Daniel - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/