Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-990

Inline namespaces confuse the generator

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Not Evaluated
    • None
    • 5.12.0
    • Shiboken
    • None
    • All
    • 44729f5c176e2585f00b6fefacffa7830b1e9f22 (pyside/pyside-setup/5.15)

    Description

      I am trying to wrap parts of the libstd++, and am having issues with the use of inline namespaces. As an example, the std::error_category in current stdlibs is actually defined as std::_V2::error_category, where _V2 is an inline namespace.

      Shiboken will generate names including the V2 namespace, and ignore types "coming in" as std::error_category. Also typedefing or similar won't work as those types are actually identical.

      From my understanding, this should be fixable by detecting in the ApiExtractor that a namespace is marked "inline", and then stripping all references to this namespace completely from the generated code.

      If shiboken should also support the use of the inline namespace, (i.e. also accessing the std::_V2::error_category by this name), it might be required to add lookups that match both names.

      Attachments

        Issue Links

          For Gerrit Dashboard: PYSIDE-990
          # Subject Branch Project Status CR V

          Activity

            People

              kleint Friedemann Kleint
              volka Volker Aßmann
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: