Boost logo

Boost :

From: Boris (boriss_at_[hidden])
Date: 2008-08-21 07:15:23

On Thu, 21 Aug 2008 00:05:08 +0200, Jeremy Pack <rostovpack_at_[hidden]>

> [...]I've just added size() and empty() functions to type_map.

Thank you!

> You can also pass some sort of status message through the type_map to the
> shared library if you'd like (using a string or some custom type).
> I'm curious though, what type of problem were you having that led to this
> request?

I was rearranging some code when I started to use Andrey's logging
library. With empty() I can implement a function loading a shared library
and calling types like this:

bool init(const std::string &name)
   shared_library lib(name);
   if (!
     BOOST_LOG(mylogger) << "error ...";
   else if (!
     BOOST_LOG(mylogger) << "error ...";
     BOOST_LOG(mylogger) << "no error ...";

   return lib.is_open() && !types.empty();

As you see it was not a very important request. :)


Boost list run by bdawes at, gregod at, cpdaniel at, john at