Comeau's C++ FAQ

Comeau Computing/Comeau C++ FAQ

  1. Can you tell me something about Comeau Computing?
  2. What is Comeau's involvement in C++ history?
  3. How does Comeau C++ alleviate transitions?
  4. Where does Comeau C++ 4.3.3 fit into the big picture?
  5. What does the Comeau C++ package include?
  6. Can Comeau C++ run on any computer system?
  7. Will Comeau C++ be ported to other systems?
  8. How much does technical support cost?
  9. How much does Comeau C++ 4.3.3 cost?
  10. Can you tell me more about C Compiler Support?

General C++ FAQ

  1. What exactly is C++?
  2. Can you tell me more about the "better C" features?
  3. Exactly what are some of the "better C" features?
  4. What else does C++ offer?
  5. Given these features, what can one do with C++?
  6. How does C++ interact with the real world?
  7. Aren't object-oriented languages slow?
  8. What kind of problems does C++ solve?
  9. Is there any hard evidence that C++ works in the real world?
  10. What types of applications are written in C++?
  11. Do you have a question to add?

Can you tell me something about Comeau Computing?

Comeau Computing is a highly visible software development firm offering various programmer tools and services. Our flagship product is Comeau C++TM, a high quality, low cost C++ solution available on multiple platforms, from the smallest PC to the largest supercomputer, allowing you to protect your investment.

Comeau Computing formed in 1985 as a privately held consulting firm specializing in UNIX and C projects. In 1987, the company entered the UNIX commercial software world as developers in Comeau's engineering department devised various programmer tools. For instance, in addition to Comeau C++, another such tool, CCshTM, a UNIX Bourne shell compiler, has been ported to dozens and dozens of platforms by Comeau engineers. Today, CCsh tries to be fully UNIX System V shell compliant and is still being ported to a diverse group of platforms whether a PC running LINUX, or an Amdahl mainframe running UNIX System V Release 4.

The CEO of Comeau Computing, Greg Comeau, is a multi-faceted individual. In addition to leading his company through the 90's, Greg also maintains extremely high visibility as an internationally renowned expert in C++, C, and UNIX. Greg has written may definitive articles in these areas for a host of magazines. He lectures extensively at conferences, colleges, user groups, professional seminars, corporate consulting and panel discussions. Greg is also well known on a host of information services and the Internet where he meticulously avails his expertise to literally thousands of UNIX, Windows, C and C++ programmers in an unbiased and devoted manner. Greg's diversity and energy reflects extensively on Comeau Computing and its staff.

Back to Top

What is Comeau's involvement in C++ history?

AT&T, through Bjarne Stroustrup's innovation and language design, created C++. It was his language and so he specified many of the various earlier versions of C++. This occurred in-house for the most part. In the mid-80's, AT&T released an implementation of C++ to the public.

Soon thereafter, during the 1988 time-frame, Comeau engineers began experimenting with C++ in-house. Within a short period of time, Comeau engineers realized that various things in C++ were beneficial over C, while at the same time realizing that nothing from C was lost. After that positive in-house research, Comeau decided that C++ was viable technology and decided to sell C++.

Beginning January, 1989, we began selling Comeau C++ Version 1.2.1 (this version added pointers to members and protected members, new features at the time). The initial platforms supported were XENIX 286, Microport 286, Interactive 386/ix and the AT&T UNIX PC 3B1. As word spread among Comeau customers and the C++ community that a robust, low-cost C++ was available for these platforms, they began to request that it be made available to them, and that we port it onto additional platforms.

Excitement continued to grow. In the summer of 1989, Comeau made a firm commitment to C++. Comeau's leadership role since that point has been unprecedented. AT&T continued with C++ 2.0, with new C++ features, and Comeau kept in close proximity. Comeau C++ Version 2.0, the first 2.0 compatible C++ on the market (supporting multiple inheritance, abstract base classes, etc), was released in early August 1989. Additional UNIX ports were added including XENIX 386, all known UNIX 386's, LYNX/OS 386, the AT&T 3B2, as well as MS-DOS.

In May 1990, Comeau C++ 2.1 was released. This product was the first 2.1 compatible C++ on the market (supporting more new AT&T features such as type safe linkage, nested classes, etc) and remained in such a position for close to one year. By this time, the ANSI C++ committee had formed and Comeau C++ 2.1 offered the most ANSI C++ support for that early specification of the language. On most platforms, Comeau C++ remained the only 2.1 C++ even after almost two years.

