WARNING: This is currently a Work In Progress
The SCL is a set of tools providing classes and utility functions that aim to ease the development of your applications.
You can have a look at the documentation here.
Here is the namespace hierarchy:
- scl - The englobing namespace
- concepts - A concept-like library based around
static_assert
(mostly implemented as defined in cppreference) - tools - General purpose utility functions
- make - Create objects/pointers through factories
- iostream - IOstream manipulators and utils
- log - Logging utils
- prefixed - Log w/ a prefix
- surrounded - Log w/ a prefix & a suffix
- wrap - An alias for scl::tools::iostream::log::surrounded
- log - Logging utils
- meta - Template Meta Programming utils (such as
void_t
,enable_if_t
andconstexpr
functions likeis_same
or even handy stuff likeconstexpr_assert
) - console - An alias for scl::tools::iostream::log
- cli - An alias for scl::console
- exceptions - Exception types used in the library
- utils - Utility classes (and rare functions), eg.
Any
orOpiontal
or eventoString
- stream - The stream API exposing stream creators, operations and terminators
- details - Implementation details for streams (including the base iterator types)
- creators - Grouping stream creation functions
- operators - Grouping intermediate stream operation functions
- terminators - Grouping end of stream operation functions
- async - The asynchronous programming API
- http - The HTTP API
- detect - The feature/platform detection API
- platform - The platform detection API
- concepts - A concept-like library based around
Here are some macros and their meaning:
- Code based macros
realConst(type)
- Gives aconst
version of the given type (equivalent toconst type const
, useful for pointers)stringLiteral
- The actual string literal type (so you don't have to learn it by heart)assert_concept
- Compile time assertions of concepts outside of a block of code (must be simple concepts, not aggregates (e.g.Copyable
vsInvocable
))static_require
- Require concepts without giving an additional error messageMETA
- The fully qualified namespace path to themeta
namespace (actually isscl::tools::meta
)asString
- The function that converts a variable tostd::string
using itsToString
specialization
- Flags
SCL_CPP14
- Define this flag to use the C++14 add-ons (e.g.is_final_t
)SCL_CPP17
- Define this flag to use the C++17 add-ons (e.g.is_swappable_t
)SCL_CONCEPTS_REQUIRE_IS_VOID
- Define this flag to replaceconstexpr bool require()
withconstexpr void require()
SCL_USE_IOSTREAM_EXTEND
- Define this flag if you wish to use the general purposeoperator<<
forostream
that usesstd::to_string
andscl::utils::toString
for conversionsSCL_ENABLE_DEPRECATED_TYPEMODS
- Define this flag if you wish to define the deprecated typemods (e.g.result_of_t
)SCL_ENABLE_DEPRECATED_TYPECHECKS
- Define this flag if you wish to define the deprecated typechecks (e.g.is_pod_t
)SCL_KEEP_DETECT_MACROS
- Define this flag if you wish to keep the macros forscl::detect
defined