#include <iostream>
using namespace std;

namespace noncopyable_  // protection from unintended ADL
{

    class noncopyable
    {
    protected:

        noncopyable()
        {
        	std::cout << "default noncopyable()/n";
        }
        ~noncopyable() {}

    //private:  
        noncopyable(const noncopyable& that)
        {
        	std::cout << "copy noncopyable()/n";
        }
        const noncopyable& operator=(const noncopyable& that);
    };

} // namespace noncopyable_

typedef noncopyable_::noncopyable noncopyable;

class Test : private noncopyable
{
public:
    Test() : m_val() {}
    Test(const Test& other) : m_val(other.m_val) {}
    ~Test() {}

private:
    int m_val;
};

int main()
{
	Test t1;
    Test t2(t1);
	std::cout << "end of test./n";
	return 0;
}