How far Watcom C/C++ compiler supports C++

Dear Sir or Madam:

I am working with Watcom C/C++ compiler ver 10.6 and QNX 4.25. Our
software development is going totally towards C++. At the start of a
project in C++, I would like to know the following:

  1. The length to which the Watcom C/C++ compiler 10.6 supports C++.
    Which of the following features it supports?
    a. templates
    b. STL
    c. ATL
    d. Exception Handling

  2. Does it support draft version of C++ or standard version?

  3. Is there Watcom compiler version available which will support
    standard C++ with QNX 4.25?

  4. Is there Watcom compiler version available which will support
    standard C++ with QNX Neutrino?

  5. Do you have a language reference manual for Watcom C/C++ compiler?

Your early response will be highly appreciated.

Babuddin Ahmad
Software Engineer II
Nanogen, Inc.
San Diego, California 92121
Phone: (858) 410-4922
Fax: (858) 410-4848
email: bahmad@nanogen.com

Dear Sir or Madam:

I am working with Watcom C/C++ compiler ver 10.6 and QNX 4.25. Our
software development is going totally towards C++. At the start of a
project in C++, I would like to know the following:

I’ll answer where I can.

  1. The length to which the Watcom C/C++ compiler 10.6 supports C++.
    Which of the following features it supports?
    a. templates
    b. STL
    c. ATL
    d. Exception Handling

a. 10.6 has templates. They are not standard templates (i.e. they are
pre ISO).

b. We have a hacked port of a pre-standard version of the STL - this
isn’t really useful IMO - if it ain’t exactly standard there’s not much
point, and since there never will be a standard compiler for QNX4, it’s
not like your gaining by coding toward the future or anything. It does
have it’s own templated container classes which are slightly amusing.

c. - sorry I don’t know what ATL stands for.

d. 10.6 does support exception handling.

  1. Does it support draft version of C++ or standard version?

I don’t think it is even a draft version (it’s a tweenie I believe). It
definately isn’t standard.

  1. Is there Watcom compiler version available which will support
    standard C++ with QNX 4.25?

No, in fact I don’t believe there is a generally available fully
compliant ISO/IEC 14882-1998 compiler available for any platform, if
you know of one, please provide a pointer (I do expect there should be
one soon, since the standard has been approved for a full 3 years now).

  1. Is there Watcom compiler version available which will support
    standard C++ with QNX Neutrino?

No, on 6.1 (Neutrino) there is g++ which comes closer to the standard,
but only 2.95 is currently available not 3.0 which is better at
standards compliance (although it has other problems I’m told).

  1. Do you have a language reference manual for Watcom C/C++ compiler?

No, I don’t, and I’m pretty sure Watcom never made one (a lot of effort
to produce one when your chasing a moving target). They used to ship
“The C++ programming language” by Bjarn Stroustrup in their docset.

