$ c++ -std=c++11 test_nn.cpp
In file included from test_nn.cpp:1:
In file included from ./nn.hpp:20:
In file included from /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/memory:638:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/tuple:1356:7: error: no matching constructor for initialization of 'dropbox::oxygen::nn<std::__1::shared_ptr<int> >'
second(_VSTD::forward<_Args2>(_VSTD::get<_I2>(__second_args))...)
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/utility:484:11: note: in instantiation of function template specialization 'std::__1::pair<const int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > >::pair<int &&, 0>' requested here
: pair(__pc, __first_args, __second_args,
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/memory:1783:31: note: in instantiation of function template specialization 'std::__1::pair<const int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > >::pair<int &&>' requested here
::new((void*)__p) _Up(_VSTD::forward<_Args>(__args)...);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/memory:1694:18: note: in instantiation of function template specialization
'std::__1::allocator<std::__1::__tree_node<std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, void *> >::construct<std::__1::pair<const int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, const
std::__1::piecewise_construct_t &, std::__1::tuple<int &&>, std::__1::tuple<> >' requested here
{__a.construct(__p, _VSTD::forward<_Args>(__args)...);}
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/memory:1540:14: note: in instantiation of function template specialization
'std::__1::allocator_traits<std::__1::allocator<std::__1::__tree_node<std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, void *> > >::__construct<std::__1::pair<const int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, const std::__1::piecewise_construct_t &, std::__1::tuple<int &&>, std::__1::tuple<> >' requested here
{__construct(__has_construct<allocator_type, _Tp*, _Args...>(),
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__tree:2163:20: note: in instantiation of function template specialization
'std::__1::allocator_traits<std::__1::allocator<std::__1::__tree_node<std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, void *> > >::construct<std::__1::pair<const int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, const std::__1::piecewise_construct_t &, std::__1::tuple<int &&>, std::__1::tuple<> >' requested here
__node_traits::construct(__na, _NodeTypes::__get_ptr(__h->__value_), _VSTD::forward<_Args>(__args)...);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__tree:2108:29: note: in instantiation of function template specialization 'std::__1::__tree<std::__1::__value_type<int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, std::__1::__map_value_compare<int, std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, std::__1::less<int>, true>,
std::__1::allocator<std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > > > >::__construct_node<const std::__1::piecewise_construct_t &, std::__1::tuple<int &&>, std::__1::tuple<> >' requested here
__node_holder __h = __construct_node(_VSTD::forward<_Args>(__args)...);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/map:1376:20: note: in instantiation of function template specialization 'std::__1::__tree<std::__1::__value_type<int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, std::__1::__map_value_compare<int, std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > >, std::__1::less<int>, true>,
std::__1::allocator<std::__1::__value_type<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> > > > >::__emplace_unique_key_args<int, const std::__1::piecewise_construct_t &, std::__1::tuple<int &&>, std::__1::tuple<> >'
requested here
return __tree_.__emplace_unique_key_args(__k,
^
test_nn.cpp:9:9: note: in instantiation of member function 'std::__1::map<int, dropbox::oxygen::nn<std::__1::shared_ptr<int> >, std::__1::less<int>, std::__1::allocator<std::__1::pair<const int,
dropbox::oxygen::nn<std::__1::shared_ptr<int> > > > >::operator[]' requested here
ints[0] = nn_make_shared<int>(1);
^
./nn.hpp:116:14: note: candidate constructor template not viable: requires single argument 'other', but no arguments were provided
explicit nn(const nn<OtherType> & other) : ptr(other.operator const OtherType & ()) {}
^
./nn.hpp:124:14: note: candidate constructor template not viable: requires single argument 'other', but no arguments were provided
explicit nn(nn<OtherType> && other) : ptr(std::move(other).operator OtherType && ()) {}
^
./nn.hpp:130:5: note: candidate constructor template not viable: requires single argument 'other', but no arguments were provided
nn(const nn<OtherType> & other) : ptr(other.operator const OtherType & ()) {}
^
./nn.hpp:137:5: note: candidate constructor template not viable: requires single argument 'other', but no arguments were provided
nn(nn<OtherType> && other) : ptr(std::move(other).operator OtherType && ()) {}
^
./nn.hpp:149:5: note: candidate constructor template not viable: requires 2 arguments, but 0 were provided
nn(const nn<OtherType> & ownership_ptr, nn<element_type *> target_ptr)
^
./nn.hpp:100:5: note: candidate constructor not viable: requires 1 argument, but 0 were provided
nn(std::nullptr_t) = delete; // nullptr is not allowed here
^
./nn.hpp:102:5: note: candidate constructor not viable: requires 1 argument, but 0 were provided
nn(PtrType) = delete; // must use NN_CHECK_ASSERT or NN_CHECK_THROW
^
./nn.hpp:71:7: note: candidate constructor (the implicit move constructor) not viable: requires 1 argument, but 0 were provided
class nn {
^
./nn.hpp:71:7: note: candidate constructor (the implicit copy constructor) not viable: requires 1 argument, but 0 were provided
./nn.hpp:106:14: note: candidate constructor not viable: requires 2 arguments, but 0 were provided
explicit nn(i_promise_i_checked_for_null_t, const PtrType & arg) : ptr(arg) { assert(ptr); }
^
./nn.hpp:107:14: note: candidate constructor not viable: requires 2 arguments, but 0 were provided
explicit nn(i_promise_i_checked_for_null_t, PtrType && arg) : ptr(std::move(arg)) { assert(ptr); }
^
1 error generated.