Reputation: 1
I'm having a problem with the NIOS 2 SD Card Libary.
The problem is referenced to this part of the libary:
#ifndef bool
typedef enum e_bool { false = 0, true = 1 } bool;
#endif
The NIOS Eclipse compiler resulted me this error:
declaration does not declare anything
What might be causing this issue?
Upvotes: 0
Views: 685
Reputation: 7368
in C++ bool
is a keyword not a macro so the code above inside the ifdef
is skipped and not compiled.
In C code sometimes bool
is defined as a macro
#define bool int
#define true 1
#define false 0
Upvotes: 0