2016-05-16 17:34:04 +03:00
|
|
|
namespace Lib {
|
|
|
|
inline namespace Lib_1 {
|
|
|
|
template <typename T>
|
|
|
|
class A;
|
2014-04-06 12:07:19 +04:00
|
|
|
}
|
|
|
|
|
2016-05-16 17:34:04 +03:00
|
|
|
template <typename T>
|
|
|
|
void g(T);
|
2014-04-06 12:07:19 +04:00
|
|
|
}
|
|
|
|
|
2016-05-16 17:34:04 +03:00
|
|
|
struct MyClass
|
|
|
|
{
|
2014-04-06 12:07:19 +04:00
|
|
|
};
|
2016-05-16 17:34:04 +03:00
|
|
|
namespace Lib {
|
|
|
|
template <>
|
|
|
|
class A<MyClass>
|
2014-04-06 12:07:19 +04:00
|
|
|
{
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
void someFunc()
|
|
|
|
{
|
|
|
|
Lib::A<MyClass> a;
|
2016-05-16 17:34:04 +03:00
|
|
|
g(a); // ok, Lib is an associated namespace of A
|
2014-04-06 12:07:19 +04:00
|
|
|
}
|