I\'m getting \"error: expected \'}\'\" where the \'^\' is pointing when I compile in the following C++ source:
\"error: expected \'}\'\"
typedef enum { false, true } Boolean;
To solve this you need to do:
#ifdef __cplusplus typedef bool Boolean; #else typedef enum { false, true } Boolean; #endif
That way, you are not trying to use C++ keywords (true and false) in an enum.
true
false
enum