The Cost of Dynamism (was Re: Pyhon 2.x or 3.x, which is faster?)
Mark Lawrence
breamoreboy at yahoo.co.uk
Mon Mar 14 16:57:36 EDT 2016
On 14/03/2016 17:53, BartC wrote:
> On 14/03/2016 17:17, Mark Lawrence wrote:
>> On 13/03/2016 20:12, Marko Rauhamaa wrote:
>>> BartC <bc at freeuk.com>:
>>>
>>>> Exactly why having ready-made solutions is preferable to everyone
>>>> hacking their own solutions to switch.
>>>
>>> A developer friend of mine once said insightfully that the point of OO
>>> is getting rid of switch statements. IOW, most use cases for switch
>>> statements are handled with virtual functions.
>>>
>>> The most significant exception in my experience is message decoding,
>>> where switches/ifs cannot be avoided.
>
>> http://c2.com/cgi/wiki?SwitchStatementsSmell
>
> I get it. The author doesn't like switch statements!
>
You clearly didn't bother reading the document. I suggest you try
again, and then attempt, just for once, to come back with some
worthwhile comments.
--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.
Mark Lawrence
More information about the Python-list
mailing list