Tool/software: TI C/C++ Compiler
the oprative "+=" seems to be wrongly compiled when I define a struct variable.
typedef struct{
unsigned short a:8;
unsigned short b:8;
}AA;
volatile AA test;
When I use test.a += 1, it gets a wrong result. And I saw into assemble code, it was not right. When I do not use volatile, the compiling seems right with "+="
And when I use test.a = test.a + 1, it can get a right result.
Why does this happen? If the compiler has problems, I don't know if there are other errors in my code. I can't see into all the assemble code since my C code is very large.