|
-
Dec 27th, 2001, 10:55 PM
#1
Thread Starter
Hyperactive Member
C Help
ompiling...
gtest.c
c:\windows\desktop\new folder\dppv.h(151) : error C2065: 'dp_MAXPLAYERS' : undeclared identifier
c:\windows\desktop\new folder\dppv.h(151) : error C2057: expected constant expression
c:\windows\desktop\new folder\dppv.h(152) : error C2229: struct '__unnamed' has an illegal zero-sized array
c:\windows\desktop\new folder\dppv.h(153) : error C2057: expected constant expression
c:\windows\desktop\new folder\dppv.h(154) : error C2229: struct '__unnamed' has an illegal zero-sized array
c:\windows\desktop\new folder\dp.h(409) : error C2057: expected constant expression
c:\windows\desktop\new folder\dp.h(412) : error C2229: struct 'dp_s' has an illegal zero-sized array
c:\windows\desktop\new folder\dp.h(413) : error C2057: expected constant expression
c:\windows\desktop\new folder\dp.h(418) : error C2229: struct 'dp_s' has an illegal zero-sized array
c:\windows\desktop\new folder\anet.h(1447) : warning C4005: 'dp_PLAYERDATA_LEN_MAX' : macro redefinition
c:\windows\desktop\new folder\dppv.h(81) : see previous definition of 'dp_PLAYERDATA_LEN_MAX'
c:\windows\desktop\new folder\gtest.c(1852) : warning C4020: 'commScanAddr' : too many actual parameters
Error executing cl.exe.
gtest.obj - 9 error(s), 2 warning(s)
what do thoes errors mean and how can they be fixed ?
-
Dec 28th, 2001, 08:06 AM
#2
c:\windows\desktop\new folder\dppv.h(151) : error C2065: 'dp_MAXPLAYERS' : undeclared identifier
the name doesn't exist. Typo? Forgot to include a header?
c:\windows\desktop\new folder\dppv.h(151) : error C2057: expected constant expression
Seems you're using a variable when declaring an array size:
int i = 2;
char ar[i];
This is illegal, array sizes need to be constants.
c:\windows\desktop\new folder\dppv.h(152) : error C2229: struct '__unnamed' has an illegal zero-sized array
A follow-up on the last error.
c:\windows\desktop\new folder\dppv.h(153) : error C2057: expected constant expression
Like (151)
c:\windows\desktop\new folder\dppv.h(154) : error C2229: struct '__unnamed' has an illegal zero-sized array
Like (152)
c:\windows\desktop\new folder\dp.h(409) : error C2057: expected constant expression
Again
c:\windows\desktop\new folder\dp.h(412) : error C2229: struct 'dp_s' has an illegal zero-sized array
And again.
c:\windows\desktop\new folder\dp.h(413) : error C2057: expected constant expression
again
c:\windows\desktop\new folder\dp.h(418) : error C2229: struct 'dp_s' has an illegal zero-sized array
again
c:\windows\desktop\new folder\anet.h(1447) : warning C4005: 'dp_PLAYERDATA_LEN_MAX' : macro redefinition
this has already been defined once. You get this error when you write:
#define MAXVALUE 23
#define MAXVALUE 23 // error - name already exists
c:\windows\desktop\new folder\dppv.h(81) : see previous definition of 'dp_PLAYERDATA_LEN_MAX'
This would be where it was defined first
c:\windows\desktop\new folder\gtest.c(1852) : warning C4020: 'commScanAddr' : too many actual parameters
You supply too many parameters to a function/macro.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Dec 29th, 2001, 09:20 AM
#3
Thread Starter
Hyperactive Member
Thanks man verry gratefull.
I do not know C/C++ at all but i think i can fix them now
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|