On Wednesday, 20 February 2013 at 06:00:02 UTC, deadalnix wrote:
As discussed previously, I really wonder hy a const and non const version of a function can exists in a first place. What problem does it solve that isn't better solved by inout ?

I use overloading of const/immutable in one of my projects to avoid a string copy when possible:

https://github.com/JakobOvrum/Dirk/blob/master/irc/client.d#L332

Granted, here const does not apply to the implicit `this` parameter, but it is essentially the same thing.

Reply via email to