Reply to: A Boggling Return to C

Most compilers don't optimize across function boundaries, so it doesn't know that strlen does not have side effects. If it had side effects, the compiler has to assume that you wanted the function invoked for every iteration.

formatting is with Markdown syntax. Comments are not displayed until they are approved by a moderator. Moderators will not approve unless the comment contributes value to the discussion.

remember info?