-
Notifications
You must be signed in to change notification settings - Fork 218
Closed
Description
This trivial example, similar to the examples in the Boost.Python documentation, compiled with 1.58 but doesn't with 1.59 (using various versions of GCC and Clang):
#include <boost/python.hpp>
struct X { int y; };
int main()
{
boost::python::make_setter(&X::y);
}
The relevant error is:
/usr/local/boost-1.59.0/include/boost/python/data_members.hpp:303:15: note: candidate: boost::python::api::object boost::python::make_setter(D&) [with D = int X::*] <near match>
inline object make_setter(D& x) ^
/usr/local/boost-1.59.0/include/boost/python/data_members.hpp:303:15: note: conversion of argument 1 would be ill-formed:
prog.cc:7:37: error: invalid initialization of non-const reference of type 'int X::*&' from an rvalue of type 'int X::*'
boost::python::make_setter(&X::y); ^
Metadata
Metadata
Assignees
Labels
No labels