Skip to content

Commit

Permalink
clangIndex
Browse files Browse the repository at this point in the history
  • Loading branch information
MaskRay committed Jul 9, 2018
1 parent ed1b221 commit c6553c7
Show file tree
Hide file tree
Showing 73 changed files with 765 additions and 691 deletions.
2 changes: 1 addition & 1 deletion index_tests/constructors/constructor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ void foo() {
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [10983126130596230582, 17165811951126099095],
"uses": [],
"callees": []
}],
Expand Down
2 changes: 1 addition & 1 deletion index_tests/constructors/destructor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ void foo() {
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [1893354193220338759],
"uses": [],
"callees": []
}, {
Expand Down
6 changes: 3 additions & 3 deletions index_tests/constructors/implicit_constructor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void Make() {
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [449111627548814328, 17097499197730163115],
"uses": [],
"callees": []
}, {
Expand Down Expand Up @@ -77,10 +77,10 @@ void Make() {
"storage": 0
}, {
"usr": 17097499197730163115,
"detailed_name": "auto foo1",
"detailed_name": "Type foo1",
"qual_name_offset": 5,
"short_name": "foo1",
"hover": "auto foo1 = Type()",
"hover": "Type foo1 = Type()",
"declarations": [],
"spell": "7:8-7:12|3957104924306079513|3|2",
"extent": "7:3-7:21|3957104924306079513|3|0",
Expand Down
4 changes: 2 additions & 2 deletions index_tests/constructors/make_functions.cc
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ OUTPUT: make_functions.cc
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [3908732770590594660],
"uses": ["17:3-17:14|0|1|8228"],
"callees": []
}, {
Expand Down Expand Up @@ -182,7 +182,7 @@ OUTPUT: make_functions.cc
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [8463700030555379526],
"uses": ["14:3-14:13|0|1|8228", "15:3-15:13|0|1|8228", "16:3-16:13|0|1|8228"],
"callees": []
}],
Expand Down
16 changes: 1 addition & 15 deletions index_tests/declaration_vs_definition/class_member.cc
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,7 @@ class Foo {
{
"includes": [],
"skipped_ranges": [],
"usr2func": [{
"usr": 15041163540773201510,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [9736582033442720743],
"uses": [],
"callees": []
}],
"usr2func": [],
"usr2type": [{
"usr": 53,
"detailed_name": "",
Expand Down
16 changes: 1 addition & 15 deletions index_tests/declaration_vs_definition/class_member_static.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,7 @@ int Foo::foo;
{
"includes": [],
"skipped_ranges": [],
"usr2func": [{
"usr": 15041163540773201510,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [8942920329766232482, 8942920329766232482],
"uses": [],
"callees": []
}],
"usr2func": [],
"usr2type": [{
"usr": 53,
"detailed_name": "",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ int foo(int a, int b) { return 0; }
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [14555488990109936920, 10963664335057337329],
"uses": [],
"callees": []
}],
Expand Down
16 changes: 1 addition & 15 deletions index_tests/enums/enum_class_decl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,7 @@ enum class Foo : uint8_t {
{
"includes": [],
"skipped_ranges": [],
"usr2func": [{
"usr": 16985894625255407295,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [439339022761937396, 15962370213938840720],
"uses": [],
"callees": []
}],
"usr2func": [],
"usr2type": [{
"usr": 2010430204259339553,
"detailed_name": "typedef unsigned char uint8_t",
Expand Down
16 changes: 1 addition & 15 deletions index_tests/enums/enum_decl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,7 @@ enum Foo {
{
"includes": [],
"skipped_ranges": [],
"usr2func": [{
"usr": 16985894625255407295,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [439339022761937396, 15962370213938840720],
"uses": [],
"callees": []
}],
"usr2func": [],
"usr2type": [{
"usr": 16985894625255407295,
"detailed_name": "enum Foo {\n}",
Expand Down
30 changes: 1 addition & 29 deletions index_tests/enums/enum_inherit.cc
Original file line number Diff line number Diff line change
Expand Up @@ -15,35 +15,7 @@ enum class E : int32_t {
{
"includes": [],
"skipped_ranges": [],
"usr2func": [{
"usr": 2986879766914123941,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [16614320383091394267, 16847439761518576294],
"uses": [],
"callees": []
}, {
"usr": 16985894625255407295,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [439339022761937396, 15962370213938840720],
"uses": [],
"callees": []
}],
"usr2func": [],
"usr2type": [{
"usr": 2986879766914123941,
"detailed_name": "enum class E : int32_t {\n}",
Expand Down
16 changes: 1 addition & 15 deletions index_tests/enums/enum_usage.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10,21 +10,7 @@ Foo x = Foo::A;
{
"includes": [],
"skipped_ranges": [],
"usr2func": [{
"usr": 16985894625255407295,
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"storage": 0,
"declarations": [],
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [439339022761937396, 15962370213938840720],
"uses": [],
"callees": []
}],
"usr2func": [],
"usr2type": [{
"usr": 16985894625255407295,
"detailed_name": "enum class Foo : int {\n}",
Expand Down
42 changes: 38 additions & 4 deletions index_tests/foobar.cc
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,23 @@ Foo<B> b;
"vars": [],
"instances": [],
"uses": ["9:5-9:6|0|1|4"]
}, {
"usr": 7074603899792463171,
"detailed_name": "Inner",
"qual_name_offset": 0,
"short_name": "Inner",
"kind": 26,
"declarations": [],
"spell": "6:3-6:18|0|1|2",
"extent": "6:3-6:18|0|1|0",
"alias_of": 0,
"bases": [],
"derived": [],
"types": [],
"funcs": [],
"vars": [],
"instances": [16721564935990383768],
"uses": []
}, {
"usr": 10528472276654770367,
"detailed_name": "struct Foo {}",
Expand All @@ -46,8 +63,25 @@ Foo<B> b;
"types": [13938528237873543349],
"funcs": [],
"vars": [],
"instances": [12028309045033782423],
"instances": [],
"uses": ["9:1-9:4|0|1|4", "10:1-10:4|0|1|4"]
}, {
"usr": 11976530632376795217,
"detailed_name": "Foo",
"qual_name_offset": 0,
"short_name": "Foo",
"kind": 26,
"declarations": [],
"spell": "4:1-7:2|0|1|2",
"extent": "4:1-7:2|0|1|0",
"alias_of": 0,
"bases": [],
"derived": [],
"types": [],
"funcs": [],
"vars": [],
"instances": [12028309045033782423],
"uses": []
}, {
"usr": 13892793056005362145,
"detailed_name": "enum B {\n}",
Expand Down Expand Up @@ -80,7 +114,7 @@ Foo<B> b;
"types": [],
"funcs": [],
"vars": [],
"instances": [16721564935990383768],
"instances": [],
"uses": ["9:9-9:14|10528472276654770367|2|4"]
}],
"usr2var": [{
Expand All @@ -91,7 +125,7 @@ Foo<B> b;
"declarations": [],
"spell": "10:8-10:9|0|1|2",
"extent": "10:1-10:9|0|1|0",
"type": 10528472276654770367,
"type": 11976530632376795217,
"uses": [],
"kind": 13,
"storage": 0
Expand All @@ -103,7 +137,7 @@ Foo<B> b;
"declarations": [],
"spell": "9:15-9:16|0|1|2",
"extent": "9:1-9:16|0|1|0",
"type": 13938528237873543349,
"type": 7074603899792463171,
"uses": [],
"kind": 13,
"storage": 0
Expand Down
18 changes: 11 additions & 7 deletions index_tests/lambdas/lambda.cc
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ void foo() {
"declaring_type": 0,
"bases": [],
"derived": [],
"vars": [],
"vars": [12666114896600231317, 2981279427664991319],
"uses": [],
"callees": []
}, {
Expand Down Expand Up @@ -67,27 +67,29 @@ void foo() {
"detailed_name": "",
"qual_name_offset": 0,
"short_name": "",
"kind": 0,
"kind": 26,
"declarations": [],
"spell": "4:22-4:23|4259594751088586730|3|2",
"extent": "4:22-4:23|4259594751088586730|3|0",
"alias_of": 0,
"bases": [],
"derived": [],
"types": [],
"funcs": [],
"vars": [],
"instances": [],
"instances": [2981279427664991319],
"uses": []
}],
"usr2var": [{
"usr": 2981279427664991319,
"detailed_name": "auto dosomething",
"qual_name_offset": 5,
"detailed_name": "(lambda) dosomething",
"qual_name_offset": 9,
"short_name": "dosomething",
"hover": "auto dosomething = [&x] (int y) {\n ++x;\n ++y;\n }\n",
"hover": "(lambda) dosomething = [&x](int y) {\n ++x;\n ++y;\n }",
"declarations": [],
"spell": "4:8-4:19|4259594751088586730|3|2",
"extent": "4:3-7:4|4259594751088586730|3|0",
"type": 0,
"type": 14635009347499519042,
"uses": ["9:3-9:14|4259594751088586730|3|4", "10:3-10:14|4259594751088586730|3|4", "11:3-11:14|4259594751088586730|3|4"],
"kind": 13,
"storage": 0
Expand All @@ -109,6 +111,8 @@ void foo() {
"qual_name_offset": 4,
"short_name": "y",
"declarations": [],
"spell": "4:31-4:32|17926497908620168464|3|2",
"extent": "4:27-4:32|17926497908620168464|3|0",
"type": 0,
"uses": ["6:7-6:8|17926497908620168464|3|28"],
"kind": 253,
Expand Down
4 changes: 2 additions & 2 deletions index_tests/macros/complex.cc
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ FOO(make1(), make2);
"detailed_name": "FOO",
"qual_name_offset": 0,
"short_name": "FOO",
"hover": "#define FOO",
"hover": "#define FOO(aaa, bbb) \\\n int a();\\\n int a() { return aaa + bbb; }",
"declarations": [],
"spell": "1:9-1:12|0|1|2",
"extent": "1:9-1:12|0|1|2",
"extent": "1:9-3:32|0|1|0",
"type": 0,
"uses": ["12:1-12:20|0|1|4"],
"kind": 255,
Expand Down
10 changes: 5 additions & 5 deletions index_tests/macros/foo.cc
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,10 @@ int x = A;
"detailed_name": "A",
"qual_name_offset": 0,
"short_name": "A",
"hover": "#define A",
"hover": "#define A 5",
"declarations": [],
"spell": "1:9-1:10|0|1|2",
"extent": "1:9-1:10|0|1|2",
"extent": "1:9-1:12|0|1|0",
"type": 0,
"uses": ["8:9-8:10|0|1|4"],
"kind": 255,
Expand All @@ -80,10 +80,10 @@ int x = A;
"detailed_name": "DISALLOW",
"qual_name_offset": 0,
"short_name": "DISALLOW",
"hover": "#define DISALLOW",
"hover": "#define DISALLOW(type) type(type&&) = delete;",
"declarations": [],
"spell": "2:9-2:17|0|1|2",
"extent": "2:9-2:17|0|1|2",
"extent": "2:9-2:46|0|1|0",
"type": 0,
"uses": ["5:3-5:16|0|1|4"],
"kind": 255,
Expand All @@ -93,7 +93,7 @@ int x = A;
"detailed_name": "int x",
"qual_name_offset": 4,
"short_name": "x",
"hover": "int x = 5",
"hover": "int x = ",
"declarations": [],
"spell": "8:5-8:6|0|1|2",
"extent": "8:1-1:1|0|1|0",
Expand Down
Loading

0 comments on commit c6553c7

Please sign in to comment.