4 ms·
Asking as a Haskell dabbler - why are features like `ExtendedLiterals` behind an opt-in language extension? Why not just turn it on for everyone?
by ridiculous_fish 3y ago
Asking as a Haskell dabbler - why are features like `ExtendedLiterals` behind an opt-in language extension? Why not just turn it on for everyone?
- ReleaseCandidat 3y agoThis happens with the most used"(?) extensions after some time. Now for example there is Ghc2021 which sets the following extensions: https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/control.html https://ghc.gitlab.haskell.org/ghc/doc/users_guide/exts/cont...
- sbergot 3y agoOne possible reason could be that haskell has specifications (latest version is haskell 2010) and multiple implementations. So GHC cannot change the default language like this.
- Buttons840 3y agoHiding language features behind opt-in flags seems weird, but after some thought I like it. Consider if C++ had similar flags, people are always saying to choose a subset of C++ to use, and flags would make that explicit and enforceable. Also, when you see a weird bit of syntax you would have an idea what to search for.