Is defining get/set methods for every field overkill?
thebluepandabear
therealbluepandabear at protonmail.com
Mon Nov 21 00:33:57 UTC 2022
On Monday, 21 November 2022 at 00:29:12 UTC, thebluepandabear
wrote:
>> .. not to mention, I'd be out of job if I stopped writing
>> getters/setters ;-)
>
> I value your input in this discussion, you have brought some
> good points.
>
> Out of interest, what type of industry-level software are you
> creating with D? I don't know much companies using D
> commercially.
I think I may actually have been convinced that writing
getters/setters is good practice, I think it's better be safe
than sorry because I am writing a library it may be important not
to break ABI compatibility in the future if needed, plus I will
not need to change the field name if I ever want to add
getters/setters.
More information about the Digitalmars-d-learn
mailing list