Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

smart_library.get_mem_fn failed to call with 64bit dll #47

Open
c8jiang opened this issue Aug 21, 2019 · 0 comments · May be fixed by boostorg/dll#85
Open

smart_library.get_mem_fn failed to call with 64bit dll #47

c8jiang opened this issue Aug 21, 2019 · 0 comments · May be fixed by boostorg/dll#85

Comments

@c8jiang
Copy link

c8jiang commented Aug 21, 2019

Environment: Windows 10 1903; MSVC 14.2; Boost 1.70
A member function in my class was successfully imported only in x86 and failed in x64.

auto f = sm.get_mem_fn<alias, void(Callback)>("set_callback"); give me an exception in x64.
image

My prject file: test_class.zip

My class like this:
#include <iostream>
#include <functional>
#include <boost/config.hpp>

struct CallbackInfo
{
void* p;
int a;
int b;
void* pContext;
};
//using Callback = std::function<void(CallbackInfo* pInfo)>;
typedef void(__stdcall* Callback)(CallbackInfo* pInfo);
class BOOST_SYMBOL_EXPORT test_a
{
int _a;
public:
test_a();
test_a(int a);
~test_a();
void print();
bool large_than(int a);
const char* number();
void set_callback(Callback callback);
static std::size_t size();
std::string name() const;
};

@c8jiang c8jiang changed the title smart_library.get_mem_fn failed to call in 64bit dll smart_library.get_mem_fn failed to call with 64bit dll Aug 21, 2019
apolukhin added a commit that referenced this issue Jan 3, 2021
update lcov in .travis.yml
apolukhin added a commit to boostorg/dll that referenced this issue Dec 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant