arg_router  1.4.0
C++ command line argument parsing and routing
string_selector.hpp File Reference
#include "arg_router/utility/compile_time_string.hpp"
#include <boost/preprocessor/variadic.hpp>
Include dependency graph for string_selector.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 arg_router
 
 arg_router::multi_lang
 

Macros

#define SM_(I, ...)
 

Typedefs

template<std::size_t I, typename... S>
using arg_router::multi_lang::string_selector = std::tuple_element_t< I, std::tuple< S... > >
 

Macro Definition Documentation

◆ SM_

#define SM_ (   I,
  ... 
)
Value:
BOOST_PP_ENUM( \
BOOST_PP_VARIADIC_SIZE(__VA_ARGS__), \
AR_SM_UNPACK, \
BOOST_PP_VARIADIC_TO_ARRAY(__VA_ARGS__))>
std::tuple_element_t< I, std::tuple< S... > > string_selector

A multi-language equivalent to S_, only for use within a multi_lang::root call.

Specify the string language variants in the order they are declared in the owning multi_lang::root.

arp::long_name<SM_("help", "aider", "ayuda")>
#define SM_(I,...)
Note
This has now been superceded by multi_lang::root_t, and will be removed in v2

The macro creates compile_time_string types from the inputs and puts them into a string_selector. There is no requirement to use this macro, it's just a convenience.

Parameters
IIndex to select

Definition at line 44 of file string_selector.hpp.