I am currently starting to program microcontrollers using C30(A microchip Cbased compiler GCCfor my devices PIC24), and I turned it on Strict ANSI warningsout of curiosity. Firstly, I didn’t know that in the comments of the C11 comment, for example, // are "wrong", and instead I should use / * blah blah * /, but I was really surprised by this warning for a line of code.
"warning: using non-standard binary prefix"
Line of code:
OSCCONbits.COSC = 0b000;
I looked online on one of the C11 projects (ISO / IEC 9899: 2011) and cannot find anything about binary prefixes in C. http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1570 .pdf
What is the correct binary notation for C according to C11?
source
share