dynamic classes and duck typing

retard re at tard.com.invalid
Tue Dec 1 22:47:29 PST 2009


Tue, 01 Dec 2009 14:22:10 -0800, Walter Bright wrote:

> bearophile wrote:
>> Right. But what people care in the end is programs that get the work
>> done. If a mix of Python plus C/C++ libs are good enough and handy
>> enough then they get used. For example I am able to use the PIL Python
>> lib with Python to load, save and process jpeg images at high-speed
>> with few lines of handy code. So I don't care if PIL is written in C++:
>> http://www.pythonware.com/products/pil/
> 
> Sure, but that's not about the language. It's about the richness of the
> ecosystem that supports the language, and Python certainly has a rich
> one.

I thought D was supposed to be a practical language for real world 
problems. This 'D is good because everything can and must be written in 
D' is beginning to sound like a religion. To me it seems the Python way 
is more practical in all ways. Even novice programmers can produce 
efficient programs with it by using a mixture of low level C/C++ libs and 
high level python scripts.

I agree that Python isn't as fast as D and it lacks type safety things 
and so on, but in the end of day the Python coder gets the job done while 
the D coder still fights with inline assembler, compiler bugs, porting 
the app, fighting the type system (mostly purity/constness issues). 
Python has more libs available, you need to write less code to implement 
the same functionality and it's all less troublesome because the lack of 
type annotations. So it's really understandable why a greater amount 
people favor Python.



More information about the Digitalmars-d mailing list