Hacker News new | past | comments | ask | show | jobs | submit login

How do you know it's never called? You can call the function from another file. It's not possible to know that the function is never called until link time.



No, the function pointer is declared static. It cannot be referred to outside the current file.


The function pointer is static. But the function that mutates it, NeverCalled, is not. One can still indirectly change that function pointer.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: