HP aC++/HP C A.06.25 Release Notes
Table Of Contents
- HP aC++/HP ANSI C Release Notes
- Table of Contents
- 1 HP aC++/HP ANSI C Release Notes
- 2 What’s New in This Version
- New Features in Version A.06.25
- C99 default C compilation mode (Changed)
- Full -AA default C++ compilation mode (Changed)
- -Ax option enables support for several C++0x extensions (New)
- C99 features added to C++0x (New)
- extern template
- Decimal Floating Point supported in C++ mode (New)
- #pragma STDC FLOAT_CONST_DECIMAL64 (New)
- #pragma omp task (New)
- #pragma omp taskwait (New)
- Performance enhancements for +O1 (Changed)
- Non-template static data members initialized outside the class no longer treated as constants in strict mode (Changed)
- Enhancements to allow code to run well on current platforms and future multi-core processors (New)
- New diagnostic messages (New)
- Improved diagnostic messages (Changed)
- Enhanced +wendian warnings (New/Changed)
- New runtime abort messages (New)
- New Features in Version A.06.20
- Decimal floating-point arithmetic (HP-UX 11.31 only) (New)
- +annotate=structs (New)
- +check=lock (New)
- +check=thread (New)
- +O[no]autopar now supported in C++ Mode (New)
- +O[no]dynopt (HP-UX 11.31 only) (New)
- +inline_level num (Enhanced)
- -dumpversion (New)
- #include_next (New)
- #pragma diag_push (New)
- #pragma diag_pop (New)
- +Oinlinebudget is deprecated (Change)
- In next release, default C compilation mode will change from C89 to C99
- In next release, default C++ compilation mode will change to full -AA
- New Features in Version A.06.15
- printf, fprintf Optimization (New)
- +Wmacro Option (New)
- +Wcontext_limit Option (New)
- +wperfadvice Option (New)
- +Wv Option (New)
- +wlock Option (New)
- +O[no]autopar Option (New)
- +O[no]loop_block Option (New)
- +O[no]loop_unroll_jam (Default Change)
- +Olit=all (Default Change for HP C)
- +macro_debug= (New)
- +pathtrace (New)
- +check Suboptions (New)
- -Bhidden_def (New)
- -dM (New)
- #pragma OPT_LEVEL INITIAL (New)
- #pragma OPTIMIZE (Deprecated)
- #pragma [NO]INLINE (New for C++ Mode)
- _Asm_ld, _Asm_ldf, _Asm_st, _Asm_stf Intrinsics (New)
- Debugging Code Compiled with Opt Levels above +O1 Is Supported
- __attribute__ ((visibility("default"|"protected"|"hidden"))) Added (New)
- __attribute__ ((warn_unused_result)) Added (New)
- Change in treatment of cv-qualified assignment operators
- New Features in Version A.06.12
- New Features in Version A.06.10
- HP Code Advisor
- +cond_rodata Option (Obsoleted)
- +[no]dep_name Option (New)
- +expand_types_in_diag Option (New)
- +FPmode Option (Enhanced)
- +Ointeger_overflow (Default Changed)
- +Onolibcalls= Option (New)
- +wendian Option (New)
- +wlint Option (Enhanced)
- +wsecurity= Option (Enhanced)
- System-wide Option Configuration
- [NO]PTRS_TO_GLOBALS Pragma
- -AA -D_HP_NONSTD_FAST_IOSTREAM Performance Improvement Macro
- New Function Attributes
- Improved Diagnostics
- C++ Standard Library Change
- Earlier Versions
- New Features in Version A.06.25
- 3 Installation Information
- 4 Compatibility Information
- 5 Known Problems and Workarounds
- Obsolete LANG-STARTUP Files
- codecvt_byname Facet Needed for C Locale Conversions
- Using +check= Options and Running on Test and Deployment Systems
- GPREL22 Relocation Error
- Object Files Generated at +O4 or -ipo
- Incompatibilities Between the Standard C++ Library Ver. 1.2.1 and the Draft Standard
- Conflict Between macros.h and numeric_limits Class (min and max)
- Known Limitations
- 6 Related Documentation
C++0x relaxes that restriction to allow such names as an unevaluated operand, such
as sizeof(X::m), typeid(X::m), and decltype(X::m). With this release, aC++
now accepts this usage in C++0x mode and non-strict C++98/03 mode; such references
are transformed into a compiler-generated member-access expression using 0 cast to
the appropriate type as the object pointer.
As an extension, these references are also accepted as subexpressions of unevaluated
operands, such as sizeof(X::arr[0]), even in strict C++0x mode.
Defaulted and deleted functions
Deleted functions (= delete;) and defaulted special member functions (= default;)
are now supported.
A deleted function is a function declaration that cannot be referenced.
For example:
int f(int) = delete;
short f(short);
int x = f(3); // Error: selected function is deleted.
int y = f((short)3); // Okay.
Special member functions that can be implicitly defined can instead be explicitly
declared, but with a default definition. As the following example shows, the default
definition can be specified inside or outside the enclosing class definition, but only if
it appears inside the class can that class be a POD type (if all other constraints for POD
types are fulfilled):
struct S { S(S const&) = default; };
struct T { T(T const&); };
T::T(T const&) = default;
In C++0x mode, auto is always a type specifier, not a storage-class specifier
The traditional meaning of auto as a storage class specifier is no longer enabled. auto
is therefore always a type specifier in C++0x mode. It is used for automatic type
deduction; when used in a declaration, it makes the type of the thing declared the same
as the type of whatever initialized it. For example:
typedef int T;
int x;
void f() {
auto T(x); // This is now the declaration of a variable T
// initialized with x (and hence of the same type as x).
// Previously, it was the declaration of a variable x of type T.
auto int y; // Now an error: Multiple type specifiers.}
Lambdas
Lambda functions are now supported.
A lambda expression is an anonymous function object containing a code snippet (for
example, predicate logic) that can be specified very succinctly by the programmer
without having to declare a function-local class; it is also referred to as closure because
New Features in Version A.06.25 13