Quantcast
Channel: LabWindows/CVI topics
Viewing all articles
Browse latest Browse all 5339

Multiple unsequenced modifications to 'i' warning

$
0
0

Hello all,

I am receving a sequence of 12-bit binary integers from a microprocessor and I want to decode them.

My code is the following:

unsigned short		mm1 = 0, mm2 = 0, mm3 = 0;
int		i;
char		buf[64];

i = 0;
mm1 = (buf[i++] << 8) + buf[i++];
mm2 = (buf[i++] << 8) + buf[i++];
mm3 = (buf[i++] << 8) + buf[i++];

The compiler issues the following: "warning: multiple unsequenced modifications to 'i' ", however returned values are correct (er, they were in CVI2012: I am porting some code to 2015 but still haven't tested it).

What does it means? How can I get rid of the warning?


Viewing all articles
Browse latest Browse all 5339

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>