Article View: comp.sys.mac.programmer.codewarrior
Article #930Re: What am I doing wrong? 'illegal constant expression'??
From: Sean McBride
Date: Tue, 15 Oct 2002 23:22
Date: Tue, 15 Oct 2002 23:22
40 lines
2196 bytes
2196 bytes
In article <b80cquo5frrpptgjbg8v0juu5d2dom7hk9@4ax.com>, News Reader <nntp@r.us> wrote: > What am I doing wrong here? I'm using Codewarrior8 on MacOSX. All > this compiled fine before under Codewarrior7 on MacOSX. > What am I missing? I'm using CW8's MacOSX target setting (not Apple's > MacOSX). > > > Error : illegal constant expression > (included from: > IOKitLib.h:48 > CGDisplayConfiguration.h:11 > CoreGraphics.h:20 > QD.h:25 > ApplicationServices.h:30 > carbon.h:24 > MgcOpenGLIncludes.h:26 > MgcOpenGLRenderer.h:23 > MgcAglRenderer.h:22 > MgcAglRenderer.cpp:21) > OSMessageNotification.h line 83 unsigned char content[0]; > > Error : illegal constant expression > (included from: > IOKitLib.h:48 > CGDisplayConfiguration.h:11 > CoreGraphics.h:20 > QD.h:25 > ApplicationServices.h:30 > carbon.h:24 > MgcOpenGLIncludes.h:26 > MgcOpenGLRenderer.h:23 > MgcAglRenderer.h:22 > MgcAglRenderer.cpp:21) > OSMessageNotification.h line 93 void * args[0]; I've seen this too. Some of Apple headers don't complile if CW's 'ANSI strict' option is on. Turning it off should fix these errors. Apple needs to improve their headers, do file a bug with them.
Technical Details
Message-ID:
<cwatson-07AAD6.19220015102002@aeinews.aei.ca>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!bloom-beacon.mit.edu!news-out.cwix.com!newsfeed.cwix.com!newsfeed1.cidera.com!Cidera!aeinews.!cwatsonReferences:
<b80cquo5frrpptgjbg8v0juu5d2dom7hk9@4ax.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10bcce,54136c2220b9e666 X-Google-Attributes: gid10bcce,public X-Google-Thread: f635e,54136c2220b9e666 X-Google-Attributes: gidf635e,public X-Google-ArrivalTime: 2002-10-15 16:22:54 PST From: Sean McBride <cwatson@cam.org> Newsgroups: comp.sys.mac.programmer.codewarrior,codewarrior.mac Subject: Re: What am I doing wrong? 'illegal constant expression'?? Organization: It's spelt "organisation"! References: <b80cquo5frrpptgjbg8v0juu5d2dom7hk9@4ax.com> User-Agent: MT-NewsWatcher/3.2 (PPC Mac OS X) Date: Tue, 15 Oct 2002 19:22:00 -0400 Message-ID: <cwatson-07AAD6.19220015102002@aeinews.aei.ca> NNTP-Posting-Host: dsl-135-245.aei.ca X-Trace: aeinews. 1034724287 dsl-135-245.aei.ca (15 Oct 2002 19:24:47 -0400) Lines: 40 Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!bloom-beacon.mit.edu!news-out.cwix.com!newsfeed.cwix.com!newsfeed1.cidera.com!Cidera!aeinews.!cwatson