|
|
|
|
|
by comex
2777 days ago
|
|
The aliasing rule isn’t symmetric: you can access objects originally declared as types other than char using char pointers, but you can’t access objects originally declared as char using non-char pointers. (And malloc()ed buffers are neither of the above and have their own rule.) Here’s a blog post explaining it in more detail: https://gustedt.wordpress.com/2016/08/17/effective-types-and... |
|