2 // RUN: split-file %s %t
3 // RUN: sed -e "s@INPUT_DIR@%{/t:regex_replacement}@g" \
4 // RUN: %t/reference.output.json.in >> %t/reference.output.json
5 // RUN: %clang_cc1 -extract-api --pretty-sgf -triple arm64-apple-macosx \
6 // RUN: -x c++-header %t/input.h -o %t/output.json -verify
8 // Generator version is not consistent across test runs, normalize it.
9 // RUN: sed -e "s@\"generator\": \".*\"@\"generator\": \"?\"@g" \
10 // RUN: %t/output.json >> %t/output-normalized.json
11 // RUN: diff %t/reference.output.json %t/output-normalized.json
14 template<typename T
> class Foo
: public T
{};
16 /// expected-no-diagnostics
18 //--- reference.output.json.in
31 "architecture": "arm64",
45 "kind": "inheritsFrom",
46 "source": "c:@ST>1#T@Foo",
53 "accessLevel": "public",
54 "declarationFragments": [
57 "spelling": "template"
65 "spelling": "typename"
72 "kind": "genericParameter",
97 "interfaceLanguage": "c++",
98 "precise": "c:@ST>1#T@Foo"
101 "displayName": "Class",
102 "identifier": "c++.class"
109 "uri": "file://INPUT_DIR/input.h"
114 "kind": "identifier",
120 "kind": "identifier",