(boost:: && std::) bind of Wt::WApplication* application_creator fails with too few arguments
This is the problem I asked a few weeks ago on stackoverflow in the Wt section, so for better formatting I recommend reading there:
--- Summary of link content
I want to bind my additional parameters for my
Wt::WApplication* MDDB_Service::application_creator(const Wt::WEnvironment& env, int foo); function like in the example. My solution compiles perfectly with gcc/mingw but with MSVC/Visual Studio 2013 Express, it fails with the error: "Error 94 error C2198: 'Wt::WApplication *(__cdecl *)(const Wt::WEnvironment &,int)' : too few arguments for call ...include\boost\function\function_template.h"
Wt::WRun(argc, argv,boost::bind(MDDB_Service::application_creator, _1, 5)); and also
Wt::WRun(argc, argv,std::bind(MDDB_Service::application_creator, std::placeholders::_1, 5));. ¶
The audience at stackoverflow supposes that this bug may be related to the fact that the default constructor of
Wt::WEnvironment is not public.
Wt version : 3.3.4.