error: array bound is not an integer constant
error: array bound is not an integer constant
- Subject: error: array bound is not an integer constant
- From: Markian Hlynka <email@hidden>
- Date: Fri, 15 Jul 2005 02:29:55 -0600
Hi all.
I've written some sample code below. This worked fine before, but I
just upgraded to xcode 2.1 and tiger 10.4.2. Now it's broken. I need
to be able to do this or else way lots of stuff breaks. Can someone
help me find a solution, or understand what's going on? The problem
seems to be in the typedef line. I don't actually need to do it for
an int, but the error is the same. What's going on?
(and yes, for all sorts of reasons, I _do need to use preprocessor
defines for now)
Thanks,
Markian
-----------------------------------------
#include <iostream>
using namespace std;
#define part1 100
#define part2 50
#define combined (part1 * part2)
#define BOARD_SIZE 7
#define FBS (float)(BOARD_SIZE)
#define MOVESFACTOR ((float)( ((int)( ( (FBS/2.0) * FBS) +0.5))+12.0))
#define MOVESFACTOR2 ((int)( (MOVESFACTOR/2.0)+0.5) )
#define MAX_LEGAL_MOVES (MOVESFACTOR2 * MOVESFACTOR2)
typedef int Movelist[MAX_LEGAL_MOVES];
int main()
{
cout<<"done: "<<combined<<endl;
}
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden