I have some operation like this C++ code that I want to convert in C89:
return reinterpret_cast<uint8_t *>(stream.buffer) - buffer;
How can I replace the reinterpret cast in C?
I have some operation like this C++ code that I want to convert in C89:
return reinterpret_cast<uint8_t *>(stream.buffer) - buffer;
How can I replace the reinterpret cast in C?
Nothing very exciting, you've seen this before:
(uint8_t *)(stream.buffer)
That's the only way to cast something in C.