FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Deprecated declarations warnings · Issue #777 · pybind/pybind11 · GitHub

Deprecated declarations warnings #777

Description

I'm compiling an empty module with -Wall with the latest pybind11 (82ece94, Linux / GCC 5.2 / both C++11 and C++14) and I get a ton of deprecated declarations warnings:

In file included from ../include/pybind11/cast.h:13:0,
                 from ../include/pybind11/attr.h:13,
                 from ../include/pybind11/pybind11.h:36,
                 from test_module.cpp:10:
../include/pybind11/pytypes.h:190:7: warning: ‘pybind11::object::borrowed’ is deprecated: Use of the `borrowed` static variable is deprecated; use `borrowed_t{}' instead [-Wdeprecated-declarations]
 class object : public handle {
       ^
../include/pybind11/pytypes.h:241:33: note: declared here
     static constexpr borrowed_t borrowed{};
                                 ^
../include/pybind11/pytypes.h:190:7: warning: ‘pybind11::object::stolen’ is deprecated: Use of the `stolen` static variable is deprecated; use `stolen_t{}' instead [-Wdeprecated-declarations]
 class object : public handle {
       ^
../include/pybind11/pytypes.h:243:31: note: declared here
     static constexpr stolen_t stolen{};
                               ^
../include/pybind11/pytypes.h:190:7: warning: ‘pybind11::object::borrowed’ is deprecated: Use of the `borrowed` static variable is deprecated; use `borrowed_t{}' instead [-Wdeprecated-declarations]
 class object : public handle {
       ^
../include/pybind11/pytypes.h:241:33: note: declared here
     static constexpr borrowed_t borrowed{};
                                 ^
../include/pybind11/pytypes.h:190:7: warning: ‘pybind11::object::stolen’ is deprecated: Use of the `stolen` static variable is deprecated; use `stolen_t{}' instead [-Wdeprecated-declarations]
 class object : public handle {
       ^
../include/pybind11/pytypes.h:243:31: note: declared here
     static constexpr stolen_t stolen{};

Source:

#include <pybind11/pybind11.h>

PYBIND11_PLUGIN(test_warnings) { return pybind11::module("test_warnings").ptr(); }

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL