I prefer this syntax: ``` public private(set) var ...
# language-proposals
b
I prefer this syntax:
Copy code
public private(set) var a
m
and if you want to override a setter?
b
It'll work the same:
Copy code
public private(set) var a
    get() = ...
    set(newValue) = ...
m
Why you don’t like existing syntax? It’s clear when private stands on a new line:
Copy code
public var a ...
    private set
b
Just
set(newValue)
would only be callable inside
private
scope, while all other scopes just see an immutable `val`and its
get()
That might work too!
m
That already works 🙂
b
Just voicing my opinions :)