Hacker News new | ask | show | jobs
by dmitryminkovsky 2575 days ago
Are there other languages that make an opinion on tabs/spaces? This seems nice.

> The only whitespace now allowed in code is ASCII space and line endings. Since you must use indentation to format PureScript code (unlike Haskell), we felt it was best to be more restrictive in what you can write instead of allowing potentially confusing behavior (implicit tab-width, zero-width spaces, etc). You can still use unicode whitespace within string literals.

I’m also wondering about the removed literals.

3 comments

F# doesn't allow tabs unless you use a compiler directive
Zig doesn't allow tabs in source code—which is a bit odd, since they don't have significant whitespace.
I think Elm have similar rules, the official code format tool is very opinionated.
I can attest to that, elm-format is an excellent tool and it is great to have a standard code formatter, one less thing to worry or argue over when writing code!