Prototype OO

sam sam at mas.pl
Wed Apr 2 08:23:21 EDT 2008


Gabriel Genellina napisał(a):

>>>> 1. You have different syntax for named and unnamed (lambdas)
>>>> functions. Functions and methods are different things in Python even
>>>> if they have same syntax. But all these are still a pieces of code
>>>> that you use repeatedly to make some task.
>>>>
>>> A knife and scissors are both used to cut things, but that doesn't mean
>>> they are the same.
>>
>> Well -- sometimes you have to use many, many types of scissors.
> 
> I don't get the point - weren't you criticizing Python for having many 
> different kind of functions?

Yes. Funciton is always a piece of code (program) that does something. There is 
no need for different syntax.

And you said that it is good to have these two types of syntax. It sounds like: 
"it is good to have knife and scissors to cut the _same_ thing, because they are 
not the same".




> What are those programmers needs?

Programmers need to protect name in a namespace. Name mangling is not the best 
choice.







More information about the Python-list mailing list