Continuing our major commitment to C++, with the superior and welcomed technology of Comeau C++, additional ports took place to still more platforms including the IBM RS/6000 running AIX and Sun 3 running SunOS. Early during this period, Comeau Computing became a founding, attending and voting member of X3J16, the ANSI C++ Committee (and we have remained an attending/voting member ever since).

Comeau's unsurpassed leadership in the C++ community was most notably recognized when we began breaking totally new ground by porting to so-called proprietary platforms. It was considered impossible by many at the time, but we provided ports to such platforms as Data General's AOS/VS, Commodore's Amiga AMIX SVR4, Commodore's AmigaDOS and the Atari ST. Those ports also further emphasized Comeau's multi-platform, multi-operating system capabilities. To our credit, our own success immensely increased our porting savvy. During this period, Comeau Computing also became a founding member of the C++ Resellers Alliance.

Continuing this tradition of being the most up-to-date and most available C++, Comeau C++ 3.0 With Templates was announced in February 1992. Additional ports such as the Sun 4/Sun SPARC running SunOs and a plethora of UNIX SVR4's were made available. Not only was Comeau C++ the only C++ available on some platforms, but it was at the time the only multi-platformed compiler supporting templates.

During 1993, 3.0.1 upgrades for the SPARC and various UNIX SVR4s were released. Similarly, a new port to the COHERENT operating system took place. During 1994, new 3.0.1 ports to Solaris 2, HP9000, a new COHERENT OS (it was binary compatible with some real PC UNIX's) and also to an early version of LINUX took place, as well as more 3.0.1 upgrades to existing platforms.

For the next 4 years, we became focused on educating "the masses". We taught many of our own training seminars as well as speaking at conferences. We also moved away from more generally available ports and into proprietary ports. That is to say, this group of ports would not have made sense to be made generally available given their nature, and further, we were contractually obligated not to make some generally available by some special customers. We also experimented in ports to a number of hopeful operating systems at the time but never released those ports (MINIX, XINU, OS/2, etc) though there were completely functional.

Around this time, it became clear that Comeau C++ needed to be rewritten. Not only were some parts modified extensively, but new language features were added by the ANSI/ISO C++ committee such as namespaces, a modified template specification, the way some names were looked up, etc. When those features stabilized in the committee, they would need to be incorporated. This was also around the time period where Sun Microsystem's marketing machine really "did a number" on the industry regarding the marvels of Java. It was time to make a break.

In January 1998, a totally new source base for Comeau C++, version 4.0, based upon EDG, came into being. This added namespaces, run time type identification, exception handling, enhanced templates, bool, new style casts, etc.. Moreover, even though we were on the cutting edge, we could not discard that every effort needed to be made to ensure that core C++ features (those up to at least 2.1) worked and worked well, including various cfront compatibility modes. Our 4.0 did that "like a champ".

Since then, at the end of 1998, we upgraded to Comeau C++ 4.2.38 which included many new template features added by the committee including partial specialization, partial ordering, explicit specification, explicit instantiation, typename, extensive deduction, member templates, etc.

Another upgrade, Comeau C++ 4.2.42, was released in November 1999 and included so-called "Koenig lookup" for functions, covariant virtual return types, class name injection, function-try-blocks, etc. as well as a huge number of compatibilities with the Microsoft compiler. A new port to NetBSD was also made available. It was at this time that we also broke new ground and made Comeau C++ available online through the web at http://www.comeaucomputing.com/tryitout

In early 2000, Comeau C++ 4.2.43 was made available for some platforms, and in August 2000, a beta of Comeau C++ 4.2.44 was released; it offered optimizations and quality of implementation issues, various compatibilities with the Sun and gnu compilers, as well as numerous language features such as Koenig lookup for templates, two-phased name binding, etc. As 2000 proceeded, `template template parameters' (actually passing a template to a template) was released (leaving just the export keyword as the only major feature to implement) and various other work was underway by Comeau engineers in numerous areas including porting Comeau C++ to various embedded systems. We also began releasing betas of libcomo, derived from SGI's PD Standard Library, for use with Comeau C++ on many platforms.

In very early 2001, we released Comeau C++ 4.2.45.2 as well as completing ports of libcomo to all our generally available platforms. This release supported most C99 features too (C99 is the new revision to C since October 1999 -- don't forget, Comeau C++ is also Comeau C too). Comeau C already supported designated initializers, compound literals, variadic macros, VLAs (variable length arrays), and restrict. This release also added support for flex array members, boolean types, __func__, long long, inline, STDC pragmas, complex and imaginary numbers, C++ style for loops, C++ style comments, C++ style mixed decls and code, universal character names, va_copy, hex floating point constants, etc. This release also added more Microsoft compatibilities.

In mid-2001, Dinkumware released their C++, their C99, and their C90 libraries for use with Comeau C/C++ on LINUX/Intel platforms as well as for Solaris/SPARC. In August 2002, Dinkumware also made a similar release of their libraries for use with Comeau C/C++ on MS-Windows.

In August 2002, Comeau C++ 4.3.0 was released, offering full core language support for Standard C++! The first compiler to do so! Yes, this means Comeau C++ includes everything: partial specialization, Koenig lookup, even export, etc. Comeau C/C++ 4.3.0 even included all the core language Defect Reports accepted by the C++ committee as "TC1". This means Comeau C/C++ already support the core language of the upcoming C++03 revised version of Standard C++. Our features list is extensive and Comeau C++ is now core language compliant. Of course, as usual, this is so without sacrificing our continued commitment to stability or robustness.

Comeau C/C++ 4.3.0 also included:

  • Many new ease of use capabilities.
  • The Windows port of 4.3.0 included support for numerous additional back end C compilers, including VC++ 7.0, Borland, MinGW, lcc-win32, Metrowerks and DigitalMars.
  • A new gcc compatibility mode under LINUX.

Version 4.3.1, released April 2003 included a new g++ compatibility mode under LINUX.

4.3.2, released during summer 2003, included more g++ mode enhancements.

4.3.3, released during January 2004, included support for C++03, extended capabilities for -M command line option to support "makefile dependency" generation, IA-64 ABI support under LINUX, and for MS-Windows the support of VC++ 7.1, BCB 6 (bcc32 version 5.6.x), and the --dinkumware option to directly integrate Dinkumware libs. We also re-released Comeau C++ for UNIXWARE.

Most of the months from mid-2004 through 2008 were spent almost exclusively on more proprietary ports and projects. For instance, we worked with hardware manufacturers, cell phone vendors and 3rd parties to support C++ apps on their cell phones, set top boxes, embedded devices, embedded LINUX, custom libraries and specialized applications. In other cases we added language extensions to support vertical market needs, for instance, security. During that timeframe, we celebrated our 20th year! While other compiler companies have gone out of business, we are still a beacon, having survived initial growth, diverse world changes, local economies, the .com bubble, technical craziness, etc. During this timeframe, internal releases of Comeau C++ proceeded from 4.3.4 through 4.3.10 and those versions were provided in custom ports, while the stablity of 4.3.3 versions upheld our out-of-the-box releases.

As 2008 ends, our plans include a bunch of new generally available ports to yet even more popular platforms. For instance, Comeau C++ 4.3.10.1 will support MinGW gcc 3.4.5 as well as VC++ 8.0 and VC++ 9.0 under Windows. Comeau C++ will also be available on OS X, for both PPC Macs and Intel Macs. We have also completed some custom ports for various ARM platforms, including ADS 1.2, CodeSourcery gcc 4.2.3 and DevKitARM gcc 4.3.0. Watch our main web page for details. And don't ever hesitate to email us about a port to a new platform. Chances are good we can provide it on schedule and at a fair price!

We will continue supporting new C++ and C features, as the respective committees make stable progress.

As you can see we have been busy chiseling away on a constant basis breaking new ground and paths for the industry at large. We are proud of our involvement in the growth of C++ over the past decades. Comeau remains committed to C++, C, UNIX and object-oriented technology in the international marketplace. New research into, and subsequent releases of, additional products will allow us to continue to be a world leader in these areas.

The commitment of Comeau Computing to our customer base is first and foremost. We strive to provide the lowest-priced, most robust, most compliant, and most flexible compilers in the industry. Not only are customers offered the opportunity to access top-notch Comeau technology, but they are also assured protection in their investment from the beginning. Comeau C++ is shipped electronically in most cases. Free life-time technical support is provided via email. And time after time after time, free upgrades are often provided (customers since 1997 have received free upgrades). And as always, customers know that Comeau will remain in the forefront of C++ evolution.

Back to Top

How does Comeau C++ alleviate transitions?

Comeau C++ is especially designed with cross platform and cross operating system capabilities in mind. Consistency across implementations is of the utmost importance. Previous versions of Comeau C++ supported MS-DOS, MS-Windows, all UNIX 386's, SCO UNIX 386, SCO XENIX 386, SVR4, the AT&T 3B2, AmigaDOS, AT&T UNIX PC 7300 & 3B1, the Sun-3, the SUN SPARC, the IBM RS/6000 AIX, the HP9000, Solaris 2, LINUX, Atari ST, MS-Windows, and OS/2. Etc.

In general, C++ provides a bridge for C programmers to enter object-oriented programming and obtain other serious improvements. Comeau C++ 4.3.3 provides another bridge to allow C programmers access to this technology and to increase their productivity. Comeau C++ 4.3.3's strong efforts to be near compatible with Standard C and Standard C++ is a stepping-stone toward this goal. C++ programmers gain the ability to express their algorithms in a more natural manner while retaining the efficiency of C. Furthermore, C programmers can move to C++ without having their code break and they can learn Comeau C++ in a multi-tiered transition (one tier might involve starting new C++ers using the C++ Standard Library immediately, another might consider core language difference such as the bool type, another investigating classes and templates, and so on).

Back to Top

Where does Comeau C++ 4.3.3 fit into the big picture?

The diversity explained above has been an important concern to our user base. They want to develop source code here and then go use it there. They want to specify generic interfaces to ensure portability. They need compilers on their target machines. They want to be assured that what worked on the source machine will work on the target with no hassles or strings attached. We address these considerations, backed up by our porting savvy, up to date features, robust and solid implementation, overall high quality, superior tech support, and often free upgrades. This is always reinforced by our knowledgeable, friendly and helpful technical support through email.

Back to Top

What does the Comeau C++ package include?

"Out of the box" (we ship electronically) for most platforms, Comeau C++ includes the C++ compiler binary, a "compiler helper" runtime library and their respective include files, and some helper tools for use during the compilation process. It also includes the C++ 4.3.3 Reference Manual which is available online. Electronic shipping is free as well as lifetime tech support.
Back to Top

Can Comeau C++ run on any computer system?

Just about! Comeau C++ is the world's most widely ported commercial C++. Recent ports of Comeau C++ currently run on all UNIX 386's (Interactive Systems, INTEL, Bell Technologies, Everex ENIX, ESIX, AT&T 6386, SCO UNIX, UNISYS 6000 Model 3x & 5x, VenturCom VENIX, Dell, Microport, Toshiba), XENIX 386 (version 2.3.1 and above), Sun Solaris/SPARC, LINUX, MS-Windows, and others. Our porting savvy cannot be beat, so contact us about new ports.
Back to Top

Will Comeau C++ be ported to other systems?

Yes, we are always performing ports to new platforms. Email us for a current list of machines or to ask for a port. We are more than happy to review your considerations. Don't hesitate to bring forward embedded systems ports.
Back to Top

How much does technical support cost?

Nothing! Tech support is obtained free of charge to licensed and registered customers. This is not a 30 day or yearly service, but one that's available for as long as you use the product! Our support is through email. Unlike other companies who use email as a black hole, we use it is a vital medium. Also do note that often many upgrades are free. For instance, 4.2.38 upgrades to 4.2.42 were free.
Back to Top

How much does Comeau C++ 4.3.3 cost?

Comeau C++ for all our generally available platforms costs $50. This includes UNIX 386, SCO, MS-Windows 95+, LINUX/ELF, SunOS 4.1.x, Solaris/SPARC. If you have a need for a proprietary port or a port which we won't generally make available, please contact us for pricing. Check out our licensing agreement for licensing details. Note that all orders are prepaid. Most major credit cards accepted. To order, use our order worksheet in FORMS or HTML or ASCII.
Back to Top

Can you tell me more about C Compiler support?

Comeau C++ 4.3.3 is a full and true compiler that performs full syntax checking, full semantic checking, full error checking and all other compiler duties. Input C++ code is translated into internal compiler trees and symbol tables looking nothing like C++ or C. As well, it generates an internal proprietary intermediate form. But instead of using a proprietary back end code generator, Comeau C++ 4.3.3 generates C code as its output. Besides the technical advantages of C++, the C generating aspects of products like Comeau C++ 4.3.3 have been touted as a reason for C++'s success since it was able to be brought to a large number of platforms due to the common availability of C compilers.

The C compiler is used merely and only for the sake of obtaining native code generation. This means that Comeau C++ is tailored for use with specific C compilers on each respective platform. Please note that it is a requirement that tailoring must be done by Comeau. Otherwise, the generated C code is meaningless as it is tied to a specific platform (where platform includes at least the CPU, OS, and C compiler) and furthermore, the generated C code is not standalone. Therefore, it cannot be used by itself (note that this is both a technical and legal requirement when using Comeau C++), and this is why there is not normally an option to see the generated C code: it's almost always unhelpful and the compile process, including its generation, should be considered as internal phases of translation.

Back to Top

What exactly is C++?

It is often said that C++ is C with object-oriented (aka OO) extensions. But C++ is much more than that. Yes, C++ is a near proper superset of C. And yes, it supports OO. However, more importantly, C++ supports multi-paradigmed programming, not just OO. Of these paradigms are numerous styles such as traditional C, "better C", as well as natural features to support so-called data hiding, data abstraction, object oriented programming, generic programming and exception handling.

Unlike many languages, an interesting facet of C++ is that no one style is forced upon you. Furthermore, styles can be combined to match the problem at hand, which is as it should be.

Note that C++ is not a second language independent of C, but instead it is a true hybrid graft atop of ANSI C. For instance, all the examples in The C Programming Language 2nd ed, written by the inventors of C, Kernighan and Ritchie, can be compiled by a C++ compiler. In fact, a C++ compiler was the primary compiler used (yes, even though this was a book on C!!).

Back to Top

Can you tell me more about the "better C" features?

Most C programmers understand the power of C: It is relatively portable, efficient, and low-level with superb capability for controlling the execution of a program with few surprises and little "machinery" behind it. However, programming is often a nightmare in C. It has loose type checking, an ugly/terse syntax, and there is the ability to easily fall into traps in C, many involving an unwieldy pointer.

As it turns out, although C allows you to get dirty and hug the hardware, it keeps you there. You are left with only minimal features in C to directly support abstraction and encapsulation. Although some C code may contain common coding idioms (like while ((c = getchar()) != EOF)), your C code will contain few higher level techniques. This is reinforced by the so-called "Spirit of C", which follows these tenets:

  • Trust the programmer.
  • Don't prevent the programmer from doing what needs to be done.
  • Keep the language small and simple.
  • Provide only one way to do an operation.
  • Make it fast, even if it is not guaranteed to be portable

Although these tenets and C's low level'ness is important, they should not have to mean that higher techniques don't need to be be a focus. Such techniques are often the crux of the matter. It's not good enough then that you can write "any program" in C. Programming is hard. It also depends upon a cognitive human involvement. You want something able to model that involvement. You want something that can process the concepts in an organized manner. The difference between the mapping of the so-called conceptual view of the program (the one in your head if you will) and the literal software view (the program itself) should be kept as small as possible.

Language features are not provided for their syntax alone. Some features should also model and map cognitive and design consideration, automate programming housekeeping issues, etc. But the few features provided by C are indirect, hence fostering elaborate and awkward code construction. For instance, C only supports the static keyword, pointers to functions, typedefing, lots of switch/case statements, and lots of preprocessor macro hackery. These things can only go so far, especially when you consider that things like function prototypes are not required by C, or that organizational aspects such as modules (or whatever you want to call them) are mostly up to the whim of the programmer. This begs for expert and disciplined programmers.

While still remaining compatible with C, one can addresses and solve these problems and limitations, and more, with C++. Not only does C++ result in complete major pure extensions to C such as classes and templates, but also differences to C's type system and other new features.

Back to Top

Exactly what are some of the "better C" features?

Some of the better C features of C++ are:
  • strong type checking (way beyond normal C -- many unrequired C warnings are errors in C++),
  • full function prototyping (C does not require this!!),
  • inline functions (instead of using macros without type checking and/or with side-effects),
  • function overloading (so coders don't need to be concerned about creating funny names for functions which perform similar tasks),
  • const (C borrowed const from C++ but didn't take all of its meaning, in C++ it can be a true named constant for instance)
  • references (allowing call by value and call by reference),
  • new slash-slash comment style ('//'),
  • new types (for instance bool)
  • memory management (allocation by raw bytes is chance'y in C, instead use the C++ new operator which considers allocation and object birth by type, and in one step)
  • non-constant static initializers (this and many C++ features avoid error-prone housekeeping/maintenance issues)
  • less dependency on the preprocessor (it's a second language with its own rules/scopes/etc intertwined with C, instead C++ offers inline, const, etc, as alternatives)
  • The struct keyword is not as necessary (A struct is a class in C++, so it's a type, so it's usually not needed except for the definition of the struct. Not only does this reduce the superfluous necessity to use struct so often in C, but it also addresses superfluous techniques such as having to follow a struct by a typedef.)
  • local declarations are allowed in more contexts (C only allows them at the top of blocks, but that creates a syntactic gap, whereas in some cases, declaring the identifier closer to its use is more appropriate)
  • implicit uses of int are not allowed (this, and many other such rules, closes up something that's clearly sloppy coding)
  • new character types, etc (to allow for internationalization issues)
  • type-safe I/O (printf and friends are error-prone)
  • type-safe linkage (allowing external objects across source files to be checked)
  • plus many more features
Some of these features were so good that even ANSI C borrowed many of them! Furthermore, the next revision of C, so-called C9X, is borrowing even more features. Note too that many of these features are important building blocks when using classes and other more major features of C++.
Back to Top

What else does C++ offer?

In addition to C++'s "better C" capabilities, C++ supports numerous programming paradigms including data abstraction, data hiding, and OOP (object-oriented programming). It does this via the concept of class, which is a superset of C's struct. Using class allows both data and functions (the operations allowed for that data) to be encapsulated in a well defined construct. This allows for user-defined data types to be created in C++ that can be used as naturally as built-in types. A complex number class, or a window class, is an easily understood example. Programs can therefore be written in an organized manner.

Furthermore, in order for C++ modeling capabilities to be more complete, the ability to express relationships such as inheritance is allowed in various flavors depending upon what it is that you are trying to accomplish. As well, polymorphism (the ability to determine at run time what function is being called upon an object, especially those function with the same interface) is allowed as a cornerstone of OO.

Another paradigm includes generic programming, through templates. In short, they allow programmers to generate types. This is important because the significance is that it allows programmers to express another type of relationship that classes do not express. Classes are often used to express a relationship up and down an inheritance hierarchy, but templates are used to express relationships across a family of entities, classes and functions alike.

C++ also supports a general purpose exception handling model, namespaces (an organizational mechanism to modularly contain the use of global names), run time type identification, etc.

No discussion of C++ would be complete without mentioning the depth of the Standard C++ Library. Not only does it support all of Standard C's library, but it also supports a rich and extensible framework of data structures and algorithms, its own I/O mechanism (iostreams) and various string and numerical class data types, internationalization, memory management, etc.

Back to Top

Given these features, what can one do with C++?

Earlier in this faq, we offered some tenets about the "Spirit of C". Similarly, there are some tenets under the auspices of the so-called "Spirit of C++":
  • Be as close as possible to C, but no closer (C, and its tenets don't and shouldn't go away)
  • "Hugging the hardware" is important, so is "Aiding the Algorithm"
  • C++ is a dialect of C with modern software enhancements
  • Although a larger language than C, you don't pay for what you don't use (so size and space penalties are kept to a minimum, and those that do exist must be put in perspective since what needs to be compared is equivalent programs, not feature X vs feature Y)
  • Catch as many errors at compile time as possible
  • Avoid the preprocessor when possible (inline, const, templates, etc are the way to go in most cases)

Using the power of class, you can perform activities such as creating your own user defined types, which supports localization and encapsulation. Details include things such as: constructors and destructors (allows initialization and cleanup of instances of variables, and conversion from any type to another in an automated fashion), operator overloading (allows C operators to be used with user defined types), plus many more features for an enhanced programming experience.

C++'s natural support for OOP is also important. OOP is based on abstraction, inheritance (the ability to derive a new class from a previous one), and polymorphism (the ability of an executing program to dynamically bind a specific operation on a type without requiring knowledge of which operation to perform until run-time). These features can support code re-use and faster program development resulting in both cheaper and more practical programming in some cases. The development cycle is often redistributed with larger up front costs in the short term that are able to be amortized efficiently in the long term.

Back to Top

How does C++ interact with the real world?

Real world problems are often complex and often span a diverse and broad spectrum of areas. C++ allows you to span this spectrum. Other procedural and OOP languages don't do this and instead will often even straight-jacket you into a specific mentality or solution. Furthermore, C++ doesn't force you to do it in one particular way, which may be awkward many times and in fact wrong other times.

For instance, although object oriented capabilities are good to have, every problem does not need such an OO solution. Some languages which support OOP tend to box you into a corner and force you to use inappropriate features anyway. Solutions should be matched to their problems. Claiming otherwise is seriously misguided. C++ allows for generality. Therefore, you can take efficient advantage of aspects like OOP to naturally support the construction of your algorithms, while at the same time be able to drop down into C and "get dirty" if you need to. C++ has been termed the perfect hybrid numerous times.

Back to Top

Are all object-oriented languages slow?

Typical implementations of object-oriented languages are often slow. However, there is nothing inherent in OOP per se that requires this to be. On average, a C++ program is just as fast or slow as its C counterpart. Think about this carefully. Since C++ has strong typing it takes full advantages of the static binding of names and therefore, even when using OOP features, there is very little penalty involved, if any in some cases. Add to this issues like inline functions, and the general point that you do not pay for features that you don't use, then any real world C++ applications are sitting rather pretty.
Back to Top

What kind of problems does C++ solve?

Many. Our customer base ranges from students to consultants to small businesses all the way up to global conglomerates and governments. Our installed base uses C++ for many applications ranging from embedded systems, GUI's, databases, and operating systems, all the way over to all aspects of business and financial programming. They also take advantage of C++ in both large and small programs. Each customer seems to have their own niche market, illustrating C++'s diversity and flexibility to conform to real world programming.
Back to Top

Is there any hard evidence that C++ works in the real world?

C++ is now a mature, stable and standard language. It is estimated to have millions of programmers and an economic impact in the billions of dollars.

In the cover article of the May 3, 1999 edition of Software Success magazine (Vol 13, No 17), the question of "Which software R&D skills should you fight for?" was considered. CEOs ranked each skill or experience with the #1 or #2 highest value to their companies. The highest percent skill CEOs sought was for C++, at 42.6%. Runners up include Object-oriented design 31.1%, Win NT 26.2%, Visual Basic 23.8%, GUI design 22.1%, SQL server 16.4%, UNIX 15.6%, Oracle 12.3%, Sybase 10.7%, Java 9.8%, Web design or HTML 9.0%, SAP 3.3%, Delphi 3.3%, and Visual FoxPro 2.5%. For more info contact them.

Case studies and white papers are always being presented at most conferences, user groups, magazines and web sites. Major corporations are using C++ for countless projects. Whether via small teams or hundreds of programmers in multi-million line applications, these projects are being successfully written and maintained.

The C++ committee is supported by many companies including giants such as AT&T, Sun Microsystems, IBM, HP, TI, Microsoft, Apple, Siemens, Intel, Motorola, Data General, Merrill Lynch, Boeing, etc. This has resulted in expenses in the millions to specify. It has also resulted in that C++ implementations and libraries are widely available.

Back to Top

What types of applications are written in C++?

C++ is a general purpose high level language. It is a notational vehicle useful for modeling, expressing, and communicating entities such as concepts, algorithms, and relationships. It has been used in many, many, many industries. In The Design and Evolution of C++ by Bjarne Stroustrup, he begins his book by writing:
"C++ was designed to provide Simula's facility for program organization together with C's efficiency and flexibility .... It succeeded."
A sample list of significant applications/uses follows (using a very rough grouping):
  • telecommunications/networking,
  • systems programming/operating systems/compilers/software tools/wacky hardware,
  • business systems/databases/billing/payroll/employee,
  • banking/stock exchanges/financials/numerical,
  • popular "off-the-shelf" software products,
  • general applications programming,
  • robotics/industrial/machine control,
  • graphics/CAD/CAM/GUIs/multi-media/animation,
  • embedded systems,
  • real time data gathering,
  • devices, hand-held and otherwise (cameras, telephony, remotes, microwaves, etc),
  • medical/hospital/imaging,
  • simulations/games/videos/virtual reality,
  • many language binding are available for C++ (for instance SOM, OLE, CORBA)
  • the "engines" and guts of many products are written in C++
  • etc.
The multi-paradigmed capabilities of C++ is able to allow for this huge span. C++ is effective and at the benefit of the bottomless pit of libraries available and still to be written. So, not only is C++ general purpose, but it is multi-purpose.
Back to Top

Do you have a question to add?

Do not hesitate to email us if you have any other questions or concerns you would like to see covered.
Back to Top

Comeau Computing.
Copyright © Comeau Computing. All rights reserved.
Revised: July, 2013.