mirror of
https://github.com/Jeuners/ECC.git
synced 2026-09-15 17:46:10 +02:00
fix: address kotlin doc review feedback
This commit is contained in:
parent
135eb4c98d
commit
e692a2886c
3 changed files with 25 additions and 20 deletions
|
|
@ -9,13 +9,16 @@ alwaysApply: false
|
|||
|
||||
## Formatting
|
||||
|
||||
- **ktfmt** or **ktlint** are mandatory for consistent formatting
|
||||
- Auto-formatting via **ktfmt** or **ktlint** (configured in `kotlin-hooks.md`)
|
||||
- Use trailing commas in multiline declarations
|
||||
|
||||
## Immutability
|
||||
|
||||
- `val` over `var` always
|
||||
- Immutable collections by default (`List`, `Map`, `Set`)
|
||||
The global immutability requirement is enforced in the common coding style rule.
|
||||
For Kotlin specifically:
|
||||
|
||||
- Prefer `val` over `var`
|
||||
- Use immutable collection types (`List`, `Map`, `Set`)
|
||||
- Use `data class` with `copy()` for immutable updates
|
||||
|
||||
## Null Safety
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue