From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: Date: Fri, 21 Nov 2008 16:54:56 -0800 From: "Russ Cox" To: "Fans of the OS Plan 9 from Bell Labs" <9fans@9fans.net> Subject: Re: [9fans] /sys/src/libdraw/arith.c:163 In-Reply-To: <4b41d6d160b1e8f95e193e2e15a713bf@proxima.alt.za> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <4b41d6d160b1e8f95e193e2e15a713bf@proxima.alt.za> Topicbox-Message-UUID: 508e317c-ead4-11e9-9d60-3106f5b1d025 On Fri, Nov 21, 2008 at 1:41 AM, wrote: > The code is: > > extern ulong > drawld2chan[] = { > GREY1, > GREY2, > GREY4, > CMAP8, > }; > > and GCC (yes, that one!) complains about it: > > gcc -c -Wall -D_PLAN_9 -D_POSIX_SOURCE -D_PLAN9_SOURCE -I. /sys/src/libdraw/arith.c > /sys/src/libdraw/arith.c:163: warning: `drawld2chan' initialized and declared `extern' > > It seems a legitimate complaint, but I'm not sure how I should address > it. The idea is to make sure that this remains compatible with the > Plan 9 native compilers, of course. Gcc has correctly diagnosed a mistake; s/extern\n// Russ