Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S261305AbUKWPLT (ORCPT ); Tue, 23 Nov 2004 10:11:19 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S261302AbUKWPI7 (ORCPT ); Tue, 23 Nov 2004 10:08:59 -0500 Received: from news.suse.de ([195.135.220.2]:50357 "EHLO Cantor.suse.de") by vger.kernel.org with ESMTP id S261282AbUKWPIA (ORCPT ); Tue, 23 Nov 2004 10:08:00 -0500 To: Jan Engelhardt Cc: Bill Davidsen , Jakub Jelinek , linux-kernel@vger.kernel.org Subject: Re: var args in kernel? References: <20041122113328.GQ10340@devserv.devel.redhat.com> <41A25D53.9050909@tmr.com> From: Andreas Schwab X-Yow: As President I have to go vacuum my coin collection! Date: Tue, 23 Nov 2004 16:07:58 +0100 In-Reply-To: (Jan Engelhardt's message of "Tue, 23 Nov 2004 15:05:21 +0100 (MET)") Message-ID: User-Agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 900 Lines: 29 Jan Engelhardt writes: >>> Why can't you do dest=src? Assignment of struct to struct has been a part >>> of C since earliest times. >> >>It's not a struct, it's an array (of one element of struct type). You >>can't assign arrays. > > int callme(const char *fmt, struct { ... } argp[1]) { struct { ... } dest[1]; > dest = *argp; > } > > Maybe that way? Maybe you should just try. Andreas. -- Andreas Schwab, SuSE Labs, schwab@suse.de SuSE Linux Products GmbH, Maxfeldstra?e 5, 90409 N?rnberg, Germany Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different." - 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/