siplasplas
A library for C++ reflection and introspection
|
Some random utilities needed by other siplasplas modules. More...
Modules | |
Assert | |
Assertion utilities. | |
Dynamic-library | |
Cross platform API to load symbols from shared librarties at runtime. | |
Error-handling | |
Error handling tools. | |
Hash | |
Hashing utilities based on std::hash . | |
Functions | |
template<typename T > | |
std::string | cpp::lexical_cast (const T &value) |
Returns an string representation of a value. More... | |
template<typename T > | |
T | cpp::lexical_cast (const std::string &value) |
Returns an string representation of a value. More... | |
Some random utilities needed by other siplasplas modules.
The siplaspals-utility module implements various utilities used in the implementation of other siplasplas modules. These utilities are not grouped in any special way, but we encourage the policy of rising utilities into full-fledged modules if these became too complex.
Move meta.hpp, function_traits.hpp, tuple.hpp, and fusion.hpp to a siplasplas-meta module.
Move error_logger.hpp and exception.hpp to a siplasplas-exception module?
Move cpp::Overload<> to function_traits.hpp
siplasplas-utility includes the following features:
std::string cpp::lexical_cast | ( | const T & | value | ) |
Returns an string representation of a value.
This function invokes operator<<(std::ostream&, const T&)
to get an string representation of a given value.
It's a simplified version of the Boost.Lexical_Cast library.
T | value type. Must have a valid operator<<(std::ostream&, T) overload. |
value | Value which is translated to a string. |
T cpp::lexical_cast | ( | const std::string & | value | ) |
Returns an string representation of a value.
This function invokes operator>>(std::istream&, T&)
to assign a T value from an string representation of it.
It's a simplified version of the Boost.Lexical_Cast library.
T | Required output value type. Must have a valid operator>>(std::istream&, T&) overload. |
value | String representation of the value. |
T
equivalent to the value
string representation argument.