Const vs Non const method
Ola Fosheim Grøstad via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Mar 7 02:52:53 PST 2016
On Sunday, 6 March 2016 at 17:53:47 UTC, Namespace wrote:
> What would be the C++ way? Is there any comfortable way to
> solve this problem in a nice way like D?
C++ has a non-idiomatic language culture. There are many ways to
do it. One clean way could be to use a templated method, another
way is to use a function object, a dirty way would be to use a
const-cast.
More information about the Digitalmars-d-learn
mailing list