cv-qualifications when the thrown and caught types are the same

As of z/OS® V1R2 C++ compiler:
  • A temporary copy is thrown rather than the actual object itself.
  • The cv-qualification in the catch clause is not considered when one of the following are true:
    • The type caught is the same (possibly cv-qualified) type as that thrown.
    • The type caught is a reference to the same (possibly cv-qualified) type.
    Note: cv is short form for const/volatile.
  • New casts also throw exceptions.

This is not the case in z/OS V1R1 and earlier C++ compilers. As of z/OS V1R5 C++ compiler, there is no available option to enable pre- z/OS V1R2 behavior.