... | ... | @@ -17,6 +17,13 @@ The general rule is to stick to the same coding style as is already used in the |
|
|
|
|
|
* Naming conventions for functions. If a function has type `This -> That`, call it `thisThat`. Not `thisToThat` nor `thatOfThis`. Example `exprType :: Expr -> Type`.
|
|
|
|
|
|
* For naming modules in the basic libraries `base`, `ghc-internal`, `ghc-experimental`, `ghc-prim`, and `ghc-bignum`, see [here](https://github.com/haskellfoundation/tech-proposals/blob/main/proposals/0000-ghc-module-naming.rst). In particular:
|
|
|
* Modules in `base`, `ghc-experimental`, `ghc-prim`, `ghc-internal` etc should all have distinct names.
|
|
|
* New modules in GHC's internal libraries (`ghc-prim`, `ghc-internal` etc) should be of form `GHC.Internal*`.
|
|
|
* Modules in `ghc-experimental` should be of form `*.Experimental`.
|
|
|
* Modules in `base` should not have either of these forms.
|
|
|
|
|
|
|
|
|
### 1.2 Prefer lucidity over brevity
|
|
|
|
|
|
**It's much better to write code that is transparent than to write code that is short.**
|
... | ... | |