diff --git a/lib/src/gen/scip.pb.dart b/lib/src/gen/scip.pb.dart index d4da93b6..fc8fafce 100644 --- a/lib/src/gen/scip.pb.dart +++ b/lib/src/gen/scip.pb.dart @@ -244,6 +244,7 @@ class Document extends $pb.GeneratedMessage { ..pc(2, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'occurrences', $pb.PbFieldType.PM, subBuilder: Occurrence.create) ..pc(3, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'symbols', $pb.PbFieldType.PM, subBuilder: SymbolInformation.create) ..aOS(4, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'language') + ..aOS(5, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'text') ..hasRequiredFields = false ; @@ -253,6 +254,7 @@ class Document extends $pb.GeneratedMessage { $core.Iterable? occurrences, $core.Iterable? symbols, $core.String? language, + $core.String? text, }) { final _result = create(); if (relativePath != null) { @@ -267,6 +269,9 @@ class Document extends $pb.GeneratedMessage { if (language != null) { _result.language = language; } + if (text != null) { + _result.text = text; + } return _result; } factory Document.fromBuffer($core.List<$core.int> i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromBuffer(i, r); @@ -313,6 +318,15 @@ class Document extends $pb.GeneratedMessage { $core.bool hasLanguage() => $_has(3); @$pb.TagNumber(4) void clearLanguage() => clearField(4); + + @$pb.TagNumber(5) + $core.String get text => $_getSZ(4); + @$pb.TagNumber(5) + set text($core.String v) { $_setString(4, v); } + @$pb.TagNumber(5) + $core.bool hasText() => $_has(4); + @$pb.TagNumber(5) + void clearText() => clearField(5); } class Symbol extends $pb.GeneratedMessage { @@ -541,6 +555,10 @@ class SymbolInformation extends $pb.GeneratedMessage { ..aOS(1, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'symbol') ..pPS(3, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'documentation') ..pc(4, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'relationships', $pb.PbFieldType.PM, subBuilder: Relationship.create) + ..e(5, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'kind', $pb.PbFieldType.OE, defaultOrMaker: SymbolInformation_Kind.UnspecifiedKind, valueOf: SymbolInformation_Kind.valueOf, enumValues: SymbolInformation_Kind.values) + ..aOS(6, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'displayName') + ..aOM(7, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'signatureDocumentation', subBuilder: Document.create) + ..aOS(8, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'enclosingSymbol') ..hasRequiredFields = false ; @@ -549,6 +567,10 @@ class SymbolInformation extends $pb.GeneratedMessage { $core.String? symbol, $core.Iterable<$core.String>? documentation, $core.Iterable? relationships, + SymbolInformation_Kind? kind, + $core.String? displayName, + Document? signatureDocumentation, + $core.String? enclosingSymbol, }) { final _result = create(); if (symbol != null) { @@ -560,6 +582,18 @@ class SymbolInformation extends $pb.GeneratedMessage { if (relationships != null) { _result.relationships.addAll(relationships); } + if (kind != null) { + _result.kind = kind; + } + if (displayName != null) { + _result.displayName = displayName; + } + if (signatureDocumentation != null) { + _result.signatureDocumentation = signatureDocumentation; + } + if (enclosingSymbol != null) { + _result.enclosingSymbol = enclosingSymbol; + } return _result; } factory SymbolInformation.fromBuffer($core.List<$core.int> i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromBuffer(i, r); @@ -597,6 +631,44 @@ class SymbolInformation extends $pb.GeneratedMessage { @$pb.TagNumber(4) $core.List get relationships => $_getList(2); + + @$pb.TagNumber(5) + SymbolInformation_Kind get kind => $_getN(3); + @$pb.TagNumber(5) + set kind(SymbolInformation_Kind v) { setField(5, v); } + @$pb.TagNumber(5) + $core.bool hasKind() => $_has(3); + @$pb.TagNumber(5) + void clearKind() => clearField(5); + + @$pb.TagNumber(6) + $core.String get displayName => $_getSZ(4); + @$pb.TagNumber(6) + set displayName($core.String v) { $_setString(4, v); } + @$pb.TagNumber(6) + $core.bool hasDisplayName() => $_has(4); + @$pb.TagNumber(6) + void clearDisplayName() => clearField(6); + + @$pb.TagNumber(7) + Document get signatureDocumentation => $_getN(5); + @$pb.TagNumber(7) + set signatureDocumentation(Document v) { setField(7, v); } + @$pb.TagNumber(7) + $core.bool hasSignatureDocumentation() => $_has(5); + @$pb.TagNumber(7) + void clearSignatureDocumentation() => clearField(7); + @$pb.TagNumber(7) + Document ensureSignatureDocumentation() => $_ensure(5); + + @$pb.TagNumber(8) + $core.String get enclosingSymbol => $_getSZ(6); + @$pb.TagNumber(8) + set enclosingSymbol($core.String v) { $_setString(6, v); } + @$pb.TagNumber(8) + $core.bool hasEnclosingSymbol() => $_has(6); + @$pb.TagNumber(8) + void clearEnclosingSymbol() => clearField(8); } class Relationship extends $pb.GeneratedMessage { @@ -710,6 +782,7 @@ class Occurrence extends $pb.GeneratedMessage { ..pPS(4, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'overrideDocumentation') ..e(5, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'syntaxKind', $pb.PbFieldType.OE, defaultOrMaker: SyntaxKind.UnspecifiedSyntaxKind, valueOf: SyntaxKind.valueOf, enumValues: SyntaxKind.values) ..pc(6, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'diagnostics', $pb.PbFieldType.PM, subBuilder: Diagnostic.create) + ..p<$core.int>(7, const $core.bool.fromEnvironment('protobuf.omit_field_names') ? '' : 'enclosingRange', $pb.PbFieldType.K3) ..hasRequiredFields = false ; @@ -721,6 +794,7 @@ class Occurrence extends $pb.GeneratedMessage { $core.Iterable<$core.String>? overrideDocumentation, SyntaxKind? syntaxKind, $core.Iterable? diagnostics, + $core.Iterable<$core.int>? enclosingRange, }) { final _result = create(); if (range != null) { @@ -741,6 +815,9 @@ class Occurrence extends $pb.GeneratedMessage { if (diagnostics != null) { _result.diagnostics.addAll(diagnostics); } + if (enclosingRange != null) { + _result.enclosingRange.addAll(enclosingRange); + } return _result; } factory Occurrence.fromBuffer($core.List<$core.int> i, [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) => create()..mergeFromBuffer(i, r); @@ -799,6 +876,9 @@ class Occurrence extends $pb.GeneratedMessage { @$pb.TagNumber(6) $core.List get diagnostics => $_getList(5); + + @$pb.TagNumber(7) + $core.List<$core.int> get enclosingRange => $_getList(6); } class Diagnostic extends $pb.GeneratedMessage { diff --git a/lib/src/gen/scip.pbenum.dart b/lib/src/gen/scip.pbenum.dart index 10f90352..28fad41b 100644 --- a/lib/src/gen/scip.pbenum.dart +++ b/lib/src/gen/scip.pbenum.dart @@ -273,6 +273,7 @@ class Language extends $pb.ProtobufEnum { static const Language Scheme = Language._(10, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Scheme'); static const Language ShellScript = Language._(64, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'ShellScript'); static const Language Skylark = Language._(78, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Skylark'); + static const Language Solidity = Language._(95, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Solidity'); static const Language Swift = Language._(2, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Swift'); static const Language TOML = Language._(73, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TOML'); static const Language TeX = Language._(82, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TeX'); @@ -369,6 +370,7 @@ class Language extends $pb.ProtobufEnum { Scheme, ShellScript, Skylark, + Solidity, Swift, TOML, TeX, @@ -397,9 +399,9 @@ class Descriptor_Suffix extends $pb.ProtobufEnum { static const Descriptor_Suffix Method = Descriptor_Suffix._(4, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Method'); static const Descriptor_Suffix TypeParameter = Descriptor_Suffix._(5, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TypeParameter'); static const Descriptor_Suffix Parameter = Descriptor_Suffix._(6, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Parameter'); - static const Descriptor_Suffix Macro = Descriptor_Suffix._(9, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Macro'); static const Descriptor_Suffix Meta = Descriptor_Suffix._(7, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Meta'); static const Descriptor_Suffix Local = Descriptor_Suffix._(8, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Local'); + static const Descriptor_Suffix Macro = Descriptor_Suffix._(9, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Macro'); static const Descriptor_Suffix Package = Namespace; @@ -411,9 +413,9 @@ class Descriptor_Suffix extends $pb.ProtobufEnum { Method, TypeParameter, Parameter, - Macro, Meta, Local, + Macro, ]; static final $core.Map<$core.int, Descriptor_Suffix> _byValue = $pb.ProtobufEnum.initByValue(values); @@ -422,3 +424,146 @@ class Descriptor_Suffix extends $pb.ProtobufEnum { const Descriptor_Suffix._($core.int v, $core.String n) : super(v, n); } +class SymbolInformation_Kind extends $pb.ProtobufEnum { + static const SymbolInformation_Kind UnspecifiedKind = SymbolInformation_Kind._(0, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'UnspecifiedKind'); + static const SymbolInformation_Kind Array = SymbolInformation_Kind._(1, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Array'); + static const SymbolInformation_Kind Assertion = SymbolInformation_Kind._(2, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Assertion'); + static const SymbolInformation_Kind AssociatedType = SymbolInformation_Kind._(3, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'AssociatedType'); + static const SymbolInformation_Kind Attribute = SymbolInformation_Kind._(4, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Attribute'); + static const SymbolInformation_Kind Axiom = SymbolInformation_Kind._(5, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Axiom'); + static const SymbolInformation_Kind Boolean = SymbolInformation_Kind._(6, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Boolean'); + static const SymbolInformation_Kind Class = SymbolInformation_Kind._(7, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Class'); + static const SymbolInformation_Kind Constant = SymbolInformation_Kind._(8, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Constant'); + static const SymbolInformation_Kind Constructor = SymbolInformation_Kind._(9, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Constructor'); + static const SymbolInformation_Kind Contract = SymbolInformation_Kind._(62, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Contract'); + static const SymbolInformation_Kind DataFamily = SymbolInformation_Kind._(10, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'DataFamily'); + static const SymbolInformation_Kind Enum = SymbolInformation_Kind._(11, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Enum'); + static const SymbolInformation_Kind EnumMember = SymbolInformation_Kind._(12, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'EnumMember'); + static const SymbolInformation_Kind Error = SymbolInformation_Kind._(63, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Error'); + static const SymbolInformation_Kind Event = SymbolInformation_Kind._(13, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Event'); + static const SymbolInformation_Kind Fact = SymbolInformation_Kind._(14, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Fact'); + static const SymbolInformation_Kind Field = SymbolInformation_Kind._(15, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Field'); + static const SymbolInformation_Kind File = SymbolInformation_Kind._(16, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'File'); + static const SymbolInformation_Kind Function = SymbolInformation_Kind._(17, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Function'); + static const SymbolInformation_Kind Getter = SymbolInformation_Kind._(18, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Getter'); + static const SymbolInformation_Kind Grammar = SymbolInformation_Kind._(19, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Grammar'); + static const SymbolInformation_Kind Instance = SymbolInformation_Kind._(20, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Instance'); + static const SymbolInformation_Kind Interface = SymbolInformation_Kind._(21, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Interface'); + static const SymbolInformation_Kind Key = SymbolInformation_Kind._(22, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Key'); + static const SymbolInformation_Kind Lang = SymbolInformation_Kind._(23, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Lang'); + static const SymbolInformation_Kind Lemma = SymbolInformation_Kind._(24, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Lemma'); + static const SymbolInformation_Kind Library = SymbolInformation_Kind._(64, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Library'); + static const SymbolInformation_Kind Macro = SymbolInformation_Kind._(25, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Macro'); + static const SymbolInformation_Kind Method = SymbolInformation_Kind._(26, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Method'); + static const SymbolInformation_Kind MethodReceiver = SymbolInformation_Kind._(27, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'MethodReceiver'); + static const SymbolInformation_Kind Message = SymbolInformation_Kind._(28, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Message'); + static const SymbolInformation_Kind Modifier = SymbolInformation_Kind._(65, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Modifier'); + static const SymbolInformation_Kind Module = SymbolInformation_Kind._(29, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Module'); + static const SymbolInformation_Kind Namespace = SymbolInformation_Kind._(30, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Namespace'); + static const SymbolInformation_Kind Null = SymbolInformation_Kind._(31, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Null'); + static const SymbolInformation_Kind Number = SymbolInformation_Kind._(32, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Number'); + static const SymbolInformation_Kind Object_ = SymbolInformation_Kind._(33, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Object'); + static const SymbolInformation_Kind Operator = SymbolInformation_Kind._(34, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Operator'); + static const SymbolInformation_Kind Package = SymbolInformation_Kind._(35, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Package'); + static const SymbolInformation_Kind PackageObject = SymbolInformation_Kind._(36, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'PackageObject'); + static const SymbolInformation_Kind Parameter = SymbolInformation_Kind._(37, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Parameter'); + static const SymbolInformation_Kind ParameterLabel = SymbolInformation_Kind._(38, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'ParameterLabel'); + static const SymbolInformation_Kind Pattern = SymbolInformation_Kind._(39, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Pattern'); + static const SymbolInformation_Kind Predicate = SymbolInformation_Kind._(40, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Predicate'); + static const SymbolInformation_Kind Property = SymbolInformation_Kind._(41, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Property'); + static const SymbolInformation_Kind Protocol = SymbolInformation_Kind._(42, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Protocol'); + static const SymbolInformation_Kind Quasiquoter = SymbolInformation_Kind._(43, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Quasiquoter'); + static const SymbolInformation_Kind SelfParameter = SymbolInformation_Kind._(44, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'SelfParameter'); + static const SymbolInformation_Kind Setter = SymbolInformation_Kind._(45, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Setter'); + static const SymbolInformation_Kind Signature = SymbolInformation_Kind._(46, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Signature'); + static const SymbolInformation_Kind Subscript = SymbolInformation_Kind._(47, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Subscript'); + static const SymbolInformation_Kind String = SymbolInformation_Kind._(48, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'String'); + static const SymbolInformation_Kind Struct = SymbolInformation_Kind._(49, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Struct'); + static const SymbolInformation_Kind Tactic = SymbolInformation_Kind._(50, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Tactic'); + static const SymbolInformation_Kind Theorem = SymbolInformation_Kind._(51, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Theorem'); + static const SymbolInformation_Kind ThisParameter = SymbolInformation_Kind._(52, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'ThisParameter'); + static const SymbolInformation_Kind Trait = SymbolInformation_Kind._(53, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Trait'); + static const SymbolInformation_Kind Type = SymbolInformation_Kind._(54, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Type'); + static const SymbolInformation_Kind TypeAlias = SymbolInformation_Kind._(55, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TypeAlias'); + static const SymbolInformation_Kind TypeClass = SymbolInformation_Kind._(56, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TypeClass'); + static const SymbolInformation_Kind TypeFamily = SymbolInformation_Kind._(57, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TypeFamily'); + static const SymbolInformation_Kind TypeParameter = SymbolInformation_Kind._(58, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'TypeParameter'); + static const SymbolInformation_Kind Union = SymbolInformation_Kind._(59, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Union'); + static const SymbolInformation_Kind Value = SymbolInformation_Kind._(60, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Value'); + static const SymbolInformation_Kind Variable = SymbolInformation_Kind._(61, const $core.bool.fromEnvironment('protobuf.omit_enum_names') ? '' : 'Variable'); + + static const $core.List values = [ + UnspecifiedKind, + Array, + Assertion, + AssociatedType, + Attribute, + Axiom, + Boolean, + Class, + Constant, + Constructor, + Contract, + DataFamily, + Enum, + EnumMember, + Error, + Event, + Fact, + Field, + File, + Function, + Getter, + Grammar, + Instance, + Interface, + Key, + Lang, + Lemma, + Library, + Macro, + Method, + MethodReceiver, + Message, + Modifier, + Module, + Namespace, + Null, + Number, + Object_, + Operator, + Package, + PackageObject, + Parameter, + ParameterLabel, + Pattern, + Predicate, + Property, + Protocol, + Quasiquoter, + SelfParameter, + Setter, + Signature, + Subscript, + String, + Struct, + Tactic, + Theorem, + ThisParameter, + Trait, + Type, + TypeAlias, + TypeClass, + TypeFamily, + TypeParameter, + Union, + Value, + Variable, + ]; + + static final $core.Map<$core.int, SymbolInformation_Kind> _byValue = $pb.ProtobufEnum.initByValue(values); + static SymbolInformation_Kind? valueOf($core.int value) => _byValue[value]; + + const SymbolInformation_Kind._($core.int v, $core.String n) : super(v, n); +} + diff --git a/lib/src/gen/scip.pbjson.dart b/lib/src/gen/scip.pbjson.dart index 451d396e..3d6f0eff 100644 --- a/lib/src/gen/scip.pbjson.dart +++ b/lib/src/gen/scip.pbjson.dart @@ -215,6 +215,7 @@ const Language$json = const { const {'1': 'Scheme', '2': 10}, const {'1': 'ShellScript', '2': 64}, const {'1': 'Skylark', '2': 78}, + const {'1': 'Solidity', '2': 95}, const {'1': 'Swift', '2': 2}, const {'1': 'TOML', '2': 73}, const {'1': 'TeX', '2': 82}, @@ -231,7 +232,7 @@ const Language$json = const { }; /// Descriptor for `Language`. Decode as a `google.protobuf.EnumDescriptorProto`. -final $typed_data.Uint8List languageDescriptor = $convert.base64Decode('CghMYW5ndWFnZRIXChNVbnNwZWNpZmllZExhbmd1YWdlEAASCAoEQUJBUBA8EgcKA0FQTBAxEgcKA0FkYRAnEggKBEFnZGEQLRIMCghBc2NpaURvYxBWEgwKCEFzc2VtYmx5EDoSBwoDQXdrEEISBwoDQmF0EEQSCgoGQmliVGVYEFESBQoBQxAiEgkKBUNPQk9MEDsSBwoDQ1BQECMSBwoDQ1NTEBoSCgoGQ1NoYXJwEAESCwoHQ2xvanVyZRAIEhAKDENvZmZlZXNjcmlwdBAVEg4KCkNvbW1vbkxpc3AQCRIHCgNDb3EQLxIICgREYXJ0EAMSCgoGRGVscGhpEDkSCAoERGlmZhBYEg4KCkRvY2tlcmZpbGUQUBIKCgZEeWFsb2cQMhIKCgZFbGl4aXIQERIKCgZFcmxhbmcQEhIKCgZGU2hhcnAQKhIICgRGaXNoEEESCAoERmxvdxAYEgsKB0ZvcnRyYW4QOBIOCgpHaXRfQ29tbWl0EFsSDgoKR2l0X0NvbmZpZxBZEg4KCkdpdF9SZWJhc2UQXBIGCgJHbxAhEgoKBkdyb292eRAHEggKBEhUTUwQHhIICgRIYWNrEBQSDgoKSGFuZGxlYmFycxBaEgsKB0hhc2tlbGwQLBIJCgVJZHJpcxAuEgcKA0luaRBIEgUKAUoQMxIICgRKU09OEEsSCAoESmF2YRAGEg4KCkphdmFTY3JpcHQQFhITCg9KYXZhU2NyaXB0UmVhY3QQXRILCgdKc29ubmV0EEwSCQoFSnVsaWEQNxIKCgZLb3RsaW4QBBIJCgVMYVRlWBBTEggKBExlYW4QMBIICgRMZXNzEBsSBwoDTHVhEAwSDAoITWFrZWZpbGUQTxIMCghNYXJrZG93bhBUEgoKBk1hdGxhYhA0EgcKA05peBBNEgkKBU9DYW1sECkSDwoLT2JqZWN0aXZlX0MQJBIRCg1PYmplY3RpdmVfQ1BQECUSBwoDUEhQEBMSCQoFUExTUUwQRhIICgRQZXJsEA0SDgoKUG93ZXJTaGVsbBBDEgoKBlByb2xvZxBHEgoKBlB5dGhvbhAPEgUKAVIQNhIKCgZSYWNrZXQQCxIICgRSYWt1EA4SCQoFUmF6b3IQPhIICgRSZVNUEFUSCAoEUnVieRAQEggKBFJ1c3QQKBIHCgNTQVMQPRIICgRTQ1NTEB0SBwoDU01MECsSBwoDU1FMEEUSCAoEU2FzcxAcEgkKBVNjYWxhEAUSCgoGU2NoZW1lEAoSDwoLU2hlbGxTY3JpcHQQQBILCgdTa3lsYXJrEE4SCQoFU3dpZnQQAhIICgRUT01MEEkSBwoDVGVYEFISDgoKVHlwZVNjcmlwdBAXEhMKD1R5cGVTY3JpcHRSZWFjdBBeEg8KC1Zpc3VhbEJhc2ljED8SBwoDVnVlEBkSCwoHV29sZnJhbRA1EgcKA1hNTBAfEgcKA1hTTBAgEggKBFlBTUwQShIHCgNaaWcQJg=='); +final $typed_data.Uint8List languageDescriptor = $convert.base64Decode('CghMYW5ndWFnZRIXChNVbnNwZWNpZmllZExhbmd1YWdlEAASCAoEQUJBUBA8EgcKA0FQTBAxEgcKA0FkYRAnEggKBEFnZGEQLRIMCghBc2NpaURvYxBWEgwKCEFzc2VtYmx5EDoSBwoDQXdrEEISBwoDQmF0EEQSCgoGQmliVGVYEFESBQoBQxAiEgkKBUNPQk9MEDsSBwoDQ1BQECMSBwoDQ1NTEBoSCgoGQ1NoYXJwEAESCwoHQ2xvanVyZRAIEhAKDENvZmZlZXNjcmlwdBAVEg4KCkNvbW1vbkxpc3AQCRIHCgNDb3EQLxIICgREYXJ0EAMSCgoGRGVscGhpEDkSCAoERGlmZhBYEg4KCkRvY2tlcmZpbGUQUBIKCgZEeWFsb2cQMhIKCgZFbGl4aXIQERIKCgZFcmxhbmcQEhIKCgZGU2hhcnAQKhIICgRGaXNoEEESCAoERmxvdxAYEgsKB0ZvcnRyYW4QOBIOCgpHaXRfQ29tbWl0EFsSDgoKR2l0X0NvbmZpZxBZEg4KCkdpdF9SZWJhc2UQXBIGCgJHbxAhEgoKBkdyb292eRAHEggKBEhUTUwQHhIICgRIYWNrEBQSDgoKSGFuZGxlYmFycxBaEgsKB0hhc2tlbGwQLBIJCgVJZHJpcxAuEgcKA0luaRBIEgUKAUoQMxIICgRKU09OEEsSCAoESmF2YRAGEg4KCkphdmFTY3JpcHQQFhITCg9KYXZhU2NyaXB0UmVhY3QQXRILCgdKc29ubmV0EEwSCQoFSnVsaWEQNxIKCgZLb3RsaW4QBBIJCgVMYVRlWBBTEggKBExlYW4QMBIICgRMZXNzEBsSBwoDTHVhEAwSDAoITWFrZWZpbGUQTxIMCghNYXJrZG93bhBUEgoKBk1hdGxhYhA0EgcKA05peBBNEgkKBU9DYW1sECkSDwoLT2JqZWN0aXZlX0MQJBIRCg1PYmplY3RpdmVfQ1BQECUSBwoDUEhQEBMSCQoFUExTUUwQRhIICgRQZXJsEA0SDgoKUG93ZXJTaGVsbBBDEgoKBlByb2xvZxBHEgoKBlB5dGhvbhAPEgUKAVIQNhIKCgZSYWNrZXQQCxIICgRSYWt1EA4SCQoFUmF6b3IQPhIICgRSZVNUEFUSCAoEUnVieRAQEggKBFJ1c3QQKBIHCgNTQVMQPRIICgRTQ1NTEB0SBwoDU01MECsSBwoDU1FMEEUSCAoEU2FzcxAcEgkKBVNjYWxhEAUSCgoGU2NoZW1lEAoSDwoLU2hlbGxTY3JpcHQQQBILCgdTa3lsYXJrEE4SDAoIU29saWRpdHkQXxIJCgVTd2lmdBACEggKBFRPTUwQSRIHCgNUZVgQUhIOCgpUeXBlU2NyaXB0EBcSEwoPVHlwZVNjcmlwdFJlYWN0EF4SDwoLVmlzdWFsQmFzaWMQPxIHCgNWdWUQGRILCgdXb2xmcmFtEDUSBwoDWE1MEB8SBwoDWFNMECASCAoEWUFNTBBKEgcKA1ppZxAm'); @$core.Deprecated('Use indexDescriptor instead') const Index$json = const { '1': 'Index', @@ -277,11 +278,12 @@ const Document$json = const { const {'1': 'relative_path', '3': 1, '4': 1, '5': 9, '10': 'relativePath'}, const {'1': 'occurrences', '3': 2, '4': 3, '5': 11, '6': '.scip.Occurrence', '10': 'occurrences'}, const {'1': 'symbols', '3': 3, '4': 3, '5': 11, '6': '.scip.SymbolInformation', '10': 'symbols'}, + const {'1': 'text', '3': 5, '4': 1, '5': 9, '10': 'text'}, ], }; /// Descriptor for `Document`. Decode as a `google.protobuf.DescriptorProto`. -final $typed_data.Uint8List documentDescriptor = $convert.base64Decode('CghEb2N1bWVudBIaCghsYW5ndWFnZRgEIAEoCVIIbGFuZ3VhZ2USIwoNcmVsYXRpdmVfcGF0aBgBIAEoCVIMcmVsYXRpdmVQYXRoEjIKC29jY3VycmVuY2VzGAIgAygLMhAuc2NpcC5PY2N1cnJlbmNlUgtvY2N1cnJlbmNlcxIxCgdzeW1ib2xzGAMgAygLMhcuc2NpcC5TeW1ib2xJbmZvcm1hdGlvblIHc3ltYm9scw=='); +final $typed_data.Uint8List documentDescriptor = $convert.base64Decode('CghEb2N1bWVudBIaCghsYW5ndWFnZRgEIAEoCVIIbGFuZ3VhZ2USIwoNcmVsYXRpdmVfcGF0aBgBIAEoCVIMcmVsYXRpdmVQYXRoEjIKC29jY3VycmVuY2VzGAIgAygLMhAuc2NpcC5PY2N1cnJlbmNlUgtvY2N1cnJlbmNlcxIxCgdzeW1ib2xzGAMgAygLMhcuc2NpcC5TeW1ib2xJbmZvcm1hdGlvblIHc3ltYm9scxISCgR0ZXh0GAUgASgJUgR0ZXh0'); @$core.Deprecated('Use symbolDescriptor instead') const Symbol$json = const { '1': 'Symbol', @@ -333,15 +335,15 @@ const Descriptor_Suffix$json = const { const {'1': 'Method', '2': 4}, const {'1': 'TypeParameter', '2': 5}, const {'1': 'Parameter', '2': 6}, - const {'1': 'Macro', '2': 9}, const {'1': 'Meta', '2': 7}, const {'1': 'Local', '2': 8}, + const {'1': 'Macro', '2': 9}, ], '3': const {'2': true}, }; /// Descriptor for `Descriptor`. Decode as a `google.protobuf.DescriptorProto`. -final $typed_data.Uint8List descriptorDescriptor = $convert.base64Decode('CgpEZXNjcmlwdG9yEhIKBG5hbWUYASABKAlSBG5hbWUSJAoNZGlzYW1iaWd1YXRvchgCIAEoCVINZGlzYW1iaWd1YXRvchIvCgZzdWZmaXgYAyABKA4yFy5zY2lwLkRlc2NyaXB0b3IuU3VmZml4UgZzdWZmaXgipQEKBlN1ZmZpeBIVChFVbnNwZWNpZmllZFN1ZmZpeBAAEg0KCU5hbWVzcGFjZRABEg8KB1BhY2thZ2UQARoCCAESCAoEVHlwZRACEggKBFRlcm0QAxIKCgZNZXRob2QQBBIRCg1UeXBlUGFyYW1ldGVyEAUSDQoJUGFyYW1ldGVyEAYSCQoFTWFjcm8QCRIICgRNZXRhEAcSCQoFTG9jYWwQCBoCEAE='); +final $typed_data.Uint8List descriptorDescriptor = $convert.base64Decode('CgpEZXNjcmlwdG9yEhIKBG5hbWUYASABKAlSBG5hbWUSJAoNZGlzYW1iaWd1YXRvchgCIAEoCVINZGlzYW1iaWd1YXRvchIvCgZzdWZmaXgYAyABKA4yFy5zY2lwLkRlc2NyaXB0b3IuU3VmZml4UgZzdWZmaXgipQEKBlN1ZmZpeBIVChFVbnNwZWNpZmllZFN1ZmZpeBAAEg0KCU5hbWVzcGFjZRABEg8KB1BhY2thZ2UQARoCCAESCAoEVHlwZRACEggKBFRlcm0QAxIKCgZNZXRob2QQBBIRCg1UeXBlUGFyYW1ldGVyEAUSDQoJUGFyYW1ldGVyEAYSCAoETWV0YRAHEgkKBUxvY2FsEAgSCQoFTWFjcm8QCRoCEAE='); @$core.Deprecated('Use symbolInformationDescriptor instead') const SymbolInformation$json = const { '1': 'SymbolInformation', @@ -349,11 +351,89 @@ const SymbolInformation$json = const { const {'1': 'symbol', '3': 1, '4': 1, '5': 9, '10': 'symbol'}, const {'1': 'documentation', '3': 3, '4': 3, '5': 9, '10': 'documentation'}, const {'1': 'relationships', '3': 4, '4': 3, '5': 11, '6': '.scip.Relationship', '10': 'relationships'}, + const {'1': 'kind', '3': 5, '4': 1, '5': 14, '6': '.scip.SymbolInformation.Kind', '10': 'kind'}, + const {'1': 'display_name', '3': 6, '4': 1, '5': 9, '10': 'displayName'}, + const {'1': 'signature_documentation', '3': 7, '4': 1, '5': 11, '6': '.scip.Document', '10': 'signatureDocumentation'}, + const {'1': 'enclosing_symbol', '3': 8, '4': 1, '5': 9, '10': 'enclosingSymbol'}, + ], + '4': const [SymbolInformation_Kind$json], +}; + +@$core.Deprecated('Use symbolInformationDescriptor instead') +const SymbolInformation_Kind$json = const { + '1': 'Kind', + '2': const [ + const {'1': 'UnspecifiedKind', '2': 0}, + const {'1': 'Array', '2': 1}, + const {'1': 'Assertion', '2': 2}, + const {'1': 'AssociatedType', '2': 3}, + const {'1': 'Attribute', '2': 4}, + const {'1': 'Axiom', '2': 5}, + const {'1': 'Boolean', '2': 6}, + const {'1': 'Class', '2': 7}, + const {'1': 'Constant', '2': 8}, + const {'1': 'Constructor', '2': 9}, + const {'1': 'Contract', '2': 62}, + const {'1': 'DataFamily', '2': 10}, + const {'1': 'Enum', '2': 11}, + const {'1': 'EnumMember', '2': 12}, + const {'1': 'Error', '2': 63}, + const {'1': 'Event', '2': 13}, + const {'1': 'Fact', '2': 14}, + const {'1': 'Field', '2': 15}, + const {'1': 'File', '2': 16}, + const {'1': 'Function', '2': 17}, + const {'1': 'Getter', '2': 18}, + const {'1': 'Grammar', '2': 19}, + const {'1': 'Instance', '2': 20}, + const {'1': 'Interface', '2': 21}, + const {'1': 'Key', '2': 22}, + const {'1': 'Lang', '2': 23}, + const {'1': 'Lemma', '2': 24}, + const {'1': 'Library', '2': 64}, + const {'1': 'Macro', '2': 25}, + const {'1': 'Method', '2': 26}, + const {'1': 'MethodReceiver', '2': 27}, + const {'1': 'Message', '2': 28}, + const {'1': 'Modifier', '2': 65}, + const {'1': 'Module', '2': 29}, + const {'1': 'Namespace', '2': 30}, + const {'1': 'Null', '2': 31}, + const {'1': 'Number', '2': 32}, + const {'1': 'Object', '2': 33}, + const {'1': 'Operator', '2': 34}, + const {'1': 'Package', '2': 35}, + const {'1': 'PackageObject', '2': 36}, + const {'1': 'Parameter', '2': 37}, + const {'1': 'ParameterLabel', '2': 38}, + const {'1': 'Pattern', '2': 39}, + const {'1': 'Predicate', '2': 40}, + const {'1': 'Property', '2': 41}, + const {'1': 'Protocol', '2': 42}, + const {'1': 'Quasiquoter', '2': 43}, + const {'1': 'SelfParameter', '2': 44}, + const {'1': 'Setter', '2': 45}, + const {'1': 'Signature', '2': 46}, + const {'1': 'Subscript', '2': 47}, + const {'1': 'String', '2': 48}, + const {'1': 'Struct', '2': 49}, + const {'1': 'Tactic', '2': 50}, + const {'1': 'Theorem', '2': 51}, + const {'1': 'ThisParameter', '2': 52}, + const {'1': 'Trait', '2': 53}, + const {'1': 'Type', '2': 54}, + const {'1': 'TypeAlias', '2': 55}, + const {'1': 'TypeClass', '2': 56}, + const {'1': 'TypeFamily', '2': 57}, + const {'1': 'TypeParameter', '2': 58}, + const {'1': 'Union', '2': 59}, + const {'1': 'Value', '2': 60}, + const {'1': 'Variable', '2': 61}, ], }; /// Descriptor for `SymbolInformation`. Decode as a `google.protobuf.DescriptorProto`. -final $typed_data.Uint8List symbolInformationDescriptor = $convert.base64Decode('ChFTeW1ib2xJbmZvcm1hdGlvbhIWCgZzeW1ib2wYASABKAlSBnN5bWJvbBIkCg1kb2N1bWVudGF0aW9uGAMgAygJUg1kb2N1bWVudGF0aW9uEjgKDXJlbGF0aW9uc2hpcHMYBCADKAsyEi5zY2lwLlJlbGF0aW9uc2hpcFINcmVsYXRpb25zaGlwcw=='); +final $typed_data.Uint8List symbolInformationDescriptor = $convert.base64Decode('ChFTeW1ib2xJbmZvcm1hdGlvbhIWCgZzeW1ib2wYASABKAlSBnN5bWJvbBIkCg1kb2N1bWVudGF0aW9uGAMgAygJUg1kb2N1bWVudGF0aW9uEjgKDXJlbGF0aW9uc2hpcHMYBCADKAsyEi5zY2lwLlJlbGF0aW9uc2hpcFINcmVsYXRpb25zaGlwcxIwCgRraW5kGAUgASgOMhwuc2NpcC5TeW1ib2xJbmZvcm1hdGlvbi5LaW5kUgRraW5kEiEKDGRpc3BsYXlfbmFtZRgGIAEoCVILZGlzcGxheU5hbWUSRwoXc2lnbmF0dXJlX2RvY3VtZW50YXRpb24YByABKAsyDi5zY2lwLkRvY3VtZW50UhZzaWduYXR1cmVEb2N1bWVudGF0aW9uEikKEGVuY2xvc2luZ19zeW1ib2wYCCABKAlSD2VuY2xvc2luZ1N5bWJvbCKOBwoES2luZBITCg9VbnNwZWNpZmllZEtpbmQQABIJCgVBcnJheRABEg0KCUFzc2VydGlvbhACEhIKDkFzc29jaWF0ZWRUeXBlEAMSDQoJQXR0cmlidXRlEAQSCQoFQXhpb20QBRILCgdCb29sZWFuEAYSCQoFQ2xhc3MQBxIMCghDb25zdGFudBAIEg8KC0NvbnN0cnVjdG9yEAkSDAoIQ29udHJhY3QQPhIOCgpEYXRhRmFtaWx5EAoSCAoERW51bRALEg4KCkVudW1NZW1iZXIQDBIJCgVFcnJvchA/EgkKBUV2ZW50EA0SCAoERmFjdBAOEgkKBUZpZWxkEA8SCAoERmlsZRAQEgwKCEZ1bmN0aW9uEBESCgoGR2V0dGVyEBISCwoHR3JhbW1hchATEgwKCEluc3RhbmNlEBQSDQoJSW50ZXJmYWNlEBUSBwoDS2V5EBYSCAoETGFuZxAXEgkKBUxlbW1hEBgSCwoHTGlicmFyeRBAEgkKBU1hY3JvEBkSCgoGTWV0aG9kEBoSEgoOTWV0aG9kUmVjZWl2ZXIQGxILCgdNZXNzYWdlEBwSDAoITW9kaWZpZXIQQRIKCgZNb2R1bGUQHRINCglOYW1lc3BhY2UQHhIICgROdWxsEB8SCgoGTnVtYmVyECASCgoGT2JqZWN0ECESDAoIT3BlcmF0b3IQIhILCgdQYWNrYWdlECMSEQoNUGFja2FnZU9iamVjdBAkEg0KCVBhcmFtZXRlchAlEhIKDlBhcmFtZXRlckxhYmVsECYSCwoHUGF0dGVybhAnEg0KCVByZWRpY2F0ZRAoEgwKCFByb3BlcnR5ECkSDAoIUHJvdG9jb2wQKhIPCgtRdWFzaXF1b3RlchArEhEKDVNlbGZQYXJhbWV0ZXIQLBIKCgZTZXR0ZXIQLRINCglTaWduYXR1cmUQLhINCglTdWJzY3JpcHQQLxIKCgZTdHJpbmcQMBIKCgZTdHJ1Y3QQMRIKCgZUYWN0aWMQMhILCgdUaGVvcmVtEDMSEQoNVGhpc1BhcmFtZXRlchA0EgkKBVRyYWl0EDUSCAoEVHlwZRA2Eg0KCVR5cGVBbGlhcxA3Eg0KCVR5cGVDbGFzcxA4Eg4KClR5cGVGYW1pbHkQORIRCg1UeXBlUGFyYW1ldGVyEDoSCQoFVW5pb24QOxIJCgVWYWx1ZRA8EgwKCFZhcmlhYmxlED0='); @$core.Deprecated('Use relationshipDescriptor instead') const Relationship$json = const { '1': 'Relationship', @@ -378,11 +458,12 @@ const Occurrence$json = const { const {'1': 'override_documentation', '3': 4, '4': 3, '5': 9, '10': 'overrideDocumentation'}, const {'1': 'syntax_kind', '3': 5, '4': 1, '5': 14, '6': '.scip.SyntaxKind', '10': 'syntaxKind'}, const {'1': 'diagnostics', '3': 6, '4': 3, '5': 11, '6': '.scip.Diagnostic', '10': 'diagnostics'}, + const {'1': 'enclosing_range', '3': 7, '4': 3, '5': 5, '10': 'enclosingRange'}, ], }; /// Descriptor for `Occurrence`. Decode as a `google.protobuf.DescriptorProto`. -final $typed_data.Uint8List occurrenceDescriptor = $convert.base64Decode('CgpPY2N1cnJlbmNlEhQKBXJhbmdlGAEgAygFUgVyYW5nZRIWCgZzeW1ib2wYAiABKAlSBnN5bWJvbBIhCgxzeW1ib2xfcm9sZXMYAyABKAVSC3N5bWJvbFJvbGVzEjUKFm92ZXJyaWRlX2RvY3VtZW50YXRpb24YBCADKAlSFW92ZXJyaWRlRG9jdW1lbnRhdGlvbhIxCgtzeW50YXhfa2luZBgFIAEoDjIQLnNjaXAuU3ludGF4S2luZFIKc3ludGF4S2luZBIyCgtkaWFnbm9zdGljcxgGIAMoCzIQLnNjaXAuRGlhZ25vc3RpY1ILZGlhZ25vc3RpY3M='); +final $typed_data.Uint8List occurrenceDescriptor = $convert.base64Decode('CgpPY2N1cnJlbmNlEhQKBXJhbmdlGAEgAygFUgVyYW5nZRIWCgZzeW1ib2wYAiABKAlSBnN5bWJvbBIhCgxzeW1ib2xfcm9sZXMYAyABKAVSC3N5bWJvbFJvbGVzEjUKFm92ZXJyaWRlX2RvY3VtZW50YXRpb24YBCADKAlSFW92ZXJyaWRlRG9jdW1lbnRhdGlvbhIxCgtzeW50YXhfa2luZBgFIAEoDjIQLnNjaXAuU3ludGF4S2luZFIKc3ludGF4S2luZBIyCgtkaWFnbm9zdGljcxgGIAMoCzIQLnNjaXAuRGlhZ25vc3RpY1ILZGlhZ25vc3RpY3MSJwoPZW5jbG9zaW5nX3JhbmdlGAcgAygFUg5lbmNsb3NpbmdSYW5nZQ=='); @$core.Deprecated('Use diagnosticDescriptor instead') const Diagnostic$json = const { '1': 'Diagnostic', diff --git a/lib/src/gen/scip.proto b/lib/src/gen/scip.proto index f1492a22..99bba1df 100644 --- a/lib/src/gen/scip.proto +++ b/lib/src/gen/scip.proto @@ -1,6 +1,3 @@ -/// Comes From: https://github.com/sourcegraph/scip/blob/main/scip.proto -/// scip v0.2.3 - // An index contains one or more pieces of information about a given piece of // source code or software artifact. Complementary information can be merged // together from multiple sources to provide a unified code intelligence @@ -34,6 +31,8 @@ message Index { // external package won't get indexed for some reason then you can use this // field to provide hover documentation for those external symbols. repeated SymbolInformation external_symbols = 3; + // IMPORTANT: When adding a new field to `Index` here, add a matching + // function in `IndexVisitor` and update `ParseStreaming`. } message Metadata { @@ -73,7 +72,7 @@ message ToolInfo { message Document { // The string ID for the programming language this file is written in. // The `Language` enum contains the names of most common programming languages. - // This field is typed as a string to permit any programming langauge, including + // This field is typed as a string to permit any programming language, including // ones that are not specified by the `Language` enum. string language = 4; // (Required) Unique path to the text document. @@ -94,6 +93,15 @@ message Document { // but have a reference and are defined by some other symbol (see // Relationship.is_definition). repeated SymbolInformation symbols = 3; + + // (optional) Text contents of the this document. Indexers are not expected to + // include the text by default. It's preferrable that clients read the text + // contents from the file system by resolving the absolute path from joining + // `Index.metadata.project_root` and `Document.relative_path`. This field was + // introduced to support `SymbolInformation.signature_documentation`, but it + // can be used for other purposes as well, for example testing or when working + // with virtual/in-memory documents. + string text = 5; } @@ -111,11 +119,12 @@ message Document { // ::= same as above, use the placeholder '.' to indicate an empty value // ::= same as above // ::= same as above -// ::= | | | | | | +// ::= | | | | | | | // ::= '/' // ::= '#' // ::= '.' // ::= ':' +// ::= '!' // ::= '(' ').' // ::= '[' ']' // ::= '(' ')' @@ -163,10 +172,10 @@ message Descriptor { Method = 4; TypeParameter = 5; Parameter = 6; - Macro = 9; // Can be used for any purpose. Meta = 7; Local = 8; + Macro = 9; } string name = 1; string disambiguator = 2; @@ -180,14 +189,174 @@ message SymbolInformation { // The string must be formatted according to the grammar in `Symbol`. string symbol = 1; // (optional, but strongly recommended) The markdown-formatted documentation - // for this symbol. This field is repeated to allow different kinds of - // documentation. For example, it's nice to include both the signature of a - // method (parameters and return type) along with the accompanying docstring. + // for this symbol. Use `SymbolInformation.signature_documentation` to + // document the method/class/type signature of this symbol. + // Due to historical reasons, indexers may include signature documentation in + // this field by rendering markdown code blocks. New indexers should only + // include non-code documentation in this field, for example docstrings. repeated string documentation = 3; // (optional) Relationships to other symbols (e.g., implements, type definition). repeated Relationship relationships = 4; + // The kind of this symbol. Use this field instead of + // `SymbolDescriptor.Suffix` to determine whether something is, for example, a + // class or a method. + Kind kind = 5; + // (optional) Kind represents the fine-grained category of a symbol, suitable for presenting + // information about the symbol's meaning in the language. + // + // For example: + // - A Java method would have the kind `Method` while a Go function would + // have the kind `Function`, even if the symbols for these use the same + // syntax for the descriptor `SymbolDescriptor.Suffix.Method`. + // - A Go struct has the symbol kind `Struct` while a Java class has + // the symbol kind `Class` even if they both have the same descriptor: + // `SymbolDescriptor.Suffix.Type`. + // + // Since Kind is more fine-grained than Suffix: + // - If two symbols have the same Kind, they should share the same Suffix. + // - If two symbols have different Suffixes, they should have different Kinds. + enum Kind { + UnspecifiedKind = 0; + Array = 1; + // For Alloy + Assertion = 2; + AssociatedType = 3; + // For C++ + Attribute = 4; + // For Lean + Axiom = 5; + Boolean = 6; + Class = 7; + Constant = 8; + Constructor = 9; + // For Solidity + Contract = 62; + // For Haskell + DataFamily = 10; + Enum = 11; + EnumMember = 12; + Error = 63; + Event = 13; + // For Alloy + Fact = 14; + Field = 15; + File = 16; + Function = 17; + // For 'get' in Swift + Getter = 18; + // For Raku + Grammar = 19; + // For Purescript and Lean + Instance = 20; + Interface = 21; + Key = 22; + // For Racket + Lang = 23; + // For Lean + Lemma = 24; + // For solidity + Library = 64; + Macro = 25; + Method = 26; + // Analogous to 'ThisParameter' and 'SelfParameter', but for languages + // like Go where the receiver doesn't have a conventional name. + MethodReceiver = 27; + // For Protobuf + Message = 28; + // For Solidity + Modifier = 65; + Module = 29; + Namespace = 30; + Null = 31; + Number = 32; + Object = 33; + Operator = 34; + Package = 35; + PackageObject = 36; + Parameter = 37; + ParameterLabel = 38; + // For Haskell's PatternSynonyms + Pattern = 39; + // For Alloy + Predicate = 40; + Property = 41; + // Analogous to 'Trait' and 'TypeClass', for Swift and Objective-C + Protocol = 42; + // For Haskell + Quasiquoter = 43; + // 'self' in Python, Rust, Swift etc. + SelfParameter = 44; + // For 'set' in Swift + Setter = 45; + // For Alloy, analogous to 'Struct'. + Signature = 46; + // For Swift + Subscript = 47; + String = 48; + Struct = 49; + // For Lean + Tactic = 50; + // For Lean + Theorem = 51; + // Method receiver for languages + // 'this' in JavaScript, C++, Java etc. + ThisParameter = 52; + // Analogous to 'Protocol' and 'TypeClass', for Rust. + Trait = 53; + // Data type definition for languages like OCaml which use `type` + // rather than separate keywords like `struct` and `enum`. + Type = 54; + TypeAlias = 55; + // Analogous to 'Trait' and 'Protocol', for Haskell, Purescript etc. + TypeClass = 56; + // For Haskell + TypeFamily = 57; + TypeParameter = 58; + // For C, C++, Capn Proto + Union = 59; + Value = 60; + Variable = 61; + // Next = 66; + // Feel free to open a PR proposing new language-specific kinds. + } + // (optional) The name of this symbol as it should be displayed to the user. + // For example, the symbol "com/example/MyClass#myMethod(+1)." should have the + // display name "myMethod". The `symbol` field is not a reliable source of + // the display name for several reasons: + // + // - Local symbols don't encode the name. + // - Some languages have case-insensitive names, so the symbol is all-lowercase. + // - The symbol may encode names with special characters that should not be + // displayed to the user. + string display_name = 6; + // (optional) The signature of this symbol as it's displayed in API + // documentation or in hover tooltips. For example, a Java method that adds + // two numbers this would have `Document.language = "java"` and `Document.text + // = "void add(int a, int b)". The `language` and `text` fields are required + // while other fields such as `Documentation.occurrences` can be optionally + // included to support hyperlinking referenced symbols in the signature. + Document signature_documentation = 7; + // (optional) The enclosing symbol if this is a local symbol. For non-local + // symbols, the enclosing symbol should be parsed from the `symbol` field + // using the `Descriptor` grammar. + // + // The primary use-case for this field is to allow local symbol to be displayed + // in a symbol hierarchy for API documentation. It's OK to leave this field + // empty for local variables since local variables usually don't belong in API + // documentation. However, in the situation that you wish to include a local + // symbol in the hierarchy, then you can use `enclosing_symbol` to locate the + // "parent" or "owner" of this local symbol. For example, a Java indexer may + // choose to use local symbols for private class fields while providing an + // `enclosing_symbol` to reference the enclosing class to allow the field to + // be part of the class documentation hierarchy. From the perspective of an + // author of an indexer, the decision to use a local symbol or global symbol + // should exclusively be determined whether the local symbol is accessible + // outside the document, not by the capability to find the enclosing + // symbol. + string enclosing_symbol = 8; } + message Relationship { string symbol = 1; // When resolving "Find references", this field documents what other symbols @@ -201,9 +370,9 @@ message Relationship { // ^^^^^ definition Animal#sound() // } // class Dog implements Animal { - // ^^^ definition Dog#, implementation_symbols = Animal# + // ^^^ definition Dog#, relationships = [{symbol: "Animal#", is_implementation: true}] // public sound(): string { return "woof" } - // ^^^^^ definition Dog#sound(), references_symbols = Animal#sound(), implementation_symbols = Animal#sound() + // ^^^^^ definition Dog#sound(), references_symbols = Animal#sound(), relationships = [{symbol: "Animal#sound()", is_implementation:true, is_reference: true}] // } // const animal: Animal = new Dog() // ^^^^^^ reference Animal# @@ -215,14 +384,14 @@ message Relationship { // references" on the `Dog#sound()` method should include references to the // `Animal#sound()` method as well. bool is_reference = 2; - // Similar to `references_symbols` but for "Go to implementation". - // It's common for the `implementation_symbols` and `references_symbols` fields - // have the same values but that's not always the case. - // In the TypeScript example above, observe that `implementation_symbols` has - // the value `"Animal#"` for the "Dog#" symbol while `references_symbols` is - // empty. When requesting "Find references" on the "Animal#" symbol we don't - // want to include references to "Dog#" even if "Go to implementation" on the - // "Animal#" symbol should navigate to the "Dog#" symbol. + // Similar to `is_reference` but for "Find implementations". + // It's common for `is_implementation` and `is_reference` to both be true but + // it's not always the case. + // In the TypeScript example above, observe that `Dog#` has an + // `is_implementation` relationship with `"Animal#"` but not `is_reference`. + // This is because "Find references" on the "Animal#" symbol should not return + // "Dog#". We only want "Dog#" to return as a result for "Find + // implementations" on the "Animal#" symbol. bool is_implementation = 3; // Similar to `references_symbols` but for "Go to type definition". bool is_type_definition = 4; @@ -246,7 +415,7 @@ message Relationship { // Update registerInverseRelationships on adding a new field here. } -// SymbolRole declares what "role" a symbol has in an occurrence. A role is +// SymbolRole declares what "role" a symbol has in an occurrence. A role is // encoded as a bitset where each bit represents a different role. For example, // to determine if the `Import` role is set, test whether the second bit of the // enum value is defined. In pseudocode, this can be implemented with the @@ -385,7 +554,7 @@ message Occurrence { // type with `start` and `end` fields of type `Position`, mirroring LSP. // Benchmarks revealed that this encoding was inefficient and that we could // reduce the total payload size of an index by 50% by using `repeated int32` - // instead. The `repeated int32` encoding is admittedly more embarrassing to + // instead. The `repeated int32` encoding is admittedly more embarrassing to // work with in some programming languages but we hope the performance // improvements make up for it. repeated int32 range = 1; @@ -408,6 +577,46 @@ message Occurrence { SyntaxKind syntax_kind = 5; // (optional) Diagnostics that have been reported for this specific range. repeated Diagnostic diagnostics = 6; + // (optional) Using the same encoding as the sibling `range` field, source + // position of the nearest non-trivial enclosing AST node. This range must + // enclose the `range` field. Example applications that make use of the + // enclosing_range field: + // + // - Call hierarchies: to determine what symbols are references from the body + // of a function + // - Symbol outline: to display breadcrumbs from the cursor position to the + // root of the file + // - Expand selection: to select the nearest enclosing AST node. + // - Highlight range: to indicate the AST expression that is associated with a + // hover popover + // + // For definition occurrences, the enclosing range should indicate the + // start/end bounds of the entire definition AST node, including + // documentation. + // ``` + // const n = 3 + // ^ range + // ^^^^^^^^^^^ enclosing_range + // + // /** Parses the string into something */ + // ^ enclosing_range start --------------------------------------| + // function parse(input string): string { | + // ^^^^^ range | + // return input.slice(n) | + // } | + // ^ enclosing_range end <---------------------------------------| + // ``` + // For reference occurrences, the enclosing range should indicate the start/end + // bounds of the parent expression. + // ``` + // const a = a.b + // ^ range + // ^^^ enclosing_range + // const b = a.b(41).f(42).g(43) + // ^ range + // ^^^^^^^^^^^^^ enclosing_range + // ``` + repeated int32 enclosing_range = 7; } // Represents a diagnostic, such as a compiler error or warning, which should be @@ -443,7 +652,7 @@ enum DiagnosticTag { // for the `Document.language` field. The primary purpose of this enum is to // prevent a situation where we have a single programming language ends up with // multiple string representations. For example, the C++ language uses the name -// "CPlusPlus" in this enum and other names such as "cpp" are incompatible. +// "CPP" in this enum and other names such as "cpp" are incompatible. // Feel free to send a pull-request to add missing programming languages. enum Language { UnspecifiedLanguage = 0; @@ -528,6 +737,7 @@ enum Language { Scheme = 10; ShellScript = 64; // Bash Skylark = 78; + Solidity = 95; Swift = 2; TOML = 73; TeX = 82; @@ -540,7 +750,7 @@ enum Language { XSL = 32; YAML = 74; Zig = 38; - // NextLanguage = 95; + // NextLanguage = 96; // Steps add a new language: // 1. Copy-paste the "NextLanguage = N" line above // 2. Increment "NextLanguage = N" to "NextLanguage = N+1" diff --git a/lib/src/metadata.dart b/lib/src/metadata.dart index 72a1c3cd..0ee77c29 100644 --- a/lib/src/metadata.dart +++ b/lib/src/metadata.dart @@ -6,9 +6,13 @@ import 'package:analyzer/dart/element/element.dart'; /// Use [getSymbolMetadata] to retrieve [SymbolMetadata] for a provided /// [Element] type. class SymbolMetadata { - List documentation; + List? documentation; + String signatureDocumentation; - SymbolMetadata({required this.documentation}); + SymbolMetadata({ + this.documentation, + required this.signatureDocumentation, + }); } /// Returns a [SymbolMetadata] object for a provided [Element] type. @@ -16,20 +20,18 @@ class SymbolMetadata { /// This information is used to embellish `SymbolInformation` struct's /// within the protobuf schema for scip SymbolMetadata getSymbolMetadata(Element element) { - final displayString = element.getDisplayString( - withNullability: false, - multiline: true, - ); - final docComment = element.documentationComment?.replaceAll( RegExp(r'^\s*///\s*', multiLine: true), '', ); + final displayString = element.getDisplayString( + withNullability: false, + multiline: true, + ); + return SymbolMetadata( - documentation: [ - '```dart\n$displayString\n```', - if (docComment != null) docComment - ], + documentation: docComment != null ? [docComment] : null, + signatureDocumentation: displayString, ); } diff --git a/lib/src/scip_visitor.dart b/lib/src/scip_visitor.dart index f080764b..272230c2 100644 --- a/lib/src/scip_visitor.dart +++ b/lib/src/scip_visitor.dart @@ -169,6 +169,10 @@ class ScipVisitor extends GeneralizingAstVisitor { globalExternalSymbols.add(SymbolInformation( symbol: symbol, documentation: meta.documentation, + signatureDocumentation: Document( + language: Language.Dart.name, + text: meta.signatureDocumentation, + ), )); } } @@ -189,6 +193,10 @@ class ScipVisitor extends GeneralizingAstVisitor { symbols.add(SymbolInformation( symbol: symbol, documentation: meta.documentation, + signatureDocumentation: Document( + language: Language.Dart.name, + text: meta.signatureDocumentation, + ), relationships: relationships, )); diff --git a/snapshots/output/basic-project/lib/main.dart b/snapshots/output/basic-project/lib/main.dart index b20c0acd..0591d7ac 100755 --- a/snapshots/output/basic-project/lib/main.dart +++ b/snapshots/output/basic-project/lib/main.dart @@ -8,11 +8,9 @@ int fib(int n) { //^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/fib(). -// documentation ```dart // documentation This is a fib function // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^ definition local 0 -// documentation ```dart if (n <= 1) return 0; // ^ reference local 0 return fib(n - 1) + fib(n - 2); @@ -24,10 +22,8 @@ void print_fib(int a) { // ^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/print_fib(). -// documentation ```dart // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^ definition local 1 -// documentation ```dart print(fib(a)); // ^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/print.dart/print(). // ^^^ reference scip-dart pub dart_test 1.0.0 lib/main.dart/fib(). @@ -36,32 +32,26 @@ final y = 'Hello'; // ^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/y. -// documentation ```dart String capture() { //^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/capture(). -// documentation ```dart return y; // ^ reference scip-dart pub dart_test 1.0.0 lib/main.dart/y. } final capture_lambda = () => y; // ^^^^^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/capture_lambda. -// documentation ```dart // ^ reference scip-dart pub dart_test 1.0.0 lib/main.dart/y. void main() { // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/main(). -// documentation ```dart for (var i = 0; i <= 10; i++) {} // ^ definition local 2 -// documentation ```dart // ^ reference local 2 // ^ reference local 2 for (var i in [1, 2, 3]) { // ^ definition local 3 -// documentation ```dart print(i); // ^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/print.dart/print(). // ^ reference local 3 @@ -69,7 +59,6 @@ var a = 0; // ^ definition local 4 -// documentation ```dart a = 1; // ^ reference local 4 print_fib(a); @@ -79,14 +68,12 @@ void forever() { // ^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/forever(). -// documentation ```dart return forever(); // ^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/main.dart/forever(). } class SomeLocalClass {} // ^^^^^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/SomeLocalClass# -// documentation ```dart /// Reference parameter: [value] // ^^^^^ reference local 5 @@ -97,11 +84,9 @@ /// Missing Reference: [IDontExist] void someFunction(int value) { // ^^^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/someFunction(). -// documentation ```dart // documentation Reference parameter: [value] // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^^^ definition local 5 -// documentation ```dart Foo(1); // ^^^ reference scip-dart pub dart_test 1.0.0 lib/other.dart/Foo# } diff --git a/snapshots/output/basic-project/lib/more.dart b/snapshots/output/basic-project/lib/more.dart index 7de9ef01..524c5e96 100755 --- a/snapshots/output/basic-project/lib/more.dart +++ b/snapshots/output/basic-project/lib/more.dart @@ -1,32 +1,24 @@ import 'dart:math' as math; // definition scip-dart pub dart_test 1.0.0 lib/more.dart/ // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/math. -// documentation ```dart enum AnimalType { // ^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType# -// documentation ```dart cat, // ^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType#cat. -// documentation ```dart dog, // ^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType#dog. -// documentation ```dart bird, // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType#bird. -// documentation ```dart } typedef SoundMaker = void Function(); // ^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/SoundMaker# -// documentation ```dart mixin SleepMixin { // ^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/SleepMixin# -// documentation ```dart void sleep() { // ^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/SleepMixin#sleep(). -// documentation ```dart print('zzz...'); // ^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/print.dart/print(). } @@ -34,31 +26,24 @@ class Animal with SleepMixin { // ^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal# -// documentation ```dart // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/SleepMixin# String name; // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#name. -// documentation ```dart AnimalType type; // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType# // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#type. -// documentation ```dart SoundMaker? soundMaker; // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/SoundMaker# // ^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#soundMaker. -// documentation ```dart Animal(this.name, {required this.type}) { // ^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#(). -// documentation ```dart // ^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal# // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#name. // ^^^^ definition local 0 -// documentation ```dart // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#type. // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#().(type) -// documentation ```dart switch (type) { // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#type. case AnimalType.cat: @@ -91,7 +76,6 @@ void makeSound() { // ^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#makeSound(). -// documentation ```dart soundMaker?.call(); // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#soundMaker. } @@ -101,7 +85,6 @@ String toString() { // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#toString(). -// documentation ```dart return '$name the $type'; // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#name. // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#type. @@ -111,41 +94,33 @@ int calculateSum(List numbers) { //^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/calculateSum(). -// documentation ```dart // ^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/list.dart/List# // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^^^^^ definition local 1 -// documentation ```dart return numbers.reduce((value, element) => value + element); // ^^^^^^^ reference local 1 // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/iterable.dart/Iterable#reduce(). // ^^^^^ definition local 2 -// documentation ```dart // ^^^^^^^ definition local 3 -// documentation ```dart // ^^^^^ reference local 2 // ^^^^^^^ reference local 3 } void main() { // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/more.dart/main(). -// documentation ```dart List numbers = [1, 2, 3, 4, 5]; // ^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/list.dart/List# // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^^^^^ definition local 4 -// documentation ```dart int sum = calculateSum(numbers); // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^ definition local 5 -// documentation ```dart // ^^^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/calculateSum(). // ^^^^^^^ reference local 4 Animal cat = Animal('Kitty', type: AnimalType.cat); // ^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal# // ^^^ definition local 6 -// documentation ```dart // ^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal# // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#().(type) // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType# @@ -153,7 +128,6 @@ Animal dog = Animal('Buddy', type: AnimalType.dog); // ^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal# // ^^^ definition local 7 -// documentation ```dart // ^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal# // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/Animal#().(type) // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/more.dart/AnimalType# diff --git a/snapshots/output/basic-project/lib/other.dart b/snapshots/output/basic-project/lib/other.dart index d8eadfed..7e0f9422 100755 --- a/snapshots/output/basic-project/lib/other.dart +++ b/snapshots/output/basic-project/lib/other.dart @@ -1,42 +1,32 @@ import 'more.dart' deferred as more; // definition scip-dart pub dart_test 1.0.0 lib/other.dart/ // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/more. -// documentation ```dart class Foo { // ^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/Foo# -// documentation ```dart int _far; // ^^^ reference scip-dart pub dart:core 2.18.0 dart:core/int.dart/int# // ^^^^ definition local 0 -// documentation ```dart Foo(this._far); // ^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/Foo#(). -// documentation ```dart // ^^^ reference scip-dart pub dart_test 1.0.0 lib/other.dart/Foo# // ^^^^ reference local 0 // ^^^^ definition local 1 -// documentation ```dart } class Bar { // ^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/Bar# -// documentation ```dart String _someValue; // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^^^^^^ definition local 2 -// documentation ```dart Bar(this._someValue); // ^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/Bar#(). -// documentation ```dart // ^^^ reference scip-dart pub dart_test 1.0.0 lib/other.dart/Bar# // ^^^^ reference local 2 // ^^^^^^^^^^ definition local 3 -// documentation ```dart void someMethod() { // ^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/Bar#someMethod(). -// documentation ```dart _someValue = 'asdf'; // ^^^^^^^^^^ reference local 2 print(_someValue); @@ -47,12 +37,10 @@ void main() { // ^^^^ definition scip-dart pub dart_test 1.0.0 lib/other.dart/main(). -// documentation ```dart more.loadLibrary().then((_) => { // ^^^^ reference scip-dart pub dart_test 1.0.0 lib/other.dart/more. // ^^^^ reference scip-dart pub dart:async 2.18.0 dart:async/future.dart/Future#then(). // ^ definition local 4 -// documentation ```dart Bar('a').someMethod.call() // ^^^ reference scip-dart pub dart_test 1.0.0 lib/other.dart/Bar# // ^^^^^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/other.dart/Bar#someMethod(). diff --git a/snapshots/output/basic-project/test/basic_test.dart b/snapshots/output/basic-project/test/basic_test.dart index a7506aae..920edeeb 100755 --- a/snapshots/output/basic-project/test/basic_test.dart +++ b/snapshots/output/basic-project/test/basic_test.dart @@ -3,7 +3,6 @@ void main() { // ^^^^ definition scip-dart pub dart_test 1.0.0 test/basic_test.dart/main(). -// documentation ```dart group('some test', () { // ^^^^^ reference scip-dart pub test_core 0.5.3 lib/scaffolding.dart/group(). test('equality', () { diff --git a/snapshots/output/relationships-project/lib/main.dart b/snapshots/output/relationships-project/lib/main.dart index b99c84b9..58fe3991 100755 --- a/snapshots/output/relationships-project/lib/main.dart +++ b/snapshots/output/relationships-project/lib/main.dart @@ -1,36 +1,29 @@ abstract class Mammal { // definition scip-dart pub dart_test 1.0.0 lib/main.dart/ // ^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Mammal# -// documentation ```dart String get hierarchy; // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Mammal#hierarchy. -// documentation ```dart } abstract class Animal extends Mammal { // ^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Animal# -// documentation ```dart // relationship scip-dart pub dart_test 1.0.0 lib/main.dart/Mammal# implementation // ^^^^^^ reference scip-dart pub dart_test 1.0.0 lib/main.dart/Mammal# String sound() => 'NOISE!'; // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Animal#sound(). -// documentation ```dart } mixin SwimAction { // ^^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/SwimAction# -// documentation ```dart void execute() => print('swimming...'); // ^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/SwimAction#execute(). -// documentation ```dart // ^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/print.dart/print(). } class Dog extends Animal with SwimAction { // ^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Dog# -// documentation ```dart // relationship scip-dart pub dart_test 1.0.0 lib/main.dart/Animal# implementation // relationship scip-dart pub dart_test 1.0.0 lib/main.dart/Mammal# implementation // relationship scip-dart pub dart_test 1.0.0 lib/main.dart/SwimAction# implementation @@ -41,7 +34,6 @@ String sound() => 'woof'; // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Dog#sound(). -// documentation ```dart // relationship scip-dart pub dart_test 1.0.0 lib/main.dart/Animal#sound(). implementation reference @override @@ -49,6 +41,5 @@ String get hierarchy => 'dog.animal.mammal'; // ^^^^^^ reference scip-dart pub dart:core 2.18.0 dart:core/string.dart/String# // ^^^^^^^^^ definition scip-dart pub dart_test 1.0.0 lib/main.dart/Dog#hierarchy. -// documentation ```dart // relationship scip-dart pub dart_test 1.0.0 lib/main.dart/Mammal#hierarchy. implementation reference }