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.

The CCS5's Debugger always show message “Error: cannot load from non-primitive location”.

When I was debugging a test programming, the CCS5 show error message to me, but you may step by step into the sub-function.

I need great master to help and guide me to resolve it. Thanks very much for great master.

As following, I submit the test programming and some screen.

-------------------------------------------------------------------------the test programming start ----------------------------------------------------------

#include "stdio.h"
#include "stdlib.h"
typedef void (*tfnShow)(void);
typedef struct _tagTestStrt tTestStrt, *tPTestStrt;
struct _tagTestStrt
{
    tfnShow show;
};
void _Show(void)
{
    printf("success... \n");
}
void TestFunction(void)
{
    tPTestStrt pTestStrt = NULL;
    pTestStrt = malloc(sizeof(tTestStrt));
    if (NULL == pTestStrt )
    {
        printf("malloc failed\n");
        return;
    }
    else
    {
        pTestStrt->show = _Show;
    }
    pTestStrt->show();
}
void main(void)
{
    TestFunction();
}
-------------------------------------------------------------------------the test programming end ----------------------------------------------------------