4 ms·
You're correct. Which is why in practice I often consider using a forward declaration and pointer to implementation instead. But you know what, even that can
by loup-vaillant 2y ago
You're correct. Which is why in practice I often consider using a forward declaration and pointer to implementation instead.
But you know what, even that can be gamed. I have gamed it once: I copied & pasted the definition of the struct, and accessed its member from a place that was supposed to only have access to an opaque pointer. It worked. (To be fair, this isn't the kind of stuff you do by mistake, unlike merely accessing a struct member.)