Having said all these bad (but true) things about Watcom 10.6/C++, in
its defence I will say that although it isn’t C++, it is a very fine
compiler of the language known as “Watcom 10.6/C++” (it wouldn’t be too
much of a stretch to say it is the best compiler of Watcom 10.6/C++
:slight_smile:. It is very fast at compiling, and produces efficient code.

Now having said that :slight_smile: I will also say, that one should not be
starting any new projects in QNX 4.25 at this late date. QSSL is going
to stop driver support on QNX 4.2x next year. QNX 6.1 has much brighter
prospects wrt getting a ISO/IEC 14882-1998 compiler pretty soon, and it
has a reasonably usable (i.e. 97% ISO/IEC) compiler right now.

Rennie

I’m adding just a few comments of my own.

“Rennie Allen” <RAllen@csical.com> wrote in message
news:64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com

  1. The length to which the Watcom C/C++ compiler 10.6 supports C++.
    Which of the following features it supports?
    c. ATL
    c. - sorry I don’t know what ATL stands for.

Boy. I’m glad I’m not the only one.


  1. Does it support draft version of C++ or standard version?

I don’t think it is even a draft version (it’s a tweenie I believe). It
definately isn’t standard.

I believe that 10.6 exactly supports the ARM.


  1. Do you have a language reference manual for Watcom C/C++ compiler?

No, I don’t, and I’m pretty sure Watcom never made one (a lot of effort
to produce one when your chasing a moving target). They used to ship
“The C++ programming language” by Bjarn Stroustrup in their docset.

Again, the best language reference for 10.6 is the ARM.


Having said all these bad (but true) things about Watcom 10.6/C++, in
its defence I will say that although it isn’t C++, it is a very fine
compiler of the language known as “Watcom 10.6/C++” (it wouldn’t be too
much of a stretch to say it is the best compiler of Watcom 10.6/C++
:slight_smile:> . It is very fast at compiling, and produces efficient code.

What he said! Watcom was an excellent compiler for QNX V4.
There is an open source version of Watcom in the works. I don’t know it’s
status.


. . . QSSL is going
to stop driver support on QNX 4.2x next year.

Rennie, while this has been painfully obvious for quite some time it has not
been officially stated by QSSL yet. Is this an OFFICIAL QSSL Statement ?


. . . QNX 6.1 has much brighter
prospects wrt getting a ISO/IEC 14882-1998 compiler pretty soon, and it
has a reasonably usable (i.e. 97% ISO/IEC) compiler right now.

True!

“Bill Caroselli (Q-TPS)” <qtps@earthlink.net> wrote in message
news:9m8s9i$mj2$1@inn.qnx.com

I’m adding just a few comments of my own.

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …

  1. The length to which the Watcom C/C++ compiler 10.6 supports C++.
    Which of the following features it supports?
    c. ATL
    c. - sorry I don’t know what ATL stands for.

Boy. I’m glad I’m not the only one.

cut from msdn:

ATL is the Active Template Library, a set of template-based C++ classes with
which you can easily create small, fast Component Object Model (COM)
objects. It has special support for key COM features including: stock
implementations of Unknown, IClassFactory, IClassFactory2 and IDispatch;
dual interfaces; standard COM enumerator interfaces; connection points;
tear-off interfaces; and ActiveX controls.

// wbr

“ian zagorskih” <ianzag@novosoft-us.com> wrote in message
news:9maft9$l4p$1@inn.qnx.com

“Bill Caroselli (Q-TPS)” <> qtps@earthlink.net> > wrote in message
news:9m8s9i$mj2$> 1@inn.qnx.com> …
I’m adding just a few comments of my own.

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …

  1. The length to which the Watcom C/C++ compiler 10.6 supports C++.
    Which of the following features it supports?
    c. ATL
    c. - sorry I don’t know what ATL stands for.

Boy. I’m glad I’m not the only one.


cut from msdn:

MSDN ah, that explains why ATL means nothing to most of us :wink:

I would guess ATL is a windows thing only (ActiveX).

ATL is the Active Template Library, a set of template-based C++ classes
with
which you can easily create small, fast Component Object Model (COM)
objects. It has special support for key COM features including: stock
implementations of Unknown, IClassFactory, IClassFactory2 and IDispatch;
dual interfaces; standard COM enumerator interfaces; connection points;
tear-off interfaces; and ActiveX controls.

// wbr

Bill Caroselli (Q-TPS) wrote in message <9m8s9i$mj2$1@inn.qnx.com>…

I’m adding just a few comments of my own.

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …
5. Do you have a language reference manual for Watcom C/C++ compiler?

No, I don’t, and I’m pretty sure Watcom never made one (a lot of effort
to produce one when your chasing a moving target). They used to ship
“The C++ programming language” by Bjarn Stroustrup in their docset.

Again, the best language reference for 10.6 is the ARM.

Ahh, but there is a language reference in hardcopy. If you can find 10.6
for Windows it might have one in soft copy.

Jay

The Open Watcom web site has a link to the 11.x version of the language
reference. Its not too far off from 10.6.

http://www.openwatcom.org/reference.html

“Jay Hogg” <Jay.Hogg@t-netix.com.r-e-m-o-v-e> wrote in message
news:9mci5j$pmr$1@inn.qnx.com

Bill Caroselli (Q-TPS) wrote in message <9m8s9i$mj2$> 1@inn.qnx.com> >…
I’m adding just a few comments of my own.

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …
5. Do you have a language reference manual for Watcom C/C++ compiler?

No, I don’t, and I’m pretty sure Watcom never made one (a lot of effort
to produce one when your chasing a moving target). They used to ship
“The C++ programming language” by Bjarn Stroustrup in their docset.

Again, the best language reference for 10.6 is the ARM.

Ahh, but there is a language reference in hardcopy. If you can find 10.6
for Windows it might have one in soft copy.

Jay

In article <9mav9r$soa$1@inn.qnx.com>, mcharest@remzinformatic.com
says…

“ian zagorskih” <> ianzag@novosoft-us.com> > wrote in message
news:9maft9$l4p$> 1@inn.qnx.com> …

“Bill Caroselli (Q-TPS)” <> qtps@earthlink.net> > wrote in message
news:9m8s9i$mj2$> 1@inn.qnx.com> …
I’m adding just a few comments of my own.

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …

  1. The length to which the Watcom C/C++ compiler 10.6 supports C++.
    Which of the following features it supports?
    c. ATL
    c. - sorry I don’t know what ATL stands for.

Boy. I’m glad I’m not the only one.


cut from msdn:


MSDN ah, that explains why ATL means nothing to most of us > :wink:

I would guess ATL is a windows thing only (ActiveX).

Having had to write code using DCOM, I used ATL…
ATL is definitely a “Windows thing”!
After Microsoft (or whatever you want to call them) finished it’s initial
support for DCOM, OLE, and related things in the Visual Studio developer
environment, using MFC (Microsift Foundation Classes - also another
“Windows thing” ), they found that they were generating enormous
executables (even for MS) because of all the class code that was being
included. So, they wrote ATL (templates instead) so that these programs
would not be quite so bloated…
(Even MS recognizes that you cannot push up the memory requirements for
programs TOO quickly! :sunglasses:


ATL is the Active Template Library, a set of template-based C++ classes
with
which you can easily create small, fast Component Object Model (COM)
objects. It has special support for key COM features including: stock
implementations of Unknown, IClassFactory, IClassFactory2 and IDispatch;
dual interfaces; standard COM enumerator interfaces; connection points;
tear-off interfaces; and ActiveX controls.

// wbr



\


Stephen Munnings
Software Developer
Corman Technologies Inc.

“Rennie Allen” <RAllen@csical.com> wrote in message
news:64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com

b. We have a hacked port of a pre-standard version of the STL - this
isn’t really useful IMO - if it ain’t exactly standard there’s not much
point, and since there never will be a standard compiler for QNX4, it’s
not like your gaining by coding toward the future or anything. It does
have it’s own templated container classes which are slightly amusing.

We use STLport (www.stlport.org) which is pretty close to the standard (yes
I know Dinkum is better) and is directly usable on virtually every platform.

The version we have works on QNX4 “out of the box” including full support
for Watcom (10.6 and 11.0). It allows us to write code which is portable
between QNX4 and QNX6.1 (Dinkum).

Rob Rutherford

What version of STLPort are you using?

“Robert Rutherford” <ruzz@ruzz.com> wrote in message
news:9mmr28$ak1$1@inn.qnx.com

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …

b. We have a hacked port of a pre-standard version of the STL - this
isn’t really useful IMO - if it ain’t exactly standard there’s not much
point, and since there never will be a standard compiler for QNX4, it’s
not like your gaining by coding toward the future or anything. It does
have it’s own templated container classes which are slightly amusing.

We use STLport (> www.stlport.org> ) which is pretty close to the standard
(yes
I know Dinkum is better) and is directly usable on virtually every
platform.

The version we have works on QNX4 “out of the box” including full support
for Watcom (10.6 and 11.0). It allows us to write code which is portable
between QNX4 and QNX6.1 (Dinkum).

Rob Rutherford

Allowing one to write portable code is one thing, conforming to the
standard is another. I am tired of having code that conforms to the
standard not compile on any platform (6.1 being the source of most
irritation right now - since I don’t even try to write standard C++ on
QNX4 - it is a lost cause).

-----Original Message-----
From: Robert Rutherford [mailto:ruzz@ruzz.com]
Posted At: Thursday, August 30, 2001 6:58 PM
Posted To: devtools
Conversation: How far Watcom C/C++ compiler supports C++
Subject: Re: How far Watcom C/C++ compiler supports C++



“Rennie Allen” <RAllen@csical.com> wrote in message
news:64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com

b. We have a hacked port of a pre-standard version of the STL - this
isn’t really useful IMO - if it ain’t exactly standard there’s not
much
point, and since there never will be a standard compiler for QNX4,
it’s
not like your gaining by coding toward the future or anything. It
does
have it’s own templated container classes which are slightly amusing.

We use STLport (www.stlport.org) which is pretty close to the standard
(yes
I know Dinkum is better) and is directly usable on virtually every
platform.

The version we have works on QNX4 “out of the box” including full
support
for Watcom (10.6 and 11.0). It allows us to write code which is portable
between QNX4 and QNX6.1 (Dinkum).

Rob Rutherford

In article <64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com>,
Rennie Allen <RAllen@csical.com> wrote:

and since there never will be a standard compiler for QNX4, it’s
not like your gaining by coding toward the future or anything.

I’m curious what this means? Because of QNX itself?

  1. Is there Watcom compiler version available which will support
    standard C++ with QNX 4.25?

No, in fact I don’t believe there is a generally available fully
compliant ISO/IEC 14882-1998 compiler available for any platform, if
you know of one, please provide a pointer (I do expect there should be
one soon, since the standard has been approved for a full 3 years now).

You are correct, there is none, yet.

Greg Comeau export ETA: Dec 1 10% “End of Summer” Offer
Comeau C/C++ ONLINE ==> http://www.comeaucomputing.com/tryitout
World Class Compilers: Breathtaking C++, Amazing C99, Fabulous C90.
Comeau C/C++ with Dinkumware’s Libraries… Have you tried it?

I’m curious what this means? Because of QNX itself?

QNX4 has been EOL (end-of-lifed - it is 10 years old now), so I doubt it
would be in anyones interest to invest the resources necessary to
produce an ISO compiler. The current version of QNX is 6.1, which IMO
will have a long and productive future.

We are using version 4.0. It worked out of the box, except I never got
their version of iostreams to compile, so I have __STL_NO_SGI_IOSTREAMS set
to 1, which causes it to “wrap” the existing Watcom iostreams.

Also Watcom doesn’t support default arguments on template classes, so if you
want to use map<>, set<> etc in a “natural” way you want to set
__STL_MINIMUM_DEFAULT_TEMPLATE_PARAMS to 1.

(Both these parameters are in stl_user_config.h)

Rob Rutherford

“Brown, Richard” <brownr@aecl.ca> wrote in message
news:9mnq8b$snk$1@inn.qnx.com

What version of STLPort are you using?

“Robert Rutherford” <> ruzz@ruzz.com> > wrote in message
news:9mmr28$ak1$> 1@inn.qnx.com> …

“Rennie Allen” <> RAllen@csical.com> > wrote in message
news:> 64F00D816A85D51198390050046F80C99F1C@exchangecal.hq.csical.com> …

b. We have a hacked port of a pre-standard version of the STL - this
isn’t really useful IMO - if it ain’t exactly standard there’s not
much
point, and since there never will be a standard compiler for QNX4,
it’s
not like your gaining by coding toward the future or anything. It
does
have it’s own templated container classes which are slightly amusing.

We use STLport (> www.stlport.org> ) which is pretty close to the standard
(yes
I know Dinkum is better) and is directly usable on virtually every
platform.

The version we have works on QNX4 “out of the box” including full
support
for Watcom (10.6 and 11.0). It allows us to write code which is portable
between QNX4 and QNX6.1 (Dinkum).

Rob Rutherford

\