But I use also ChatGPT. It came to the same conclusion, it is a pointer directive not an operator.
buf[BUF_SIZE-1] = (uint8_t *)'\n';
is almost certainly incorrect code. It is trying to cast a char
constant to a pointer to a uint8_t
, and then copy that address (10) into the buf[]
array. This makes no sense: the address will be 32 bits long, and the buf[] array contains 8-bit values. Hence the warning.