mirror of
https://github.com/MaskRay/ccls.git
synced 2024-11-23 08:05:07 +00:00
clangIndex
This commit is contained in:
parent
ed1b221fab
commit
c6553c79ab
@ -42,7 +42,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [10983126130596230582, 17165811951126099095],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -47,7 +47,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [1893354193220338759],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
|
@ -25,7 +25,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [449111627548814328, 17097499197730163115],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
@ -77,10 +77,10 @@ OUTPUT:
|
||||
"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",
|
||||
|
@ -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": []
|
||||
}, {
|
||||
@ -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": []
|
||||
}],
|
||||
|
@ -7,21 +7,7 @@ OUTPUT:
|
||||
{
|
||||
"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": "",
|
||||
|
@ -9,21 +9,7 @@ OUTPUT:
|
||||
{
|
||||
"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": "",
|
||||
|
@ -22,7 +22,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [14555488990109936920, 10963664335057337329],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -9,21 +9,7 @@ OUTPUT:
|
||||
{
|
||||
"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",
|
||||
|
@ -8,21 +8,7 @@ OUTPUT:
|
||||
{
|
||||
"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}",
|
||||
|
@ -15,35 +15,7 @@ OUTPUT:
|
||||
{
|
||||
"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}",
|
||||
|
@ -10,21 +10,7 @@ OUTPUT:
|
||||
{
|
||||
"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}",
|
||||
|
@ -31,6 +31,23 @@ OUTPUT:
|
||||
"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 {}",
|
||||
@ -46,8 +63,25 @@ OUTPUT:
|
||||
"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}",
|
||||
@ -80,7 +114,7 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [16721564935990383768],
|
||||
"instances": [],
|
||||
"uses": ["9:9-9:14|10528472276654770367|2|4"]
|
||||
}],
|
||||
"usr2var": [{
|
||||
@ -91,7 +125,7 @@ OUTPUT:
|
||||
"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
|
||||
@ -103,7 +137,7 @@ OUTPUT:
|
||||
"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
|
||||
|
@ -29,7 +29,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [12666114896600231317, 2981279427664991319],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
@ -67,27 +67,29 @@ OUTPUT:
|
||||
"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
|
||||
@ -109,6 +111,8 @@ OUTPUT:
|
||||
"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,
|
||||
|
@ -83,10 +83,10 @@ OUTPUT:
|
||||
"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,
|
||||
|
@ -67,10 +67,10 @@ OUTPUT:
|
||||
"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,
|
||||
@ -80,10 +80,10 @@ OUTPUT:
|
||||
"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,
|
||||
@ -93,7 +93,7 @@ OUTPUT:
|
||||
"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",
|
||||
|
@ -10,21 +10,7 @@ OUTPUT: funky_enum.h
|
||||
{
|
||||
"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, 8524995777615948802],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 16985894625255407295,
|
||||
"detailed_name": "",
|
||||
|
@ -10,20 +10,6 @@ OUTPUT: header.h
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 4481210672785600703,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [6141718166919284735, 17716334512218775320, 7285646116511901840],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 11650481237659640387,
|
||||
"detailed_name": "void Foo1()",
|
||||
"qual_name_offset": 5,
|
||||
|
@ -51,8 +51,8 @@ OUTPUT: static.cc
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 14576076421851654759,
|
||||
"detailed_name": "static void Buffer::CreateSharedBuffer()",
|
||||
"qual_name_offset": 12,
|
||||
"detailed_name": "void Buffer::CreateSharedBuffer()",
|
||||
"qual_name_offset": 5,
|
||||
"short_name": "CreateSharedBuffer",
|
||||
"kind": 6,
|
||||
"storage": 0,
|
||||
|
@ -31,21 +31,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 14450849931009540802,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [15042442838933090518],
|
||||
"vars": [6030927277961448585, 7657277353101371136],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
@ -106,7 +92,10 @@ OUTPUT:
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"vars": [{
|
||||
"L": 15042442838933090518,
|
||||
"R": -1
|
||||
}],
|
||||
"instances": [],
|
||||
"uses": ["9:27-9:30|17805385787823406700|2|4", "12:21-12:24|17805385787823406700|2|4"]
|
||||
}, {
|
||||
|
@ -30,20 +30,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 11072669167287398027,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [12898699035586282159],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 17328473273923617489,
|
||||
"detailed_name": "void ns::Accept(int a)",
|
||||
@ -57,7 +43,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [3649375698083002347],
|
||||
"uses": ["7:7-7:13|11072669167287398027|2|8228", "9:3-9:9|11072669167287398027|2|8228"],
|
||||
"callees": []
|
||||
}],
|
||||
@ -88,7 +74,10 @@ OUTPUT:
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [17328473273923617489],
|
||||
"vars": [],
|
||||
"vars": [{
|
||||
"L": 12898699035586282159,
|
||||
"R": -1
|
||||
}],
|
||||
"instances": [],
|
||||
"uses": ["7:3-7:5|0|1|4", "7:14-7:16|0|1|4", "8:19-8:21|0|1|4"]
|
||||
}],
|
||||
|
@ -85,18 +85,19 @@ OUTPUT: static_function_in_type.cc
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 17019747379608639279,
|
||||
"detailed_name": "static void ns::Foo::Register(ns::Manager *)",
|
||||
"qual_name_offset": 12,
|
||||
"detailed_name": "void Foo::Register(ns::Manager *m)",
|
||||
"qual_name_offset": 5,
|
||||
"short_name": "Register",
|
||||
"kind": 6,
|
||||
"storage": 0,
|
||||
"comments": "static",
|
||||
"declarations": [],
|
||||
"spell": "5:11-5:19|17262466801709381811|2|514",
|
||||
"extent": "5:1-6:2|11072669167287398027|2|0",
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [13569879755236306838],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -18,7 +18,7 @@ OUTPUT:
|
||||
"hover": "#define FOO",
|
||||
"declarations": [],
|
||||
"spell": "2:9-2:12|0|1|2",
|
||||
"extent": "2:9-2:12|0|1|2",
|
||||
"extent": "2:9-2:12|0|1|0",
|
||||
"type": 0,
|
||||
"uses": [],
|
||||
"kind": 255,
|
||||
|
@ -19,35 +19,7 @@ OUTPUT:
|
||||
{
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 11072669167287398027,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [12898699035586282159, 9008550860229740818],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 12688716854043726585,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [4731849186641714451, 4731849186641714451],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 53,
|
||||
"detailed_name": "",
|
||||
@ -92,7 +64,13 @@ OUTPUT:
|
||||
"derived": [],
|
||||
"types": [1532099849728741556, 12688716854043726585],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"vars": [{
|
||||
"L": 12898699035586282159,
|
||||
"R": -1
|
||||
}, {
|
||||
"L": 9008550860229740818,
|
||||
"R": -1
|
||||
}],
|
||||
"instances": [],
|
||||
"uses": []
|
||||
}, {
|
||||
@ -118,7 +96,7 @@ OUTPUT:
|
||||
"detailed_name": "static constexpr ns::VarType ns::Holder::static_var",
|
||||
"qual_name_offset": 29,
|
||||
"short_name": "static_var",
|
||||
"hover": "static constexpr ns::VarType ns::Holder::static_var = (ns::VarType)0",
|
||||
"hover": "static constexpr ns::VarType ns::Holder::static_var = (VarType)0x0",
|
||||
"declarations": ["6:30-6:40|12688716854043726585|2|513"],
|
||||
"spell": "10:37-10:47|12688716854043726585|2|514",
|
||||
"extent": "9:3-10:47|11072669167287398027|2|0",
|
||||
|
@ -41,20 +41,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 8402783583255987702,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [5866801090710377175],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 8905286151237717330,
|
||||
"detailed_name": "void C::bar()",
|
||||
@ -90,6 +76,23 @@ OUTPUT:
|
||||
}],
|
||||
"instances": [],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 14750650276757822712,
|
||||
"detailed_name": "T",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "T",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:11-1:18|8402783583255987702|2|2",
|
||||
"extent": "1:11-1:18|8402783583255987702|2|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [5866801090710377175],
|
||||
"uses": []
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 5866801090710377175,
|
||||
@ -99,7 +102,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "3:5-3:6|8402783583255987702|2|514",
|
||||
"extent": "3:3-3:6|8402783583255987702|2|0",
|
||||
"type": 0,
|
||||
"type": 14750650276757822712,
|
||||
"uses": [],
|
||||
"kind": 8,
|
||||
"storage": 0
|
||||
|
@ -32,20 +32,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": ["10:21-10:24|14042997404480181958|2|36", "11:22-11:25|14042997404480181958|2|36"],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 11072669167287398027,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [15768138241775955040, 3182917058194750998],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2type": [{
|
||||
"usr": 53,
|
||||
@ -74,7 +60,13 @@ OUTPUT:
|
||||
"derived": [],
|
||||
"types": [14042997404480181958],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"vars": [{
|
||||
"L": 15768138241775955040,
|
||||
"R": -1
|
||||
}, {
|
||||
"L": 3182917058194750998,
|
||||
"R": -1
|
||||
}],
|
||||
"instances": [],
|
||||
"uses": []
|
||||
}, {
|
||||
|
@ -11,22 +11,42 @@ OUTPUT:
|
||||
{
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 11072669167287398027,
|
||||
"detailed_name": "",
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 3948666349864691553,
|
||||
"detailed_name": "Foo",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"short_name": "Foo",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"spell": "2:3-3:15|11072669167287398027|2|2",
|
||||
"extent": "2:3-3:15|11072669167287398027|2|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [15768138241775955040, 3182917058194750998],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2type": [{
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [3182917058194750998],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 8224244241460152567,
|
||||
"detailed_name": "Foo",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "Foo",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "2:3-3:15|11072669167287398027|2|2",
|
||||
"extent": "2:3-3:15|11072669167287398027|2|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [15768138241775955040],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 11072669167287398027,
|
||||
"detailed_name": "namespace ns {\n}",
|
||||
"qual_name_offset": 10,
|
||||
@ -38,7 +58,13 @@ OUTPUT:
|
||||
"derived": [],
|
||||
"types": [14042997404480181958],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"vars": [{
|
||||
"L": 15768138241775955040,
|
||||
"R": -1
|
||||
}, {
|
||||
"L": 3182917058194750998,
|
||||
"R": -1
|
||||
}],
|
||||
"instances": [],
|
||||
"uses": []
|
||||
}, {
|
||||
@ -56,7 +82,7 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [15768138241775955040, 3182917058194750998],
|
||||
"instances": [],
|
||||
"uses": ["5:3-5:6|11072669167287398027|2|4", "6:3-6:6|11072669167287398027|2|4"]
|
||||
}],
|
||||
"usr2var": [{
|
||||
@ -67,7 +93,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "6:13-6:14|11072669167287398027|2|514",
|
||||
"extent": "6:3-6:14|11072669167287398027|2|0",
|
||||
"type": 14042997404480181958,
|
||||
"type": 3948666349864691553,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -79,7 +105,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "5:12-5:13|11072669167287398027|2|514",
|
||||
"extent": "5:3-5:13|11072669167287398027|2|0",
|
||||
"type": 14042997404480181958,
|
||||
"type": 8224244241460152567,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
|
@ -75,20 +75,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 9201299975592934124,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [15477793821005285152, 4917621020431490070],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 17498190318698490707,
|
||||
"detailed_name": "void foo(T Value)",
|
||||
@ -102,7 +88,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [17826688417349629938],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
@ -135,6 +121,23 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [13914496963221806870],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 218068462278884837,
|
||||
"detailed_name": "template <typename T, typename ...Args> class function<type-parameter-0-0 (type-parameter-0-1...)> {}",
|
||||
"qual_name_offset": 46,
|
||||
"short_name": "function",
|
||||
"kind": 5,
|
||||
"declarations": [],
|
||||
"spell": "5:7-5:15|0|1|2",
|
||||
"extent": "4:1-5:30|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [15019211479263750068],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 1663022413889915338,
|
||||
"detailed_name": "template<> class vector<Z2, allocator<Z2>> {}",
|
||||
@ -152,6 +155,23 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [15931696253641284761],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 3231449734830406187,
|
||||
"detailed_name": "function",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "function",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "4:1-5:30|0|1|2",
|
||||
"extent": "4:1-5:30|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [2933643612409209903],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 5760043510674081814,
|
||||
"detailed_name": "struct Z1 {}",
|
||||
@ -180,11 +200,11 @@ OUTPUT:
|
||||
"extent": "12:1-14:2|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [1663022413889915338],
|
||||
"derived": [16155717907537731864, 1663022413889915338],
|
||||
"types": [],
|
||||
"funcs": [18107614608385228556],
|
||||
"vars": [],
|
||||
"instances": [5792869548777559988, 86949563628772958, 3566687051827176322],
|
||||
"instances": [],
|
||||
"uses": ["17:7-17:13|0|1|4", "26:7-26:13|0|1|4", "30:1-30:7|0|1|4", "31:1-31:7|0|1|4", "32:1-32:7|0|1|4", "33:1-33:7|0|1|4"]
|
||||
}, {
|
||||
"usr": 9201299975592934124,
|
||||
@ -220,6 +240,57 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": ["26:14-26:16|0|1|4", "33:8-33:10|0|1|4"]
|
||||
}, {
|
||||
"usr": 11153492883079050853,
|
||||
"detailed_name": "vector",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "vector",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "16:1-17:20|0|1|2",
|
||||
"extent": "16:1-17:20|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [86949563628772958],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 13322943937025195708,
|
||||
"detailed_name": "vector",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "vector",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "11:1-14:2|0|1|2",
|
||||
"extent": "11:1-14:2|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [5792869548777559988],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 14111105212951082474,
|
||||
"detailed_name": "T",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "T",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "38:11-38:21|17498190318698490707|3|2",
|
||||
"extent": "38:11-38:21|17498190318698490707|3|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [17826688417349629938],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 15019211479263750068,
|
||||
"detailed_name": "class function",
|
||||
@ -229,12 +300,29 @@ OUTPUT:
|
||||
"declarations": ["2:7-2:15|0|1|1"],
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [218068462278884837],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": ["5:7-5:15|0|1|4", "7:1-7:9|0|1|4"]
|
||||
}, {
|
||||
"usr": 15440970074034693939,
|
||||
"detailed_name": "vector",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "vector",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "21:1-21:26|0|1|2",
|
||||
"extent": "21:1-21:26|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [2933643612409209903],
|
||||
"uses": ["5:7-5:15|0|1|4", "7:1-7:9|0|1|4"]
|
||||
"instances": [3566687051827176322],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 15695704394170757108,
|
||||
"detailed_name": "class allocator",
|
||||
@ -250,6 +338,23 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": ["11:39-11:48|0|1|4"]
|
||||
}, {
|
||||
"usr": 16155717907537731864,
|
||||
"detailed_name": "template <typename T> class vector<type-parameter-0-0 *, allocator<type-parameter-0-0 *>> {}",
|
||||
"qual_name_offset": 28,
|
||||
"short_name": "vector",
|
||||
"kind": 5,
|
||||
"declarations": [],
|
||||
"spell": "17:7-17:13|0|1|2",
|
||||
"extent": "16:1-17:20|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [7440942986741176606],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": []
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 86949563628772958,
|
||||
@ -259,7 +364,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "31:14-31:17|0|1|2",
|
||||
"extent": "31:1-31:17|0|1|0",
|
||||
"type": 7440942986741176606,
|
||||
"type": 11153492883079050853,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -271,7 +376,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "7:21-7:22|0|1|2",
|
||||
"extent": "7:1-7:22|0|1|0",
|
||||
"type": 15019211479263750068,
|
||||
"type": 3231449734830406187,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -283,7 +388,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "32:12-32:15|0|1|2",
|
||||
"extent": "32:1-32:15|0|1|0",
|
||||
"type": 7440942986741176606,
|
||||
"type": 15440970074034693939,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -308,7 +413,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "30:14-30:16|0|1|2",
|
||||
"extent": "30:1-30:16|0|1|0",
|
||||
"type": 7440942986741176606,
|
||||
"type": 13322943937025195708,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -358,7 +463,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "39:12-39:17|17498190318698490707|3|514",
|
||||
"extent": "39:10-39:17|17498190318698490707|3|0",
|
||||
"type": 0,
|
||||
"type": 14111105212951082474,
|
||||
"uses": [],
|
||||
"kind": 253,
|
||||
"storage": 0
|
||||
|
@ -24,8 +24,8 @@ OUTPUT:
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 6995843774014807426,
|
||||
"detailed_name": "void Template<void>::Foo()",
|
||||
"qual_name_offset": 5,
|
||||
"detailed_name": "template <> void Template<void>::Foo()",
|
||||
"qual_name_offset": 31,
|
||||
"short_name": "Foo",
|
||||
"kind": 6,
|
||||
"storage": 0,
|
||||
|
@ -50,6 +50,23 @@ OUTPUT:
|
||||
"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 {}",
|
||||
@ -99,8 +116,25 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [16721564935990383768, 12028309045033782423],
|
||||
"instances": [],
|
||||
"uses": ["9:9-9:14|10528472276654770367|2|4", "10:9-10:14|10528472276654770367|2|4"]
|
||||
}, {
|
||||
"usr": 15961308565836244174,
|
||||
"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": [12028309045033782423],
|
||||
"uses": []
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 12028309045033782423,
|
||||
@ -110,7 +144,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "10:15-10:16|0|1|2",
|
||||
"extent": "10:1-10:16|0|1|0",
|
||||
"type": 13938528237873543349,
|
||||
"type": 15961308565836244174,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -122,7 +156,7 @@ OUTPUT:
|
||||
"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
|
||||
|
@ -11,21 +11,7 @@ OUTPUT:
|
||||
{
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 10528472276654770367,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [13545144895171991916],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 53,
|
||||
"detailed_name": "",
|
||||
|
@ -11,6 +11,23 @@ OUTPUT:
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 5123806965838456033,
|
||||
"detailed_name": "Foo",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "Foo",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:1-2:13|0|1|2",
|
||||
"extent": "1:1-2:13|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [16721564935990383768],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 10528472276654770367,
|
||||
"detailed_name": "class Foo {}",
|
||||
"qual_name_offset": 6,
|
||||
@ -25,8 +42,25 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [16721564935990383768, 12028309045033782423],
|
||||
"instances": [],
|
||||
"uses": ["4:1-4:4|0|1|4", "5:1-5:4|0|1|4"]
|
||||
}, {
|
||||
"usr": 14134940367505932005,
|
||||
"detailed_name": "Foo",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "Foo",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:1-2:13|0|1|2",
|
||||
"extent": "1:1-2:13|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [12028309045033782423],
|
||||
"uses": []
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 12028309045033782423,
|
||||
@ -36,7 +70,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "5:11-5:12|0|1|2",
|
||||
"extent": "5:1-5:12|0|1|0",
|
||||
"type": 10528472276654770367,
|
||||
"type": 14134940367505932005,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -48,7 +82,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "4:10-4:11|0|1|2",
|
||||
"extent": "4:1-4:11|0|1|0",
|
||||
"type": 10528472276654770367,
|
||||
"type": 5123806965838456033,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
|
@ -53,6 +53,23 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [16721564935990383768],
|
||||
"uses": ["7:1-7:2|0|1|4", "7:11-7:12|0|1|4"]
|
||||
}, {
|
||||
"usr": 11919899838872947844,
|
||||
"detailed_name": "T",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "T",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "4:10-4:20|0|1|2",
|
||||
"extent": "4:10-4:20|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [8096973118640070624],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 13892793056005362145,
|
||||
"detailed_name": "enum B {\n}",
|
||||
@ -80,7 +97,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "5:3-5:6|0|1|2",
|
||||
"extent": "5:1-5:12|0|1|0",
|
||||
"type": 0,
|
||||
"type": 11919899838872947844,
|
||||
"uses": ["7:7-7:10|0|1|12", "8:7-8:10|0|1|12"],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
|
@ -8,35 +8,7 @@ OUTPUT:
|
||||
{
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 1428566502523368801,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [3348817847649945564, 4821094820988543895, 15292551660437765731],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 17937907487590875128,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [1963212417280098348],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 82,
|
||||
"detailed_name": "",
|
||||
|
@ -8,21 +8,7 @@ OUTPUT:
|
||||
{
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 8501689086387244262,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [9529311430721959843, 8804696910588009104],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 37,
|
||||
"detailed_name": "",
|
||||
|
@ -17,20 +17,6 @@ OUTPUT:
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 8501689086387244262,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [9529311430721959843, 8804696910588009104],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 13982179977217945200,
|
||||
"detailed_name": "void act(Foo *)",
|
||||
"qual_name_offset": 5,
|
||||
|
@ -48,10 +48,10 @@ OUTPUT:
|
||||
"detailed_name": "MACRO_CALL",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "MACRO_CALL",
|
||||
"hover": "#define MACRO_CALL",
|
||||
"hover": "#define MACRO_CALL(e) e",
|
||||
"declarations": [],
|
||||
"spell": "1:9-1:19|0|1|2",
|
||||
"extent": "1:9-1:19|0|1|2",
|
||||
"extent": "1:9-1:24|0|1|0",
|
||||
"type": 0,
|
||||
"uses": ["6:3-6:33|0|1|4"],
|
||||
"kind": 255,
|
||||
|
@ -41,7 +41,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [16088407831770615719],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
|
@ -25,7 +25,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [4636142131003982569],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
@ -63,10 +63,10 @@ OUTPUT:
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 4636142131003982569,
|
||||
"detailed_name": "auto x",
|
||||
"qual_name_offset": 5,
|
||||
"detailed_name": "void (Foo::*)() x",
|
||||
"qual_name_offset": 16,
|
||||
"short_name": "x",
|
||||
"hover": "auto x = &Foo::Used",
|
||||
"hover": "void (Foo::*)() x = &Foo::Used",
|
||||
"declarations": [],
|
||||
"spell": "6:8-6:9|9376923949268137283|3|2",
|
||||
"extent": "6:3-6:22|9376923949268137283|3|0",
|
||||
|
@ -25,7 +25,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [14045150712868309451],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
|
@ -27,20 +27,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": ["6:11-6:17|0|1|36"],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 15041163540773201510,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [4220150017963593039],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2type": [{
|
||||
"usr": 53,
|
||||
|
@ -24,7 +24,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [16229832321010999607],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
|
@ -28,7 +28,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [3364438781074774169],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
@ -47,8 +47,25 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [12857919739649552168, 18075066956054788088, 3364438781074774169],
|
||||
"instances": [],
|
||||
"uses": ["6:8-6:18|0|1|4", "7:8-7:18|0|1|4", "9:1-9:11|0|1|4", "10:3-10:13|0|1|4"]
|
||||
}, {
|
||||
"usr": 4186953406371619898,
|
||||
"detailed_name": "unique_ptr",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "unique_ptr",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:1-2:20|0|1|2",
|
||||
"extent": "1:1-2:20|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [18075066956054788088, 3364438781074774169],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 4750332761459066907,
|
||||
"detailed_name": "struct S {}",
|
||||
@ -66,6 +83,23 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": ["7:19-7:20|0|1|4", "9:12-9:13|0|1|4", "10:14-10:15|0|1|4"]
|
||||
}, {
|
||||
"usr": 16848604152578034754,
|
||||
"detailed_name": "unique_ptr",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "unique_ptr",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:1-2:20|0|1|2",
|
||||
"extent": "1:1-2:20|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [12857919739649552168],
|
||||
"uses": []
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 3364438781074774169,
|
||||
@ -75,7 +109,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "10:18-10:23|16359708726068806331|3|2",
|
||||
"extent": "10:3-10:23|16359708726068806331|3|0",
|
||||
"type": 3286534761799572592,
|
||||
"type": 4186953406371619898,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -87,7 +121,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "6:25-6:27|0|1|2",
|
||||
"extent": "6:1-6:27|0|1|0",
|
||||
"type": 3286534761799572592,
|
||||
"type": 16848604152578034754,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 2
|
||||
@ -99,7 +133,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "7:22-7:24|0|1|2",
|
||||
"extent": "7:1-7:24|0|1|0",
|
||||
"type": 3286534761799572592,
|
||||
"type": 4186953406371619898,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 2
|
||||
|
@ -144,7 +144,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [500112618220246],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
@ -191,7 +191,7 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [2933643612409209903, 500112618220246],
|
||||
"instances": [],
|
||||
"uses": ["15:8-15:18|0|1|4", "15:19-15:29|0|1|4", "33:1-33:11|0|1|4", "33:12-33:22|0|1|4", "33:52-33:62|0|1|4", "54:3-54:13|0|1|4", "54:14-54:24|0|1|4", "65:3-65:13|0|1|4", "79:1-79:11|0|1|4"]
|
||||
}, {
|
||||
"usr": 15041163540773201510,
|
||||
@ -210,6 +210,23 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"instances": [],
|
||||
"uses": ["79:21-79:24|0|1|4"]
|
||||
}, {
|
||||
"usr": 18153735331422331128,
|
||||
"detailed_name": "unique_ptr",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "unique_ptr",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:1-2:17|0|1|2",
|
||||
"extent": "1:1-2:17|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [2933643612409209903, 500112618220246],
|
||||
"uses": []
|
||||
}],
|
||||
"usr2var": [{
|
||||
"usr": 500112618220246,
|
||||
@ -219,7 +236,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "54:39-54:44|18320186404467436976|3|2",
|
||||
"extent": "54:3-54:44|18320186404467436976|3|0",
|
||||
"type": 14209198335088845323,
|
||||
"type": 18153735331422331128,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
@ -229,7 +246,7 @@ OUTPUT:
|
||||
"qual_name_offset": 42,
|
||||
"short_name": "f",
|
||||
"declarations": ["15:43-15:44|0|1|1"],
|
||||
"type": 14209198335088845323,
|
||||
"type": 18153735331422331128,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 1
|
||||
|
@ -26,8 +26,25 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [3398408600781120939],
|
||||
"instances": [],
|
||||
"uses": ["6:8-6:18|0|1|4"]
|
||||
}, {
|
||||
"usr": 4186953406371619898,
|
||||
"detailed_name": "unique_ptr",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "unique_ptr",
|
||||
"kind": 26,
|
||||
"declarations": [],
|
||||
"spell": "1:1-2:20|0|1|2",
|
||||
"extent": "1:1-2:20|0|1|0",
|
||||
"alias_of": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [3398408600781120939],
|
||||
"uses": []
|
||||
}, {
|
||||
"usr": 4750332761459066907,
|
||||
"detailed_name": "struct S",
|
||||
@ -52,7 +69,7 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "6:22-6:25|0|1|2",
|
||||
"extent": "6:1-6:25|0|1|0",
|
||||
"type": 3286534761799572592,
|
||||
"type": 4186953406371619898,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 2
|
||||
|
@ -11,21 +11,7 @@ OUTPUT:
|
||||
{
|
||||
"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": [14314859014962085433, 14727441168849658842],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 8508299082070213750,
|
||||
"detailed_name": "struct ImplementedType {}",
|
||||
|
@ -24,7 +24,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [16374832544037266261, 2580122838476012357],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -21,7 +21,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [13058491096576226774, 11055777568039014776],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -26,7 +26,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [13823260660189154978],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -24,7 +24,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [7997456978847868736, 17228576662112939520, 15429032129697337561, 6081981442495435784, 5004072032239834773, 14939253431683105646],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -27,7 +27,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [16380484338511689669],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -32,7 +32,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [8039186520399841081],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
@ -49,20 +49,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": ["14:14-14:17|0|1|8228"],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 15041163540773201510,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [11489549839875479478, 9648311402855509901, 11489549839875479478],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 18319417758892371313,
|
||||
"detailed_name": "void called(int a)",
|
||||
@ -144,7 +130,6 @@ OUTPUT:
|
||||
"detailed_name": "static int Foo::static_var",
|
||||
"qual_name_offset": 11,
|
||||
"short_name": "static_var",
|
||||
"hover": "int Foo::static_var = 0",
|
||||
"declarations": ["6:14-6:24|15041163540773201510|2|513"],
|
||||
"spell": "10:10-10:20|15041163540773201510|2|514",
|
||||
"extent": "10:1-10:24|0|1|0",
|
||||
|
@ -41,7 +41,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [9121974011454213596],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -35,7 +35,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [14669930844300034456],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
@ -52,20 +52,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": ["16:3-16:9|0|1|8228"],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 15041163540773201510,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [4220150017963593039, 3873837747174060388],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 17175780305784503374,
|
||||
"detailed_name": "void accept(int)",
|
||||
|
@ -29,20 +29,6 @@ OUTPUT:
|
||||
"vars": [],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 15041163540773201510,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [8599782646965457351],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}, {
|
||||
"usr": 17175780305784503374,
|
||||
"detailed_name": "void accept(int)",
|
||||
|
@ -12,21 +12,7 @@ OUTPUT:
|
||||
{
|
||||
"includes": [],
|
||||
"skipped_ranges": [],
|
||||
"usr2func": [{
|
||||
"usr": 10028537921178202800,
|
||||
"detailed_name": "",
|
||||
"qual_name_offset": 0,
|
||||
"short_name": "",
|
||||
"kind": 0,
|
||||
"storage": 0,
|
||||
"declarations": [],
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [7057400933868440116, 7057400933868440116],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 5792006888140599735,
|
||||
"detailed_name": "enum VarType {\n}",
|
||||
@ -67,7 +53,7 @@ OUTPUT:
|
||||
"detailed_name": "static constexpr VarType Holder::static_var",
|
||||
"qual_name_offset": 25,
|
||||
"short_name": "static_var",
|
||||
"hover": "static constexpr VarType Holder::static_var = (VarType)0",
|
||||
"hover": "static constexpr VarType Holder::static_var = (VarType)0x0",
|
||||
"declarations": ["4:28-4:38|10028537921178202800|2|513"],
|
||||
"spell": "7:23-7:33|10028537921178202800|2|514",
|
||||
"extent": "7:1-7:33|0|1|0",
|
||||
|
@ -19,7 +19,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [10063793875496522529],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -20,7 +20,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [14014650769929566957],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -25,7 +25,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [13311055950748663970, 14036425367303419504],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -25,7 +25,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [11608231465452906059, 6997229590862003559],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -6,21 +6,7 @@ OUTPUT:
|
||||
{
|
||||
"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": [13799811842374292251],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 15041163540773201510,
|
||||
"detailed_name": "class Foo {}",
|
||||
|
@ -8,21 +8,7 @@ OUTPUT:
|
||||
{
|
||||
"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": [5844987037615239736, 5844987037615239736],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 15041163540773201510,
|
||||
"detailed_name": "class Foo {}",
|
||||
@ -46,7 +32,6 @@ OUTPUT:
|
||||
"detailed_name": "static Foo *Foo::member",
|
||||
"qual_name_offset": 12,
|
||||
"short_name": "member",
|
||||
"hover": "Foo *Foo::member = nullptr",
|
||||
"declarations": ["2:15-2:21|15041163540773201510|2|513"],
|
||||
"spell": "4:11-4:17|15041163540773201510|2|514",
|
||||
"extent": "4:1-4:27|0|1|0",
|
||||
|
@ -6,21 +6,7 @@ OUTPUT:
|
||||
{
|
||||
"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": [5844987037615239736],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
"usr2func": [],
|
||||
"usr2type": [{
|
||||
"usr": 53,
|
||||
"detailed_name": "",
|
||||
|
@ -22,7 +22,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [10601729374837386290, 18422884837902130475],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
@ -41,7 +41,7 @@ OUTPUT:
|
||||
"types": [],
|
||||
"funcs": [],
|
||||
"vars": [],
|
||||
"instances": [18422884837902130475],
|
||||
"instances": [10601729374837386290, 18422884837902130475],
|
||||
"uses": ["3:16-3:19|0|1|4", "4:17-4:20|0|1|4"]
|
||||
}],
|
||||
"usr2var": [{
|
||||
@ -53,16 +53,16 @@ OUTPUT:
|
||||
"declarations": [],
|
||||
"spell": "3:8-3:9|880549676430489861|3|2",
|
||||
"extent": "3:3-3:21|880549676430489861|3|0",
|
||||
"type": 0,
|
||||
"type": 15041163540773201510,
|
||||
"uses": [],
|
||||
"kind": 13,
|
||||
"storage": 0
|
||||
}, {
|
||||
"usr": 18422884837902130475,
|
||||
"detailed_name": "auto *y",
|
||||
"qual_name_offset": 6,
|
||||
"detailed_name": "Foo *y",
|
||||
"qual_name_offset": 5,
|
||||
"short_name": "y",
|
||||
"hover": "auto *y = new Foo()",
|
||||
"hover": "Foo *y = new Foo()",
|
||||
"declarations": [],
|
||||
"spell": "4:9-4:10|880549676430489861|3|2",
|
||||
"extent": "4:3-4:22|880549676430489861|3|0",
|
||||
|
@ -22,7 +22,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [13198746475679542317],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -20,7 +20,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [8730439006497971620, 2525014371090380500],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -25,7 +25,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [1894874819807168345, 4508045017817092115],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -19,7 +19,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [5875271969926422921, 11404600766177939811],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
@ -24,7 +24,7 @@ OUTPUT:
|
||||
"declaring_type": 0,
|
||||
"bases": [],
|
||||
"derived": [],
|
||||
"vars": [],
|
||||
"vars": [6975456769752895964],
|
||||
"uses": [],
|
||||
"callees": []
|
||||
}],
|
||||
|
366
src/indexer.cc
366
src/indexer.cc
@ -33,7 +33,12 @@ struct IndexParam {
|
||||
std::unordered_map<llvm::sys::fs::UniqueID, std::string> SeenUniqueID;
|
||||
std::unordered_map<std::string, FileContents> file_contents;
|
||||
std::unordered_map<std::string, int64_t> file2write_time;
|
||||
llvm::DenseMap<const Decl*, Usr> Decl2usr;
|
||||
struct DeclInfo {
|
||||
Usr usr;
|
||||
std::string short_name;
|
||||
std::string qualified;
|
||||
};
|
||||
std::unordered_map<const Decl*, DeclInfo> Decl2Info;
|
||||
|
||||
ASTUnit& Unit;
|
||||
ASTContext* Ctx;
|
||||
@ -68,6 +73,20 @@ struct IndexParam {
|
||||
}
|
||||
};
|
||||
|
||||
StringRef GetSourceInRange(const SourceManager &SM, const LangOptions &LangOpts,
|
||||
SourceRange R) {
|
||||
SourceLocation BLoc = R.getBegin(), ELoc = R.getEnd();
|
||||
std::pair<FileID, unsigned> BInfo = SM.getDecomposedLoc(BLoc),
|
||||
EInfo = SM.getDecomposedLoc(ELoc);
|
||||
bool invalid = false;
|
||||
StringRef Buf = SM.getBufferData(BInfo.first, &invalid);
|
||||
if (invalid)
|
||||
return "";
|
||||
return Buf.substr(BInfo.second, EInfo.second + Lexer::MeasureTokenLength(
|
||||
ELoc, SM, LangOpts) -
|
||||
BInfo.second);
|
||||
}
|
||||
|
||||
Range FromSourceRange(const SourceManager &SM, const LangOptions &LangOpts,
|
||||
SourceRange R, llvm::sys::fs::UniqueID *UniqueID,
|
||||
bool token) {
|
||||
@ -120,56 +139,65 @@ SymbolKind GetSymbolKind(const Decl* D) {
|
||||
case Decl::NamespaceAlias:
|
||||
case Decl::ClassTemplate:
|
||||
case Decl::TypeAliasTemplate:
|
||||
case Decl::TemplateTemplateParm:
|
||||
case Decl::Enum:
|
||||
case Decl::Record:
|
||||
case Decl::CXXRecord:
|
||||
case Decl::ClassTemplateSpecialization:
|
||||
case Decl::ClassTemplatePartialSpecialization:
|
||||
case Decl::TypeAlias:
|
||||
case Decl::Typedef:
|
||||
case Decl::UnresolvedUsingTypename:
|
||||
return SymbolKind::Type;
|
||||
case Decl::VarTemplate:
|
||||
case Decl::Binding:
|
||||
case Decl::Field:
|
||||
case Decl::Var:
|
||||
case Decl::ParmVar:
|
||||
case Decl::ImplicitParam:
|
||||
case Decl::Decomposition:
|
||||
case Decl::EnumConstant:
|
||||
case Decl::UnresolvedUsingValue:
|
||||
return SymbolKind::Var;
|
||||
default:
|
||||
return SymbolKind::Invalid;
|
||||
}
|
||||
}
|
||||
|
||||
// clang/lib/AST/DeclPrinter.cpp
|
||||
QualType GetBaseType(QualType T, bool deduce_auto) {
|
||||
QualType BaseType = T;
|
||||
while (!BaseType.isNull() && !BaseType->isSpecifierType()) {
|
||||
if (const PointerType *PTy = BaseType->getAs<PointerType>())
|
||||
BaseType = PTy->getPointeeType();
|
||||
else if (const BlockPointerType *BPy = BaseType->getAs<BlockPointerType>())
|
||||
BaseType = BPy->getPointeeType();
|
||||
else if (const ArrayType* ATy = dyn_cast<ArrayType>(BaseType))
|
||||
BaseType = ATy->getElementType();
|
||||
else if (const VectorType *VTy = BaseType->getAs<VectorType>())
|
||||
BaseType = VTy->getElementType();
|
||||
else if (const ReferenceType *RTy = BaseType->getAs<ReferenceType>())
|
||||
BaseType = RTy->getPointeeType();
|
||||
else if (const ParenType *PTy = BaseType->getAs<ParenType>())
|
||||
BaseType = PTy->desugar();
|
||||
else if (deduce_auto) {
|
||||
if (const AutoType *ATy = BaseType->getAs<AutoType>())
|
||||
BaseType = ATy->getDeducedType();
|
||||
else
|
||||
break;
|
||||
}
|
||||
else
|
||||
break;
|
||||
}
|
||||
return BaseType;
|
||||
}
|
||||
|
||||
const Decl* GetTypeDecl(QualType T) {
|
||||
Decl *D = nullptr;
|
||||
const Type *TP;
|
||||
for(;;) {
|
||||
T = T.getUnqualifiedType();
|
||||
TP = T.getTypePtrOrNull();
|
||||
if (!TP)
|
||||
return D;
|
||||
switch (TP->getTypeClass()) {
|
||||
case Type::Pointer:
|
||||
T = cast<PointerType>(TP)->getPointeeType();
|
||||
continue;
|
||||
case Type::BlockPointer:
|
||||
T = cast<BlockPointerType>(TP)->getPointeeType();
|
||||
continue;
|
||||
case Type::LValueReference:
|
||||
case Type::RValueReference:
|
||||
T = cast<ReferenceType>(TP)->getPointeeType();
|
||||
continue;
|
||||
case Type::ObjCObjectPointer:
|
||||
T = cast<ObjCObjectPointerType>(TP)->getPointeeType();
|
||||
continue;
|
||||
case Type::MemberPointer:
|
||||
T = cast<MemberPointerType>(TP)->getPointeeType();
|
||||
continue;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
T = GetBaseType(T.getUnqualifiedType(), true);
|
||||
const Type* TP = T.getTypePtrOrNull();
|
||||
if (!TP)
|
||||
return nullptr;
|
||||
|
||||
try_again:
|
||||
switch (TP->getTypeClass()) {
|
||||
@ -186,6 +214,9 @@ try_again:
|
||||
case Type::Enum:
|
||||
D = cast<TagType>(TP)->getDecl();
|
||||
break;
|
||||
case Type::TemplateTypeParm:
|
||||
D = cast<TemplateTypeParmType>(TP)->getDecl();
|
||||
break;
|
||||
case Type::TemplateSpecialization:
|
||||
if (const RecordType *Record = TP->getAs<RecordType>())
|
||||
D = Record->getDecl();
|
||||
@ -313,15 +344,23 @@ public:
|
||||
return ret;
|
||||
}
|
||||
|
||||
Usr GetUsr(const Decl* D) const {
|
||||
Usr GetUsr(const Decl *D, IndexParam::DeclInfo **info = nullptr) const {
|
||||
D = D->getCanonicalDecl();
|
||||
auto R = param.Decl2usr.try_emplace(D);
|
||||
auto R = param.Decl2Info.try_emplace(D);
|
||||
if (R.second) {
|
||||
SmallString<256> USR;
|
||||
index::generateUSRForDecl(D, USR);
|
||||
R.first->second = HashUsr(USR);
|
||||
auto &info = R.first->second;
|
||||
info.usr = HashUsr(USR);
|
||||
if (auto *ND = dyn_cast<NamedDecl>(D)) {
|
||||
info.short_name = ND->getNameAsString();
|
||||
info.qualified = ND->getQualifiedNameAsString();
|
||||
SimplifyAnonymous(info.qualified);
|
||||
}
|
||||
}
|
||||
return R.first->second;
|
||||
if (info)
|
||||
*info = &R.first->second;
|
||||
return R.first->second.usr;
|
||||
}
|
||||
|
||||
Use GetUse(IndexFile *db, Range range, const DeclContext *DC,
|
||||
@ -367,13 +406,10 @@ public:
|
||||
|
||||
template <typename Def>
|
||||
void SetName(const Decl *D, std::string_view short_name,
|
||||
std::string_view qualified, Def &def, bool hover = false) {
|
||||
std::string_view qualified, Def &def) {
|
||||
SmallString<256> Str;
|
||||
llvm::raw_svector_ostream OS(Str);
|
||||
PrintingPolicy PP = GetDefaultPolicy();
|
||||
if (hover)
|
||||
PP.SuppressInitializers = false;
|
||||
D->print(OS, PP);
|
||||
D->print(OS, GetDefaultPolicy());
|
||||
|
||||
std::string name = OS.str();
|
||||
SimplifyAnonymous(name);
|
||||
@ -381,44 +417,96 @@ public:
|
||||
if (i == std::string::npos) {
|
||||
// e.g. operator type-parameter-1
|
||||
i = 0;
|
||||
if (!hover)
|
||||
def.short_name_offset = 0;
|
||||
} else if (short_name.size()) {
|
||||
def.short_name_offset = 0;
|
||||
} else if (short_name.size() && (!i || name[i - 1] != ':')) {
|
||||
name.replace(i, short_name.size(), qualified);
|
||||
if (!hover)
|
||||
def.short_name_offset = i + qualified.size() - short_name.size();
|
||||
def.short_name_offset = i + qualified.size() - short_name.size();
|
||||
} else {
|
||||
if (!hover)
|
||||
def.short_name_offset = i;
|
||||
def.short_name_offset = i;
|
||||
}
|
||||
if (hover) {
|
||||
if (name != def.detailed_name)
|
||||
def.hover = Intern(name);
|
||||
} else {
|
||||
def.short_name_size = short_name.size();
|
||||
for (int paren = 0; i; i--) {
|
||||
// Skip parentheses in "(anon struct)::name"
|
||||
if (name[i - 1] == ')')
|
||||
paren++;
|
||||
else if (name[i - 1] == '(')
|
||||
paren--;
|
||||
else if (!(paren > 0 || isalnum(name[i - 1]) || name[i - 1] == '_' ||
|
||||
name[i - 1] == ':'))
|
||||
break;
|
||||
}
|
||||
def.qual_name_offset = i;
|
||||
def.detailed_name = Intern(name);
|
||||
}
|
||||
|
||||
void SetVarName(const Decl *D, std::string_view short_name,
|
||||
std::string_view qualified, IndexVar::Def &def) {
|
||||
QualType T;
|
||||
const Expr* init = nullptr;
|
||||
if (auto *VD = dyn_cast<VarDecl>(D)) {
|
||||
T = VD->getType();
|
||||
init = VD->getAnyInitializer();
|
||||
def.storage = VD->getStorageClass();
|
||||
} else if (auto *FD = dyn_cast<FieldDecl>(D)) {
|
||||
T = FD->getType();
|
||||
init = FD->getInClassInitializer();
|
||||
}
|
||||
auto BT = GetBaseType(T, false);
|
||||
if (!BT.isNull() && BT->getAs<AutoType>()) {
|
||||
SmallString<256> Str;
|
||||
llvm::raw_svector_ostream OS(Str);
|
||||
PrintingPolicy PP = GetDefaultPolicy();
|
||||
T.print(OS, PP);
|
||||
if (Str.size() &&
|
||||
(Str.back() != ' ' && Str.back() != '*' && Str.back() != '&'))
|
||||
Str += ' ';
|
||||
def.qual_name_offset = Str.size();
|
||||
def.short_name_offset = Str.size() + qualified.size() - short_name.size();
|
||||
def.short_name_size = short_name.size();
|
||||
for (int paren = 0; i; i--) {
|
||||
// Skip parentheses in "(anon struct)::name"
|
||||
if (name[i - 1] == ')')
|
||||
paren++;
|
||||
else if (name[i - 1] == '(')
|
||||
paren--;
|
||||
else if (!(paren > 0 || isalnum(name[i - 1]) || name[i - 1] == '_' ||
|
||||
name[i - 1] == ':'))
|
||||
break;
|
||||
}
|
||||
def.qual_name_offset = i;
|
||||
def.detailed_name = Intern(name);
|
||||
Str += StringRef(qualified.data(), qualified.size());
|
||||
def.detailed_name = Intern(Str.str());
|
||||
} else {
|
||||
SetName(D, short_name, qualified, def);
|
||||
}
|
||||
if (init) {
|
||||
SourceManager &SM = Ctx->getSourceManager();
|
||||
const LangOptions& Lang = Ctx->getLangOpts();
|
||||
SourceRange R = init->getSourceRange();
|
||||
SourceLocation L = D->getLocation();
|
||||
if (!SM.isBeforeInTranslationUnit(L, R.getBegin()))
|
||||
return;
|
||||
StringRef Buf = GetSourceInRange(SM, Lang, R);
|
||||
Twine T =
|
||||
def.detailed_name +
|
||||
(Buf.size() && Buf[0] == ':' ? Twine(" ", Buf) : Twine(" = ", Buf));
|
||||
def.hover =
|
||||
def.storage == SC_Static && strncmp(def.detailed_name, "static ", 7)
|
||||
? Intern(("static " + T).str())
|
||||
: Intern(T.str());
|
||||
}
|
||||
}
|
||||
|
||||
void AddMacroUse(SourceManager &SM, std::vector<Use> &uses,
|
||||
void AddMacroUse(SourceManager &SM, Usr usr, SymbolKind kind,
|
||||
SourceLocation Spell) const {
|
||||
const FileEntry *FE = SM.getFileEntryForID(SM.getFileID(Spell));
|
||||
if (FE) {
|
||||
IndexFile *db = param.ConsumeFile(*FE);
|
||||
Range spell =
|
||||
FromTokenRange(SM, Ctx->getLangOpts(), SourceRange(Spell, Spell));
|
||||
uses.push_back(GetUse(db, spell, nullptr, Role::Dynamic));
|
||||
if (!FE) return;
|
||||
IndexFile *db = param.ConsumeFile(*FE);
|
||||
if (!db) return;
|
||||
Range spell =
|
||||
FromTokenRange(SM, Ctx->getLangOpts(), SourceRange(Spell, Spell));
|
||||
Use use = GetUse(db, spell, nullptr, Role::Dynamic);
|
||||
switch (kind) {
|
||||
case SymbolKind::Func:
|
||||
db->ToFunc(usr).uses.push_back(use);
|
||||
break;
|
||||
case SymbolKind::Type:
|
||||
db->ToType(usr).uses.push_back(use);
|
||||
break;
|
||||
case SymbolKind::Var:
|
||||
db->ToVar(usr).uses.push_back(use);
|
||||
break;
|
||||
default:
|
||||
llvm_unreachable("");
|
||||
}
|
||||
}
|
||||
|
||||
@ -450,17 +538,20 @@ public:
|
||||
SourceLocation Spell = SM.getSpellingLoc(Loc);
|
||||
Loc = SM.getFileLoc(Loc);
|
||||
Range loc = FromTokenRange(SM, Lang, SourceRange(Loc, Loc));
|
||||
const FileEntry *FE = SM.getFileEntryForID(SM.getFileID(Loc));
|
||||
FileID LocFID = SM.getFileID(Loc);
|
||||
const FileEntry *FE = SM.getFileEntryForID(LocFID);
|
||||
if (!FE) {
|
||||
// TODO
|
||||
#if LLVM_VERSION_MAJOR < 7
|
||||
auto P = SM.getExpansionRange(Loc);
|
||||
loc = FromCharRange(SM, Ctx->getLangOpts(), SourceRange(P.first, P.second));
|
||||
FE = SM.getFileEntryForID(SM.getFileID(P.first));
|
||||
LocFID = SM.getFileID(P.first);
|
||||
FE = SM.getFileEntryForID(LocFID);
|
||||
#else
|
||||
auto R = SM.getExpansionRange(Loc);
|
||||
loc = FromTokenRange(SM, Lang, R.getAsRange());
|
||||
FE = SM.getFileEntryForID(SM.getFileID(R.getBegin()));
|
||||
LocFID = SM.getFileID(R.getBegin());
|
||||
FE = SM.getFileEntryForID(LocFID);
|
||||
#endif
|
||||
if (!FE)
|
||||
return true;
|
||||
@ -476,26 +567,14 @@ public:
|
||||
|
||||
bool is_decl = Roles & uint32_t(index::SymbolRole::Declaration);
|
||||
bool is_def = Roles & uint32_t(index::SymbolRole::Definition);
|
||||
std::string short_name, qualified;
|
||||
|
||||
if (auto* ND = dyn_cast<NamedDecl>(D)) {
|
||||
short_name = ND->getNameAsString();
|
||||
qualified = ND->getQualifiedNameAsString();
|
||||
SimplifyAnonymous(qualified);
|
||||
}
|
||||
|
||||
IndexFunc *func = nullptr;
|
||||
IndexType *type = nullptr;
|
||||
IndexVar *var = nullptr;
|
||||
SymbolKind kind = GetSymbolKind(D);
|
||||
Usr usr = GetUsr(D);
|
||||
IndexParam::DeclInfo* info;
|
||||
Usr usr = GetUsr(D, &info);
|
||||
|
||||
auto do_def_decl = [&](auto *entity) {
|
||||
if (!entity->def.detailed_name[0]) {
|
||||
SetName(D, short_name, qualified, entity->def);
|
||||
if (entity->def.comments[0] == '\0' && g_config->index.comments)
|
||||
entity->def.comments = Intern(GetComment(D));
|
||||
}
|
||||
if (is_def) {
|
||||
entity->def.spell = GetUse(db, loc, SemDC, role);
|
||||
entity->def.extent =
|
||||
@ -505,19 +584,25 @@ public:
|
||||
entity->declarations.push_back(GetUse(db, loc, LexDC, role));
|
||||
} else {
|
||||
entity->uses.push_back(GetUse(db, loc, LexDC, role));
|
||||
return;
|
||||
}
|
||||
if (Spell != Loc)
|
||||
AddMacroUse(SM, entity->uses, Spell);
|
||||
if (entity->def.comments[0] == '\0' && g_config->index.comments)
|
||||
entity->def.comments = Intern(GetComment(OrigD));
|
||||
};
|
||||
switch (kind) {
|
||||
case SymbolKind::Invalid:
|
||||
LOG_S(INFO) << "Unhandled " << int(D->getKind());
|
||||
LOG_S(INFO) << "Unhandled " << int(D->getKind()) << " " << info->qualified
|
||||
<< " in " << db->path << ":" << loc.start.line;
|
||||
return true;
|
||||
case SymbolKind::File:
|
||||
return true;
|
||||
case SymbolKind::Func:
|
||||
func = &db->ToFunc(usr);
|
||||
do_def_decl(func);
|
||||
if (Spell != Loc)
|
||||
AddMacroUse(SM, usr, SymbolKind::Func, Spell);
|
||||
if (func->def.detailed_name[0] == '\0')
|
||||
SetName(OrigD, info->short_name, info->qualified, func->def);
|
||||
if (is_def || is_decl) {
|
||||
const Decl* DC = cast<Decl>(SemDC);
|
||||
if (GetSymbolKind(DC) == SymbolKind::Type)
|
||||
@ -527,6 +612,10 @@ public:
|
||||
case SymbolKind::Type:
|
||||
type = &db->ToType(usr);
|
||||
do_def_decl(type);
|
||||
if (Spell != Loc)
|
||||
AddMacroUse(SM, usr, SymbolKind::Type, Spell);
|
||||
if (type->def.detailed_name[0] == '\0')
|
||||
SetName(OrigD, info->short_name, info->qualified, type->def);
|
||||
if (is_def || is_decl) {
|
||||
const Decl* DC = cast<Decl>(SemDC);
|
||||
if (GetSymbolKind(DC) == SymbolKind::Type)
|
||||
@ -536,28 +625,21 @@ public:
|
||||
case SymbolKind::Var:
|
||||
var = &db->ToVar(usr);
|
||||
do_def_decl(var);
|
||||
if (Spell != Loc)
|
||||
AddMacroUse(SM, usr, SymbolKind::Var, Spell);
|
||||
if (var->def.detailed_name[0] == '\0')
|
||||
SetVarName(OrigD, info->short_name, info->qualified, var->def);
|
||||
QualType T;
|
||||
if (auto *VD = dyn_cast<VarDecl>(D))
|
||||
T = VD->getType();
|
||||
else if (auto *FD = dyn_cast<FieldDecl>(D))
|
||||
T = FD->getType();
|
||||
if (is_def || is_decl) {
|
||||
const Decl* DC = cast<Decl>(SemDC);
|
||||
if (GetSymbolKind(DC) == SymbolKind::Type)
|
||||
if (GetSymbolKind(DC) == SymbolKind::Func)
|
||||
db->ToFunc(GetUsr(DC)).def.vars.push_back(usr);
|
||||
else if (auto *ND = dyn_cast<NamespaceDecl>(SemDC))
|
||||
db->ToType(GetUsr(ND)).def.vars.emplace_back(usr, -1);
|
||||
QualType T;
|
||||
if (auto *VD = dyn_cast<VarDecl>(D)) {
|
||||
var->def.storage = VD->getStorageClass();
|
||||
T = VD->getType();
|
||||
// O(n^2)
|
||||
for (auto I : VD->redecls())
|
||||
if (I->hasInit()) {
|
||||
// TODO missing "static" in definition
|
||||
SetName(I, short_name, qualified, var->def, true);
|
||||
break;
|
||||
}
|
||||
} else if (auto *FD = dyn_cast<FieldDecl>(D)) {
|
||||
T = FD->getType();
|
||||
if (FD->hasInClassInitializer())
|
||||
SetName(D, short_name, qualified, var->def, true);
|
||||
}
|
||||
if (!T.isNull()) {
|
||||
if (auto *BT = T->getAs<BuiltinType>()) {
|
||||
Usr usr1 = static_cast<Usr>(BT->getKind());
|
||||
@ -565,16 +647,41 @@ public:
|
||||
db->ToType(usr1).instances.push_back(usr);
|
||||
} else {
|
||||
for (const Decl *D1 = GetTypeDecl(T); D1; D1 = GetSpecialized(D1)) {
|
||||
Usr usr1 = GetUsr(D1);
|
||||
IndexParam::DeclInfo* info1;
|
||||
Usr usr1 = GetUsr(D1, &info1);
|
||||
auto it = db->usr2type.find(usr1);
|
||||
if (it != db->usr2type.end()) {
|
||||
var->def.type = usr1;
|
||||
it->second.instances.push_back(usr);
|
||||
break;
|
||||
}
|
||||
// e.g. TemplateTypeParmDecl is not handled by handleDeclOccurence.
|
||||
SourceRange R1 = D1->getSourceRange();
|
||||
if (SM.getFileID(R1.getBegin()) == LocFID) {
|
||||
IndexType& type1 = db->ToType(usr1);
|
||||
Range loc1 = FromTokenRange(SM, Lang, R1);
|
||||
type1.def.spell = GetUse(db, loc1, SemDC, Role::Definition);
|
||||
type1.def.extent = GetUse(db, loc1, LexDC, Role::None);
|
||||
type1.def.detailed_name = Intern(info1->short_name);
|
||||
type1.def.short_name_size = int16_t(info1->short_name.size());
|
||||
type1.def.kind = lsSymbolKind::TypeParameter;
|
||||
var->def.type = usr1;
|
||||
type1.instances.push_back(usr);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (!var->def.spell && var->declarations.empty()) {
|
||||
// e.g. lambda parameter
|
||||
SourceLocation L = OrigD->getLocation();
|
||||
if (SM.getFileID(L) == LocFID) {
|
||||
var->def.spell = GetUse(db, FromTokenRange(SM, Lang, {L, L}), SemDC,
|
||||
Role::Definition);
|
||||
var->def.extent =
|
||||
GetUse(db, FromTokenRange(SM, Lang, OrigD->getSourceRange()),
|
||||
LexDC, Role::None);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
@ -643,8 +750,13 @@ public:
|
||||
break;
|
||||
case Decl::TypeAliasTemplate:
|
||||
type->def.kind = lsSymbolKind::TypeAlias;
|
||||
case Decl::VarTemplate:
|
||||
type->def.kind = lsSymbolKind::Variable;
|
||||
case Decl::TemplateTemplateParm:
|
||||
type->def.kind = lsSymbolKind::TypeParameter;
|
||||
break;
|
||||
case Decl::ClassTemplateSpecialization:
|
||||
case Decl::ClassTemplatePartialSpecialization:
|
||||
type->def.kind = lsSymbolKind::Class;
|
||||
if (is_def || is_decl) {
|
||||
if (auto *RD = dyn_cast<CXXRecordDecl>(D)) {
|
||||
@ -686,6 +798,11 @@ public:
|
||||
}
|
||||
}
|
||||
break;
|
||||
case Decl::Binding:
|
||||
var->def.kind = lsSymbolKind::Variable;
|
||||
case Decl::Field:
|
||||
var->def.kind = lsSymbolKind::Field;
|
||||
break;
|
||||
case Decl::Function:
|
||||
func->def.kind = lsSymbolKind::Function;
|
||||
break;
|
||||
@ -713,9 +830,6 @@ public:
|
||||
case Decl::CXXDestructor:
|
||||
func->def.kind = lsSymbolKind::Method;
|
||||
break;
|
||||
case Decl::Field:
|
||||
var->def.kind = lsSymbolKind::Field;
|
||||
break;
|
||||
case Decl::Var:
|
||||
case Decl::Decomposition:
|
||||
var->def.kind = lsSymbolKind::Variable;
|
||||
@ -737,6 +851,9 @@ public:
|
||||
var->def.hover = Intern(var->def.detailed_name + init);
|
||||
}
|
||||
break;
|
||||
case Decl::UnresolvedUsingValue:
|
||||
var->def.kind = lsSymbolKind::Variable;
|
||||
break;
|
||||
default:
|
||||
LOG_S(INFO) << "Unhandled " << int(D->getKind());
|
||||
break;
|
||||
@ -757,13 +874,18 @@ class IndexPPCallbacks : public PPCallbacks {
|
||||
}
|
||||
|
||||
public:
|
||||
IndexPPCallbacks(SourceManager& SM, IndexParam& param) : SM(SM), param(param) {}
|
||||
IndexPPCallbacks(SourceManager &SM, IndexParam ¶m)
|
||||
: SM(SM), param(param) {}
|
||||
void InclusionDirective(SourceLocation HashLoc, const Token &Tok,
|
||||
StringRef Included, bool IsAngled,
|
||||
CharSourceRange FilenameRange, const FileEntry *File,
|
||||
StringRef SearchPath, StringRef RelativePath,
|
||||
const Module *Imported,
|
||||
SrcMgr::CharacteristicKind FileType) override {
|
||||
const Module *Imported
|
||||
#if LLVM_VERSION_MAJOR >= 7
|
||||
,
|
||||
SrcMgr::CharacteristicKind FileType
|
||||
#endif
|
||||
) override {
|
||||
if (!File)
|
||||
return;
|
||||
llvm::sys::fs::UniqueID UniqueID;
|
||||
@ -780,25 +902,27 @@ public:
|
||||
}
|
||||
void MacroDefined(const Token &Tok, const MacroDirective *MD) override {
|
||||
llvm::sys::fs::UniqueID UniqueID;
|
||||
const LangOptions& Lang = param.Ctx->getLangOpts();
|
||||
SourceLocation L = MD->getLocation();
|
||||
auto range =
|
||||
FromTokenRange(SM, param.Ctx->getLangOpts(), {L, L}, &UniqueID);
|
||||
const FileEntry *FE = SM.getFileEntryForID(SM.getFileID(L));
|
||||
if (!FE)
|
||||
return;
|
||||
if (IndexFile *db = param.ConsumeFile(*FE)) {
|
||||
auto[Name, usr] = GetMacro(Tok);
|
||||
IndexVar &var = db->ToVar(usr);
|
||||
if (!var.def.detailed_name[0]) {
|
||||
auto range = FromTokenRange(SM, Lang, {L, L}, &UniqueID);
|
||||
var.def.kind = lsSymbolKind::Macro;
|
||||
if (var.def.spell)
|
||||
var.declarations.push_back(*var.def.spell);
|
||||
var.def.spell = Use{{range, 0, SymbolKind::File, Role::Definition}};
|
||||
const MacroInfo *MI = MD->getMacroInfo();
|
||||
SourceRange R(MI->getDefinitionLoc(), MI->getDefinitionEndLoc());
|
||||
range = FromTokenRange(SM, param.Ctx->getLangOpts(), R);
|
||||
var.def.extent = Use{{range, 0, SymbolKind::File, Role::None}};
|
||||
if (var.def.detailed_name[0] == '\0') {
|
||||
var.def.detailed_name = Intern(Name);
|
||||
var.def.short_name_size = Name.size();
|
||||
// TODO defin
|
||||
var.def.hover = Intern(Twine("#define ", Name).str());
|
||||
var.def.kind = lsSymbolKind::Macro;
|
||||
if (var.def.spell)
|
||||
var.declarations.push_back(*var.def.spell);
|
||||
var.def.spell = Use{{range, 0, SymbolKind::File, Role::Definition}};
|
||||
var.def.extent = var.def.spell;
|
||||
var.def.hover = Intern(Twine("#define ", GetSourceInRange(SM, Lang, R)).str());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -14,17 +14,17 @@ MAKE_HASHABLE(SymbolIdx, t.usr, t.kind);
|
||||
|
||||
namespace {
|
||||
|
||||
struct Out_CclsSetInactiveRegion
|
||||
: public lsOutMessage<Out_CclsSetInactiveRegion> {
|
||||
struct Out_CclsSetSkippedRanges
|
||||
: public lsOutMessage<Out_CclsSetSkippedRanges> {
|
||||
struct Params {
|
||||
lsDocumentUri uri;
|
||||
std::vector<lsRange> inactiveRegions;
|
||||
std::vector<lsRange> skippedRanges;
|
||||
};
|
||||
std::string method = "$ccls/setInactiveRegions";
|
||||
std::string method = "$ccls/setSkippedRanges";
|
||||
Params params;
|
||||
};
|
||||
MAKE_REFLECT_STRUCT(Out_CclsSetInactiveRegion::Params, uri, inactiveRegions);
|
||||
MAKE_REFLECT_STRUCT(Out_CclsSetInactiveRegion, jsonrpc, method, params);
|
||||
MAKE_REFLECT_STRUCT(Out_CclsSetSkippedRanges::Params, uri, skippedRanges);
|
||||
MAKE_REFLECT_STRUCT(Out_CclsSetSkippedRanges, jsonrpc, method, params);
|
||||
|
||||
struct ScanLineEvent {
|
||||
lsPosition pos;
|
||||
@ -177,14 +177,14 @@ bool FindFileOrFail(DB* db,
|
||||
|
||||
void EmitSkippedRanges(WorkingFile *working_file,
|
||||
const std::vector<Range> &skipped_ranges) {
|
||||
Out_CclsSetInactiveRegion out;
|
||||
Out_CclsSetSkippedRanges out;
|
||||
out.params.uri = lsDocumentUri::FromPath(working_file->filename);
|
||||
for (Range skipped : skipped_ranges) {
|
||||
std::optional<lsRange> ls_skipped = GetLsRange(working_file, skipped);
|
||||
if (ls_skipped)
|
||||
out.params.inactiveRegions.push_back(*ls_skipped);
|
||||
out.params.skippedRanges.push_back(*ls_skipped);
|
||||
}
|
||||
pipeline::WriteStdout(kMethodType_CclsPublishInactiveRegions, out);
|
||||
pipeline::WriteStdout(kMethodType_CclsPublishSkippedRanges, out);
|
||||
}
|
||||
|
||||
void EmitSemanticHighlighting(DB* db,
|
||||
|
@ -4,8 +4,8 @@ MethodType kMethodType_Unknown = "$unknown";
|
||||
MethodType kMethodType_Exit = "exit";
|
||||
MethodType kMethodType_TextDocumentPublishDiagnostics =
|
||||
"textDocument/publishDiagnostics";
|
||||
MethodType kMethodType_CclsPublishInactiveRegions =
|
||||
"$ccls/publishInactiveRegions";
|
||||
MethodType kMethodType_CclsPublishSkippedRanges =
|
||||
"$ccls/publishSkippedRanges";
|
||||
MethodType kMethodType_CclsPublishSemanticHighlighting =
|
||||
"$ccls/publishSemanticHighlighting";
|
||||
|
||||
|
@ -9,7 +9,7 @@ using MethodType = const char*;
|
||||
extern MethodType kMethodType_Unknown;
|
||||
extern MethodType kMethodType_Exit;
|
||||
extern MethodType kMethodType_TextDocumentPublishDiagnostics;
|
||||
extern MethodType kMethodType_CclsPublishInactiveRegions;
|
||||
extern MethodType kMethodType_CclsPublishSkippedRanges;
|
||||
extern MethodType kMethodType_CclsPublishSemanticHighlighting;
|
||||
|
||||
struct lsRequestId {
|
||||
|
@ -320,7 +320,7 @@ void Main_OnIndexed(DB* db,
|
||||
db->ApplyIndexUpdate(update);
|
||||
timer.stopTimer();
|
||||
|
||||
// Update indexed content, inactive lines, and semantic highlighting.
|
||||
// Update indexed content, skipped ranges, and semantic highlighting.
|
||||
if (update->files_def_update) {
|
||||
auto& def_u = *update->files_def_update;
|
||||
LOG_S(INFO) << "apply index for " << def_u.first.path;
|
||||
|
Loading…
Reference in New Issue
Block a user