Compilers these days tend to do a significant amount of optimizations. Do they also remove unused functions from the final output?
Compilers these days tend to do a significant amount of optimizations. Do they also
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
It depends on the compiler. Visual C++ 9 can do that – unused
staticfunctions are removed at compilation phase (there’s even a C4505 warning for that), unused functions with external linkage can be removed at link phase depending on linker settings.