# HG changeset patch # User Sebastien Jodogne # Date 1607255274 -3600 # Node ID 85237ae3a0766812133333be27f1a37494be1823 # Parent 93c281752e7a72d9e40224ae2226e904aaae9974 relax CheckOrthancFrameworkSymbols.py about one friend stream function diff -r 93c281752e7a -r 85237ae3a076 OrthancFramework/Resources/CheckOrthancFrameworkSymbols.py --- a/OrthancFramework/Resources/CheckOrthancFrameworkSymbols.py Sun Dec 06 12:21:31 2020 +0100 +++ b/OrthancFramework/Resources/CheckOrthancFrameworkSymbols.py Sun Dec 06 12:47:54 2020 +0100 @@ -251,6 +251,16 @@ elif (i.kind == clang.cindex.CursorKind.TYPEDEF_DECL or # Allow "typedef" i.kind == clang.cindex.CursorKind.ENUM_DECL): # Allow enums pass + + elif i.kind == clang.cindex.CursorKind.FRIEND_DECL: + children = list(i.get_children()) + if (isPublic and + (len(children) != 1 or + not children[0].displayname in [ + # This is supported for ABI compatibility with Orthanc <= 1.8.0 + 'operator<<(std::ostream &, const Orthanc::DicomTag &)', + ])): + raise Exception('Unsupported: %s, %s' % (i.kind, i.location)) else: if isPublic: diff -r 93c281752e7a -r 85237ae3a076 OrthancFramework/Sources/DicomFormat/DicomTag.h --- a/OrthancFramework/Sources/DicomFormat/DicomTag.h Sun Dec 06 12:21:31 2020 +0100 +++ b/OrthancFramework/Sources/DicomFormat/DicomTag.h Sun Dec 06 12:47:54 2020 +0100 @@ -26,6 +26,7 @@ #include #include +#include "../Compatibility.h" #include "../Enumerations.h" namespace Orthanc @@ -73,7 +74,7 @@ DicomModule module); #if ORTHANC_BUILDING_FRAMEWORK_LIBRARY == 1 - ORTHANC_PUBLIC friend std::ostream& operator<< (std::ostream& o, const DicomTag& tag); + ORTHANC_PUBLIC friend std::ostream& operator<< (std::ostream& o, const DicomTag& tag) ORTHANC_DEPRECATED; #endif };