11// RUN: rm -rf %t
22// RUN: mkdir %t
3+
34// RUN: clang-doc --doxygen --executor=standalone %s -output=%t/docs
45// RUN: cat %t/docs/index.yaml | FileCheck %s --check-prefix=YAML
56
7+ // RUN: clang-doc --doxygen --executor=standalone %s -output=%t/docs --format=md
8+ // RUN: cat %t/docs/GlobalNamespace/index.md | FileCheck %s --check-prefix=MD
9+
610// YAML: ---
711// YAML-NEXT: USR: '{{([0-9A-F]{40})}}'
812
13+ // MD: # Global Namespace
14+ // MD: ## Functions
15+
916template <class ... T>
1017void ParamPackFunction (T... args);
1118
@@ -28,6 +35,9 @@ void ParamPackFunction(T... args);
2835// YAML-NEXT: Params:
2936// YAML-NEXT: - Contents: 'class... T'
3037
38+ // MD: ### ParamPackFunction
39+ // MD: *void ParamPackFunction(T... args)*
40+
3141template <typename T, int U = 1 >
3242void function (T x) {}
3343
@@ -50,6 +60,10 @@ void function(T x) {}
5060// YAML-NEXT: - Contents: 'typename T'
5161// YAML-NEXT: - Contents: 'int U = 1'
5262
63+ // MD: ### function
64+ // MD: *void function(T x)*
65+ // MD: *Defined at {{.*}}templates.cpp#[[# @LINE - 23]]*
66+
5367template <>
5468void function<bool , 0 >(bool x) {}
5569
@@ -75,3 +89,7 @@ void function<bool, 0>(bool x) {}
7589// YAML-NEXT: - Contents: '0'
7690// YAML-NEXT: ...
7791
92+ // MD: ### function
93+ // MD: *void function(_Bool x)*
94+ // MD: *Defined at {{.*}}templates.cpp#[[# @LINE - 27]]*
95+
0 commit comments