HP aC++/HP ANSI C A.06.27 Release Notes

For example:
wchar_t *str1 = L"a" "b"; // Okay, same as L"ab".
wchar_t *str2 = "a" L"b"; // Okay, same as L"ab"
Such constructs were already accepted in C99 and GNU modes.
Rule changes related to determining the type of large literal constants
As in C99, unsuffixed integer literals that do not fit in type long, but can fit in type unsigned
long, are given type long long instead. This might cause certain expressions to differ in values
in C++0x and default C++ compilation modes.
Example for +DD32:
bool b = 4000000000 > -1; // b = true in C++0x mode.
// b = false in default C++ mode with long long enabled.
// (In that case, a warning is issued on the conversion of -1
// to an unsigned type.)
For +DD64, both modes are the same for that literal value.
Variadic macros
With this release, aC++ now accepts C99-style variadic macros in C++0x mode.
Like C99, the special identifier __VA_ARGS__ represents the set of all the arguments passed to the
macro just as they are passed in the variable arguments mechanism for functions.
Example:
# define PRINTF(...) printf (__VA_ARGS__)
int main() {
char* from = "aCC";
PRINTF("Hello, World" " from %s!\n", from);
return 0;
}
// This will print:
// Hello, World from aCC!
_Pragma operator
The _Pragma operator (originally from C99 and already supported in GNU mode), is now
supported in non-strict C++98/C++03 mode and in all C++0x modes.
The operator has the effect of expanding the pragma specified in the string (in double-quotes) in
just the way a #pragma would.
Example:
_Pragma ("pack 1");
struct Packed {
char c;
int i;
};
int main () {
int iPackedSize = sizeof(Packed);
}
extern template
In C++0x mode (that is, with -Ax specified) and in non-strict C++98 mode, extern template
can now be used to suppress the implicit instantiation of an entity.
Traditionally the C++ compiler instantiates a template in each translation unit where it finds a
specification for the same. To suppress this (and thereby reduce the compilation times), C++0x
now provides extern templates. This directs the compiler not to instantiate the template for this
translation unit.
Example:
20 Product changes in earlier versions