0
void Halt ();
void Reply (const char * num,uint8_t stat);

{

this is the error message for this code
7|error: 'uint8_t' has not been declared
9|error: expected unqualified-id before '{' token

no idea
3
Contributors
3
Replies
22
Views
11 Months
Discussion Span
Last Post by directorabbey
0

uint8_t as others of that ilk are not defined by default by c or c++. You either need to include some header that defines them for you, or you need to define them yourself as in:

typedef unsigned char uint8_t;

0

As rubberman mentioned, those typedefs are specified in <stdint.h> (for C) and <cstdint> (for C++). But note that <cstdint> wasn't officially supported by C++ until the C++11 standard, so if you're not compiling against that standard then defining your own or using the Boost library would be options to consider.

Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.