Releases: alexpolt/luple
Releases · alexpolt/luple
Final Release
Polished and ready for use. Added as_nuple:
auto get_person( int id ) {
return as_nuple( $name("key"), std::string{"John"}, $name("value"), id );
}
auto p = get_person(0);
std::cout << get<$("key")>( p ) << ", " << get<$("value")>( p );
Check out links to online samples.
Pre-Final
Added as_luple function (aka make_tuple). And a twin as_nuple which allows syntax:
auto p = as_nuple( $name("key"), "some string", $name("value"), some value );
std::cout << get<$("key")>( p ); //some string
Note
Also added luple_tie() (aka std::tie). Added converting assigment and construction:
luple< std::string > obj = as_luple( "Hello World" );
Lastly added swap ( using std::move ).
intern.h now defines N3599 by default which makes use of GCC and Clang extension, waiting for MSVC.
Remains to implement std::forward_as_tuple.
Looking to add C++17 template arg deduction for class templates and folding expression for luple_do.