This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Macro Expansion Issue

I've got a macro that expands a #define'd register name to reference a byte in an information segment of flash.  I'm then trying to test that value to conditionally execute some code.  CCS is giving me a couple compiler errors, though, saying "Syntax error" and "expected a ')'" so I expanded it by hand to the point where I'm not sure why there is an error:

#define	FLASH_SEGMENT_D_ADDR		0x1000;
if ((*(unsigned char*)(FLASH_SEGMENT_D_ADDR + 0x0000)))
{
	do_stuff();
}

That still gives me the error, but if I do:

if ((*(unsigned char*)(0x1000 + 0x0000)))
{
	do_stuff();
}

then it's happy.  That seems like a pretty simply preprocessor substitution...  Am I missing something?

**Attention** This is a public forum