wrap.cc - return *this; } template<typename...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include <iostream> #include "Wrap.h" template<typename T> Wrap<T>::Wrap() { value = 0; } template<typename T> Wrap<T>::Wrap(T v) { this->value = v; } template<typename T> this->value = w.value; } template<typename T> Wrap<T>::~Wrap() { // nothing } template<typename T> this->value = w.value;
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: return *this; } template&lt;typename T&gt; T Wrap&lt;T&gt;::get() const { return value; } template&lt;typename T&gt; void Wrap&lt;T&gt;::set(T v) { value = v; } template&lt;typename T&gt; void Wrap&lt;T&gt;::display(ostream&amp; os) const { os &lt;&lt; value &lt;&lt; endl; } //ostream&amp; operator&lt;&lt;(ostream&amp; os, const Wrap&amp; w) { // w.display(os); // return os; //}...
View Full Document

Ask a homework question - tutors are online