Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-12-08 12:36:49


Stefan Seefeld wrote:
>
> When writing plugins under linux (i.e. with 'dlopen' etc.),
> I believe I have already used a function returning a std::auto_ptr as
> entry point for the loader. What is wrong with that ? Is your advice
> above simply due to a limitation with MSVC ?

It seems so. From a quick test, g++ and bcc32 do return C++ classes from
extern "C" functions, only MSVC emits an error. I'm not sure whether such a
function makes sense, though. If you suppress name mangling, presumably
because two different compilers mangle names differently, what are the
chances that the object layout will be the same?


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk