On 10 April 2013 22:37, Andrei Alexandrescu
<[email protected]>wrote:

> On 4/10/13 2:02 AM, Manu wrote:
>
>> I do use virtual functions, that's the point of classes. But most
>> functions are not virtual. More-so, most functions are trivial
>> accessors, which really shouldn't be virtual.
>>
>
> I'd say a valid style is to use free functions for non-virtual methods.
> UFCS will take care of caller syntax.


Valid, perhaps. But would you really recommend that design pattern?
It seems a little obscure for no real reason. Breaks the feeling of the OO
encapsulation principle somewhat.

I've started using UFCS more recently, but I'm still wary of overuse
leading to unnecessary obscurity.

Reply via email to