Skip to content

Instantly share code, notes, and snippets.

@Lazin
Created June 11, 2014 19:49
Show Gist options
  • Save Lazin/18c10ae0ac1a48a882d3 to your computer and use it in GitHub Desktop.
Save Lazin/18c10ae0ac1a48a882d3 to your computer and use it in GitHub Desktop.
//! Loading for std::list
template <class Archive, class T, class A> inline
void load( Archive & ar, std::list<T, A> & list )
{
size_type size;
ar( make_size_tag( size ) );
list.resize( static_cast<size_t>( size ) );
for( auto & i : list )
ar( i );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment