[C++-sig] Re: Why Python for C++ programmers
Daryl P McDaniel
python at mc2research.org
Mon Jan 6 22:54:13 CET 2003
Greetings,
The Python / C++ relationship is not adversarial; it is complementary. I
think that this is a very important point to get across to a C++ audience.
One can easily prototype in Python then convert to C++. (There are
significant benefits to prototyping in something other than your production
language.) By coupling Python with application specific extension libraries,
in C++, one can produce an application with very good performance while
retaining the benefits (as expressed in the original messages) of Python.
For us, the greatest benefit comes when Python is embedded in our product
(Low-level management firmware for Mainframes). Through the facilities
provided by Boost.Python, all "important" C++ objects are available in the
Python environment. This allows one to easily interract with the system, and
the system objects, for experimentation, development, and debugging. Where
appropriate, portions of the final application that are not time critical can
be written in Python. The breadth of Python library support usually results
in small, easily maintained, modules.
As one who has been programming in C++ daily for about 20 years, my initial
reaction (in a seminar environment) to the phrase "C++ is hard, Python is
easy" would be fairly negative. C++ is harder than Python to use correctly
and fully. That which you know is always easier than that which you don't.
Best of luck on the articles and talks.
Sincerely,
Daryl V. McDaniel python at mc2research.org
Python Evangelist
MC2 Research
Portland, Oregon
On Monday 06 January 2003 09:00 am, Mike Thompson wrote:
> Message: 1
> From: "Mike Thompson" <mike.thompson at day8.com.au>
> To: <c++-sig at python.org>
> Date: Mon, 6 Jan 2003 18:00:00 +1100
> Subject: [C++-sig] Re: Why Python for C++ programmers
> Reply-To: c++-sig at python.org
>
>
> "David Abrahams" <dave at boost-consulting.com> wrote in message
> news:u8yz4qk31.fsf at boost-consulting.com...
>
> > Hi All,
> >
> > I'm starting work on some articles and talks about Boost.Python. Some
> > of these are primarily for a "C++ audience", and I'll have to at least
> > briefly make the case for why a C++ programmer should care about
> > Python. Some of the answers are obvious to me, but I thought I should
> > get additional feedback from a group who must have their own
> > well-thought-out reasons.
> >
> > Here are some things I've thought of.
> >
> > In broad strokes, they're complimentary because:
> >
> > * C++ is hard. Python is easy
> >
> > * C++ is fast. Python is small
> >
> > * C++ is "dangerous" (easy to crash). Python is "safe"
> >
> > * C++ is rigorous. Python is loose.
> >
> > * C++ is compiled. Python is interactive.
> >
> > * C++ has a deep and focused standard library. Python has broad
> > libraries
> >
> > * C++ has limited introspection capability. Everything in Python is
> > introspectable
> >
> > * C++ is supported to varying degrees on different platforms. The
> > latest Python really does run ``everywhere''.
>
> I'm a bit late to this, but my 2c worth is:
>
> C++ is deep. Python is broad.
> C++ is complex. Python is simple.
> C++ is wonderfully fast. Python is mostly fast enough.
> C++ is hard. Python is easy.
> C++ will be portable one day. Python genuinely is already.
> C++ is impressive. Python makes me smile.
> C++'s draws great power from rigidity. Python from flexibility.
> C++ is for large. Python is for small, medium and large.
> C++ is sometimes where I finish. Python is always where I start.
>
> Python and C++ are to my software development as Taxis and Aircraft are to
> my
> business travel. Most times I only need a Taxi. Sometimes I need more than
> that. Even then its the combination of the two that gets me there.
>
> I wouldn't be without either.
>
> -Mike.
>
More information about the Cplusplus-sig
mailing list