Skip to content

Comment on Extending ltrace to make your Ruby/Python/Perl/PHP apps fasterparent

Comments

Right but I can selectively run ltrace, where as my logging statements are always in the code, and if statements have to be evaluated etc

It's not about performance; it's about not having logging statements in the code and/or having to add them when something goes awry.

One shouldn't remove asserts() just because you're going to ship code, you just #define assert() to expand nothing. Same applies to languages other than C that don't have a pre-processor: you can define a null function, and hopefully your runtime is awesome enough to optimize calls to it away.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.