|
Boost Users : |
Subject: [Boost-users] [function] Boost.Function won't compile under Borland DevStudio 2006
From: Fábio 'Petrucio' Stange (petrucio_at_[hidden])
Date: 2010-04-09 18:09:31
I've just recently learned about boost::function when reading Effective
C++, and I was thrilled about it.
This is the simple code I'm trying to implement:
typedef boost::function1<void, boost::shared_ptr<VarSpeedObject> >
ObjectDoneCallback;
void SomeFunction(ObjectDoneCallback callback, ...) {
// Some code
callback(...);
}
When trying to compile it under C++ Builder 2006 (I have no other choice
but to use this in the current project), I get the following error:
[C++ Error] function_template.hpp(904): E2131 Objects of type
'detail::function::basic_vtable1<void,shared_ptr<VarSpeedObject> >'
cannot be initialized with { }
On this line in function_template.hpp:
static vtable_type stored_vtable =
{ { &manager_type::manage }, &invoker_type::invoke };
Can I circumvent this somehow to make it compile under my environment?
Thanks,
Petrucio
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net