fork(1) download
  1. #include <iostream>
  2. #include <vector>
  3.  
  4. struct First {
  5. template <typename T>
  6. using ArrayType = std::vector<T>;
  7. };
  8.  
  9. template <typename T>
  10. struct Second {
  11. void go() { std::cout << "General\n"; }
  12. };
  13.  
  14. template <typename T>
  15. struct Second < typename First::template ArrayType<T> > {
  16. void go() { std::cout << "Specialized\n"; }
  17. };
  18.  
  19. int main() {
  20. Second < std::vector<int> > second;
  21. second.go();
  22. return 0;
  23. }
Success #stdin #stdout 0s 3340KB
stdin
Standard input is empty
stdout
Specialized