Re: C++?

From: Paul Hepworth <paul1+vsta_at_nospam.org>
Date: Tue Feb 24 2004 - 15:58:00 PST

"Andy Valencia From:" <vandys@vsta.org> wrote in message
news:c1gb1n$ni1$1@vsta.org...
> No C++. While I support almost any kind of hacking, I'm pretty reluctant
> to fill the C header files with all the garbage needed to placate a C++
> compiler. It's like insult to injury that a crummy language insists on
> putting its fingerprints all over another language's header files.

It should be possible to put all the C++ fingerprints in the C++-specific
header wrappers. (A c++ program should include <cstdio> rather than
<stdio.h>, for example.) If a c++ program includes a c .h file that doesn't
have the requisit extern "C" and such, the compiler will complain, and the
include can be changed to include a wrapped header instead.
(Indeed, it is not that C++ "insists on putting its fingerprints on another
language's header files"; rather, C++ has its own header files that have
additional fingerprints. The fact that one can make C++'s header files also
work with C (or vice-versa) is a benefit to an implementor of both
languages/libraries (though not to an implementor of just C or even just
C++). The alternative is to provide disjoint sets of headers, as is done
with many other languages to provide "bindings" to libraries written in
other languages.)

> As I said, I look on hacking--any hacking (no, not the illegal activity
> which has preempted an old and honorable name)--as excellent. That said,
> if I was nudging somebody to port an OO language, my first choice would
> be Squeak, and my second would be Java. FWIW. Squeak+svgalib would be
> pretty cool...

I'm not familiar with Squeak. I'll have to read up on it a bit. There is
Python already, of course (though it would be nice to update that to 2.x
before doing much substantial development in Python).

But my motivation for porting a language is for porting stuff already
developed in that language, for example FLTK and FTE, which are written in
C++. (FLTK because it provides a very good widget set and even a decent HTML
browser.)

Hmm. Perhaps TCL/Tk (for Tk really (PyTk especially)) would be a reasonable
port.

Paul
Received on Tue, 24 Feb 2004 16:58:00 -0700

This archive was generated by hypermail 2.1.8 : Tue Sep 26 2006 - 09:03:08 PDT