• Decq@lemmy.world
    link
    fedilink
    arrow-up
    2
    ·
    10 hours ago

    Whitespace being part of semantics is always a bad design decision. You’re not alone in this. I wish this was more widely accepted. But alas, it’s not. For a configuration language I can accept it a bit more. But for a programming language it’s a big faux pas in my opinion (looking at you python).

    • crater2150@feddit.org
      link
      fedilink
      arrow-up
      1
      ·
      40 minutes ago

      I was in the same camp when I had to use Python on the job, but when Scala introduced (optional) significant whitespace, I actually grew to like it a lot. I think the important difference to Python is, that with a good type system and compile time checks a whitespace error is basically always a compile time error in Scala. That’s also for me it’s worse in a configuration language (unless you have a schema file for validation, which is rarely the case sadly)