KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
We all know that dereferencing an null pointer or a pointer to unallocated memory invokes undefined behaviour. But what is the rule when used within an expression passed to sizeof ? For example: int *ptr = 0; int size = sizeof(*ptr); Is this also undefined?
Tags (comma-separated)
Save Edits
Cancel