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.

Strange CCS compiler warning when comparing pointers

Other Parts Discussed in Thread: TEST2

Hi,

I'm not sure if this is the correct forum but I am seeing this problem on the TMS570 using CCS code generation toold V4.6.3.

I have some code where I want to validate a parameter that is a function pointer. I am getting an "operand types are incompatible" warning message even though the types are the same. Here is an example that highlights the problem:

int test(void);

static void test1(void);

static void test2(void);

int test(void)

{

    int i = 0;

    if(&test1 > &test2) /* Warning on this line */

    {

        i = 1;

    }

    return i;

}

static void test1(void) { }

static void test2(void) { }