Anonymous
public text v1 · immutabletemplate<class T>
class list
{
public:
void add(T& v);
void del(int i);
void find(T& v);
template<class U>
void find_if(U functor);
};
template<class T>
class list_proxy
{
list<T>& list_;
public:
list_proxy(list<T>& l): list_(l) {};
void add(T& v){throw std::string("resticted");}
void del(int i){throw std::string("resticted");}
const T find(T& v){return list_.find(v);}
template<class U>
const T& find_if(U functor){return list_.find_if(functor); }
};