Skip to content

Comment on The Apple goto fail vulnerability: lessons learned (2014)parent

Comments

What's the practical difference between:

   if (foo)
      bar;
   else
      baz;
   
and:
   if (foo) {
      bar;
   } else {
      baz;
   }
The latter has one extra line, which is hardly bloat. It also has the braces, of course, but the upside of this style is that it's clear where the compound statement begins (it's the line that doesn't start with a brace!), and where it continues.
AboutSource Built by g1lg1l

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