<div dir="ltr">On 10 April 2013 22:37, Andrei Alexandrescu <span dir="ltr"><<a href="mailto:SeeWebsiteForEmail@erdani.org" target="_blank">SeeWebsiteForEmail@erdani.org</a>></span> wrote:<br><div class="gmail_extra">
<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On 4/10/13 2:02 AM, Manu wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I do use virtual functions, that's the point of classes. But most<br>
functions are not virtual. More-so, most functions are trivial<br>
accessors, which really shouldn't be virtual.<br>
</blockquote>
<br></div>
I'd say a valid style is to use free functions for non-virtual methods. UFCS will take care of caller syntax.</blockquote><div><br></div><div style>Valid, perhaps. But would you really recommend that design pattern?</div>
<div style>It seems a little obscure for no real reason. Breaks the feeling of the OO encapsulation principle somewhat.</div><div style><br></div><div style>I've started using UFCS more recently, but I'm still wary of overuse leading to unnecessary obscurity.</div>
</div></div></div>