diff --git a/include/qpdf/QPDFObject.hh b/include/qpdf/QPDFObject.hh index 04b859c..343e4e4 100644 --- a/include/qpdf/QPDFObject.hh +++ b/include/qpdf/QPDFObject.hh @@ -23,14 +23,14 @@ #ifndef QPDFOBJECT_OLD_HH #define QPDFOBJECT_OLD_HH -// This file exists so that if anyone still includes -// and has been ignoring the warning, they will get an error. This reduces -// the chances of someone accidentally including the file from an -// installed, old version. The QPDFObject API, which is not part of the -// public API, is defined in QPDFObject_private.hh. Prior to qpdf 11, this -// file was exposed for some constants. This error was introduced in qpdf -// 12. +// Current code should not include . This file exists +// to ensure that code that includes it doesn't accidentally work because +// of an old qpdf installed on the system. Including this file became an +// error with qpdf version 12. The internal QPDFObject API is defined in +// QPDFObject_private.hh, which is not part of the public API. -#error "QPDFObject.hh is no longer a valid QPDF Header file" +// Instead of including this header, include , and +// replace `QPDFObject::ot_` with `::ot_` in your code. +#error "QPDFObject.hh is obsolete; see comments in QPDFObject.hh for details" #endif // QPDFOBJECT_OLD_HH diff --git a/manual/release-notes.rst b/manual/release-notes.rst index 7cb32f8..51fd219 100644 --- a/manual/release-notes.rst +++ b/manual/release-notes.rst @@ -18,7 +18,9 @@ more detail. - The header file ``qpdf/QPDFObject.hh`` now generates an error if included. This is to prevent code that includes it from accidentally working because an old version is installed - somewhere on the system. + somewhere on the system. Instead of including that header, + include ````, and replace ``QPDFObject::ot_`` + with ``::ot_`` in your code. - ``QPDFObjectHandle::replaceOrRemoveKey`` has been removed since it was identical to ``QPDFObjectHandle::replaceKey``.