COM support (was Re: Can Python replace Visual Basic? Should it?)

Alex Martelli aleaxit at yahoo.com
Fri Mar 9 07:24:55 EST 2001


"Werner Schiendl" <ws-news at gmx.at> wrote in message
news:984133550.452523 at newsmaster-04.atnet.at...
    [snip]
> I did not do much COM stuff in Python right now, but I think you cannot
> compare it to Visual Basic at this time.
> Of course, Mark Hammond does a really impressing job on that issue, but
> Microsoft is still somewhat in advance with VB I think.

Speaking as somebody whose main bill-paying-techolological-expertise
right now is COM -- I disagree.  VB may well be better for those who
_lack_ significant COM expertise and still need to handle a lot of COM
stuff -- if nothing else, because it does a good job of handling the
visual parts of Active/X, and comes with a zillion wizards which (not
always successfully) strive to hide the complexities from you.  But
if one DOES know COM (or needs to do complex-enough stuff that the
knowledge of COM itself is not optional anyway), Python is better --
because it does _NOT_ strive to hide things behind your back, you are
in far better control -- essentially the same potential for "control
of what's going on" that you get with VC++ and ATL, but without the
horrid complexities thereof.

Like with ATL, though, you do have to study the sources you're supplied;
the docs are not bad, but they never go deep enough into the system's
bowels -- only study of sources can take you there.
[[However, this also applies to theoretically "simple" stuff, as soon as
you need to answer questions that are deep enough in themselves, e.g.,
"if I malloc a zillion byte then free them, will the memory be given
back to the system or will my process keep it to itself for possible
future needs" -- this can be crucial in practice, but only studying
the sources of your C system's runtime libraries will help you answer.]]


Alex






More information about the Python-list mailing list