Templated Queue C++