cppast icon indicating copy to clipboard operation
cppast copied to clipboard

Arguments in a template specialization are not exposed

Open foonathan opened this issue 8 years ago • 0 comments

  • cppast version: latest one
  • parser: libclang_parser
  • clang version: 3.9.1+

Due to a libclang limitation, the arguments in a template specialization are only available as a string unless the specialization is in a friend declaration.

Input:

template <typename T, int I>
struct foo {};

template <>
struct foo<int, 42> {};

Here, the only information available about the specialization arguments is the string "int, 42".

foonathan avatar Apr 18 '17 14:04 foonathan