DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
C++ compatibility issues

UnixWare 2.x source

For UnixWare 2.x, there is no exact source-level compatibility option. This is because

  1. UnixWare 2.0 and 2.1 each have a somewhat different dialect of the language they accept, both different from Cfront, and so it would be a lot of work to provide compatibility with each of them.

  2. Users of UnixWare 2.x may have already had to change their code from the original Cfront versions; they are more likely to be aware of the evolving language rules.

  3. The UnixWare 2.x code base isn't as large as the OpenServer code base.

That being said, it is sometimes possible to use the UDK CC -Xo option on UnixWare 2.x-built code. For instance, the unmodified src.C example above will compile on UnixWare 2.x with default options, and can thus be built on the UDK using CC -Xo.

But for a counter-example, consider this code (that uses the so-called "keyword operators" added by ANSI/ISO):

   int j(int i1, int i2) {
   	return (i1 and i2) xor i2;
   }

This code will not compile under UnixWare 2.0 C++ but will compile under UnixWare 2.1 and UDK C++. However if it is part of a larger code base for which you need the UDK CC -Xo option, it will be rejected, because the keyword operators were not part of the Cfront definition of the language.

So to get existing UnixWare 2.x C++ code to compile under UDK C++, the best approach is to just bite the bullet and change it. The good news is that many of the minor language interpretation issues will already be resolved (since UnixWare 2.x and UDK C++ share the same front end technology).


Next topic: Other C++ compatibility issues
Previous topic: OpenServer C++ source

© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 27 April 2004