169 references to GetLocation
Microsoft.CodeAnalysis.VisualBasic (131)
Binding\Binder_AnonymousTypes.vb (1)
200Me._fields(fieldIndex) = New AnonymousTypeField(fieldName, fieldNode.GetLocation(), fieldIsKey)
Binding\Binder_Constraints.vb (4)
58constraintsBuilder.Add(New TypeParameterConstraint(TypeParameterConstraintKind.Constructor, syntax.GetLocation())) 68constraintsBuilder.Add(New TypeParameterConstraint(TypeParameterConstraintKind.ReferenceType, syntax.GetLocation())) 80constraintsBuilder.Add(New TypeParameterConstraint(TypeParameterConstraintKind.ValueType, syntax.GetLocation())) 90constraintsBuilder.Add(New TypeParameterConstraint(constraintType, syntax.GetLocation()))
Binding\Binder_Expressions.vb (4)
341elementLocations.Add(nameSyntax.GetLocation) 349elementLocations.Add(argumentSyntax.GetLocation) 374inferredType = TupleTypeSymbol.Create(node.GetLocation, elements, locations, elementNames, Me.Compilation, 2993Dim referenceLocation As Location = node.GetLocation()
Binding\Binder_Invocation.vb (4)
1320Return DirectCast(result, QualifiedNameSyntax).Right.GetLocation() 1327Return DirectCast(result, MemberAccessExpressionSyntax).Name.GetLocation() 1332Return DirectCast(result, XmlMemberAccessExpressionSyntax).Name.GetLocation() 1335Return DirectCast(result, HandlesClauseItemSyntax).EventMember.GetLocation()
Binding\Binder_Lambda.vb (1)
801parameters(i).Name, parameters(i).Type, sourceParameter.Syntax.GetLocation(), parameters(i).IsByRef)
Binding\Binder_Query.vb (13)
258fields(i) = New AnonymousTypeField(rangeVar.Name, rangeVar.Type, rangeVar.Syntax.GetLocation(), isKeyOrByRef:=True) 2185Dim param = New BoundLambdaParameterSymbol(name, ordinal, type, isByRef:=False, syntaxNode:=syntaxNode, location:=syntaxNode.GetLocation()) 2195Dim param = New BoundLambdaParameterSymbol(name, ordinal, type, isByRef:=False, syntaxNode:=syntaxNode, location:=syntaxNode.GetLocation()) 2788rangeVar.Name, rangeVar.Type, rangeVar.Syntax.GetLocation(), isKeyOrByRef:=True) 3215fields(j) = New AnonymousTypeField(leftVar.Name, leftVar.Type, leftVar.Syntax.GetLocation(), isKeyOrByRef:=True) 3237rangeVarOpt.Name, rangeVarOpt.Type, rangeVarOpt.Syntax.GetLocation(), isKeyOrByRef:=True) 3351"Key" & i.ToString(), outerKeys(i).Type, joinConditions(i).GetLocation(), isKeyOrByRef:=True) 3809keysRangeVariables(0).Syntax.GetLocation(), isKeyOrByRef:=True) 3819keysRangeVariablesPart1(0).Syntax.GetLocation(), 3825keysRangeVariablesPart2(0).Syntax.GetLocation(), 3837fields(i) = New AnonymousTypeField(rangeVar.Name, rangeVar.Type, rangeVar.Syntax.GetLocation(), isKeyOrByRef:=True) 3852fields(keys) = New AnonymousTypeField(rangeVar.Name, rangeVar.Type, rangeVar.Syntax.GetLocation(), isKeyOrByRef:=True) 3865rangeVar.Name, rangeVar.Type, rangeVar.Syntax.GetLocation(), isKeyOrByRef:=True)
Binding\Binder_Symbols.vb (2)
647locations.Add(argumentSyntax.GetLocation) 674Return TupleTypeSymbol.Create(syntax.GetLocation,
Binding\Binder_Utils.vb (2)
311diagBag.Add(pair.UseSiteInfo, syntaxTypeArgument.GetLocation()) 1001Dim location = identifier.GetLocation()
Compilation\DocumentationComments\DocumentationCommentCompiler.Common.vb (10)
178Me._diagnostics.Add(errorId, node.GetLocation(), args) 291Me._diagnostics.Add(ERRID.WRN_XMLDocDuplicateXMLNode1, node2.Node.GetLocation(), tagName) 367Me._diagnostics.Add(ERRID.WRN_XMLDocExceptionTagWithoutCRef, element.GetLocation()) 436node.GetLocation(), 511Me._diagnostics.Add(badNameValueError, node.GetLocation(), nameValue.Trim(), symbolName) 589Me._diagnostics.Add(ERRID.WRN_XMLDocParseError1, trivia.GetLocation(), GetDescription(ex)) 661Me._diagnostics.Add(badNameValueError, attr.GetLocation(), attributeValue, symbolName) 671Me._diagnostics.Add(missingNameValueError, element.GetLocation()) 686Me._diagnostics.Add(ERRID.WRN_XMLDocMoreThanOneCommentBlock, theOnlyDocCommentTrivia.GetLocation()) 704Me._diagnostics.Add(ERRID.WRN_XMLDocBadXMLLine, theOnlyDocCommentTrivia.GetLocation())
Compilation\DocumentationComments\DocumentationCommentCompiler.Includes.vb (1)
593location = originatingSyntax.GetLocation()
Compilation\DocumentationComments\DocumentationCommentCompiler.NamedType.vb (1)
72Me._diagnostics.Add(ERRID.WRN_XMLDocOnAPartialType, trivia.GetLocation(), symbolName)
Compilation\DocumentationComments\DocumentationCommentWalker.vb (2)
281ProcessBadNameInCrefAttribute(crefAttr, crefAttr.GetLocation, errid.Value) 307Dim location = If(errorLocation, reference.GetLocation)
Compilation\SyntaxTreeSemanticModel.vb (1)
1340Return New AliasSymbol(binder.Compilation, binder.ContainingNamespaceOrType, aliasName, targetSymbol, declarationSyntax.GetLocation())
Errors\DiagnosticBagExtensions.vb (1)
63Return Not useSiteDiagnostics.IsNullOrEmpty AndAlso diagnostics.Add(node.GetLocation, useSiteDiagnostics)
Errors\MessageProvider.vb (7)
499diagnostics.Add(ERRID.ERR_BadAttribute1, node.ArgumentList.Arguments(parameterIndex).GetLocation(), attribute.AttributeClass) 504diagnostics.Add(ERRID.ERR_BadAttribute1, node.ArgumentList.Arguments(namedArgumentIndex).GetLocation(), attributeClass) 509diagnostics.Add(ERRID.ERR_ParameterNotValidForType, node.ArgumentList.Arguments(namedArgumentIndex).GetLocation()) 514diagnostics.Add(ERRID.ERR_MarshalUnmanagedTypeNotValidForFields, node.ArgumentList.Arguments(parameterIndex).GetLocation(), unmanagedTypeName) 519diagnostics.Add(ERRID.ERR_MarshalUnmanagedTypeOnlyValidForFields, node.ArgumentList.Arguments(parameterIndex).GetLocation(), unmanagedTypeName) 524diagnostics.Add(ERRID.ERR_AttributeParameterRequired1, node.Name.GetLocation(), parameterName) 529diagnostics.Add(ERRID.ERR_AttributeParameterRequired2, node.Name.GetLocation(), parameterName1, parameterName2)
Lowering\LambdaRewriter\LambdaRewriter.vb (1)
1339Me.Diagnostics.Add(ERRID.ERR_CannotUseOnErrorGotoWithClosure, resumeLabel.ResumeStatement.GetLocation(),
OptionsValidator.vb (1)
45syntaxErrors = syntaxErrors.Concat(New VBDiagnostic(New DiagnosticInfo(MessageProvider.Instance, ERRID.ERR_ExpectedEOS), importsClausesSyntaxList(1).GetLocation()))
Symbols\Attributes\AttributeData.vb (5)
243diagnostics.Add(If(nodeOpt IsNot Nothing, nodeOpt.Name.GetLocation, NoLocation.Singleton), useSiteInfo) 248If(nodeOpt IsNot Nothing, nodeOpt.Name.GetLocation, NoLocation.Singleton)) 263Return (arg.ToString(), arg.GetLocation()) 265Return (value.ToString(), nodeOpt.GetLocation()) 400arguments.AttributeSyntaxOpt.ArgumentList.Arguments(1).GetLocation(),
Symbols\ConstraintsHelper.vb (1)
509Dim location = typeArgumentsSyntax(ordinal).GetLocation()
Symbols\Source\ImplementsHelper.vb (1)
497Not InternalSyntax.Parser.CheckFeatureAvailability(diagBag, implementedMemberSyntax.GetLocation(),
Symbols\Source\RangeVariableSymbol.vb (1)
267Return ImmutableArray.Create(Of Location)(_syntax.GetLocation())
Symbols\Source\SourceAssemblySymbol.vb (5)
938diagnostics.Add(ERRID.ERR_FriendAssemblyNameInvalid, If(nodeOpt IsNot Nothing, nodeOpt.GetLocation(), NoLocation.Singleton), displayName) 945diagnostics.Add(ERRID.ERR_FriendAssemblyNameInvalid, If(nodeOpt IsNot Nothing, nodeOpt.GetLocation(), NoLocation.Singleton), displayName) 953diagnostics.Add(ERRID.ERR_FriendAssemblyBadArguments, If(nodeOpt IsNot Nothing, nodeOpt.GetLocation(), NoLocation.Singleton), displayName) 972locationAndValue = New Tuple(Of Location, String)(If(nodeOpt IsNot Nothing, nodeOpt.GetLocation(), NoLocation.Singleton), displayName) 1125Return attributeSyntaxOpt.ArgumentList.Arguments.First().GetLocation()
Symbols\Source\SourceEventSymbol.vb (3)
363Dim location = syntax.GetLocation() 666DirectCast(arguments.Diagnostics, BindingDiagnosticBag).Add(ERRID.ERR_InvalidNonSerializedUsage, arguments.AttributeSyntaxOpt.GetLocation()) 733Return implementingSyntax.GetLocation()
Symbols\Source\SourceFieldSymbol.vb (4)
728diagnostics.Add(ERRID.ERR_InvalidNonSerializedUsage, arguments.AttributeSyntaxOpt.GetLocation()) 766diagnostics.Add(ERRID.ERR_FieldHasMultipleDistinctConstantValues, arguments.AttributeSyntaxOpt.GetLocation()) 769diagnostics.Add(ERRID.ERR_FieldHasMultipleDistinctConstantValues, arguments.AttributeSyntaxOpt.GetLocation()) 780diagnostics.Add(ERRID.ERR_FieldHasMultipleDistinctConstantValues, arguments.AttributeSyntaxOpt.GetLocation())
Symbols\Source\SourceMemberContainerTypeSymbol.vb (10)
990location = asClause.Type.GetLocation() 1027location = syntax.AsClause.Type.GetLocation() 1098location = syntax.AsClause.Type.GetLocation() 1134location = syntax.AsClause.Type.GetLocation() 2541diagBag.Add(ERRID.ERR_InvalidInNamespace, fieldDecl.GetLocation()) 2556diagBag.Add(ERRID.ERR_InvalidInNamespace, methodDecl.GetLocation()) 2575diagBag.Add(ERRID.ERR_InvalidInNamespace, methodDecl.GetLocation()) 2587diagBag.Add(ERRID.ERR_InvalidInNamespace, propertyDecl.PropertyStatement.GetLocation()) 2596diagBag.Add(ERRID.ERR_InvalidInNamespace, propertyDecl.GetLocation()) 2623diagBag.Add(ERRID.ERR_InvalidInNamespace, memberSyntax.GetLocation())
Symbols\Source\SourceMethodSymbol.vb (15)
263diagBag.Add(ERRID.ERR_BadAttribute1, syntax.LibraryName.GetLocation(), name) 272diagBag.Add(ERRID.ERR_BadAttribute1, syntax.LibraryName.GetLocation(), name) 1170Return implementingSyntax.GetLocation() 1604diagnostics.Add(ERRID.ERR_ExtensionOnlyAllowedOnModuleSubOrFunction, arguments.AttributeSyntaxOpt.GetLocation()) 1607diagnostics.Add(ERRID.ERR_ExtensionMethodNotInModule, arguments.AttributeSyntaxOpt.GetLocation()) 1673diagnostics.Add(ERRID.ERR_BadAttribute1, arguments.AttributeSyntaxOpt.ArgumentList.Arguments(position).GetLocation(), attrData.AttributeClass) 1737Binder.ReportDiagnostic(diagnostics, arguments.AttributeSyntaxOpt.GetLocation(), ERRID.ERR_SecurityCriticalAsync, "SecurityCritical") 1740Binder.ReportDiagnostic(diagnostics, arguments.AttributeSyntaxOpt.GetLocation(), ERRID.ERR_SecurityCriticalAsync, "SecuritySafeCritical") 1776diagnostics.Add(ERRID.ERR_DllImportNotLegalOnDeclare, syntax.Name.GetLocation()) 1780diagnostics.Add(ERRID.ERR_DllImportNotLegalOnGetOrSet, syntax.Name.GetLocation()) 1784diagnostics.Add(ERRID.ERR_DllImportNotLegalOnEventMethod, syntax.Name.GetLocation()) 1789diagnostics.Add(ERRID.ERR_DllImportOnInterfaceMethod, syntax.Name.GetLocation()) 1794diagnostics.Add(ERRID.ERR_DllImportOnGenericSubOrFunction, syntax.Name.GetLocation()) 1799diagnostics.Add(ERRID.ERR_DllImportOnInstanceMethod, syntax.Name.GetLocation()) 1818diagnostics.Add(ERRID.ERR_DllImportOnNonEmptySubOrFunction, syntax.Name.GetLocation())
Symbols\Source\SourceNamedTypeSymbol.vb (5)
1332backupLocation = t.GetLocation() 1341Return typeSyntax.GetLocation() 2197diagnostics.Add(ERRID.ERR_DefaultEventNotFound1, arguments.AttributeSyntaxOpt.GetLocation(), eventName) 2265diagnostics.Add(ERRID.ERR_StructLayoutAttributeNotAllowed, arguments.AttributeSyntaxOpt.GetLocation(), Me) 2296diagnostics.Add(ERRID.ERR_CantUseRequiredAttribute, arguments.AttributeSyntaxOpt.GetLocation(), Me)
Symbols\Source\SourceNamespaceSymbol.vb (3)
503Dim diag = New VBDiagnostic(ErrorFactory.ErrorInfo(ERRID.ERR_TypecharNotallowed), node.GetLocation()) 521Dim diag = New VBDiagnostic(ErrorFactory.ErrorInfo(ERRID.WRN_NamespaceCaseMismatch3, node.Identifier.ValueText, Me.Name, path), node.GetLocation()) 540Dim diag = New VBDiagnostic(ErrorFactory.ErrorInfo(ERRID.ERR_NestedGlobalNamespace), node.GetLocation())
Symbols\Source\SourcePropertySymbol.vb (3)
571diagnostics.Add(ERRID.WRN_ReturnTypeAttributeOnWriteOnlyProperty, arguments.AttributeSyntaxOpt.GetLocation()) 592diagnostics.Add(ERRID.WRN_DebuggerHiddenIgnoredOnProperties, arguments.AttributeSyntaxOpt.GetLocation()) 1011Return implementingSyntax.GetLocation()
Symbols\Source\SynthesizedEventAccessorSymbol.vb (6)
159diagnostics.Add(useSiteInfo, syntax.GetLocation()) 178diagnostics.Add(useSiteInfo, syntax.GetLocation()) 288diagnostics.Add(useSiteInfo, syntax.GetLocation()) 336diagnostics.Add(syntax.GetLocation(), conversionsUseSiteInfo) 370diagnostics.Add(useSiteInfo, syntax.GetLocation()) 413diagnostics.Add(syntax.GetLocation(), conversionsUseSiteInfo)
Symbols\Source\SynthesizedMyGroupCollectionPropertyAccessorSymbol.vb (1)
76Dim diagnosticLocation As Location = attributeSyntax.GetLocation()
Symbols\Symbol_Attributes.vb (10)
504diagnostics.Add(ERRID.ERR_InvalidMultipleAttributeUsage1, node.GetLocation(), CustomSymbolDisplayFormatter.ShortErrorName(attributeType)) 530diagnostics.Add(ERRID.ERR_InvalidAssemblyAttribute1, node.Name.GetLocation, CustomSymbolDisplayFormatter.ShortErrorName(attributeType)) 533diagnostics.Add(ERRID.ERR_InvalidModuleAttribute1, node.Name.GetLocation, CustomSymbolDisplayFormatter.ShortErrorName(attributeType)) 543diagnostics.Add(ERRID.ERR_InvalidAttributeUsageOnAccessor, node.Name.GetLocation, 550diagnostics.Add(ERRID.ERR_InvalidAttributeUsage2, node.Name.GetLocation, 562diagnostics.Add(ERRID.ERR_InvalidAttributeUsage2, node.Name.GetLocation, CustomSymbolDisplayFormatter.ShortErrorName(attributeType), ownerName) 565diagnostics.Add(ERRID.ERR_InvalidAttributeUsage2, node.Name.GetLocation, CustomSymbolDisplayFormatter.ShortErrorName(attributeType), 569diagnostics.Add(ERRID.ERR_InvalidAttributeUsage2, node.Name.GetLocation, CustomSymbolDisplayFormatter.ShortErrorName(attributeType), 582diagnostics.Add(ERRID.ERR_SecurityAttributeInvalidTarget, node.Name.GetLocation, CustomSymbolDisplayFormatter.ShortErrorName(attributeType)) 595diagnostics.Add(useSiteInfo, If(nodeOpt IsNot Nothing, nodeOpt.GetLocation(), NoLocation.Singleton))
Syntax\SyntaxFacts.vb (1)
1116If p.GetLocation.SourceSpan.Start < token.SpanStart Then
Syntax\VisualBasicWarningStateMap.vb (1)
91entries(index) = New WarningStateMapEntry(currentDirective.GetLocation().SourceSpan.End, accumulatedGeneralWarningState, accumulatedSpecificWarningState)
Microsoft.CodeAnalysis.VisualBasic.CodeStyle (6)
VisualBasicAddAccessibilityModifiersDiagnosticAnalyzer.vb (1)
61Dim additionalLocations = ImmutableArray.Create(member.GetLocation())
VisualBasicQualifyMemberAccessDiagnosticAnalyzer.vb (1)
43Return unaryExpressionSyntax.Operand.GetLocation()
VisualBasicRemoveUnnecessaryByValDiagnosticAnalyzer.vb (1)
29syntaxContext.ReportDiagnostic(Diagnostic.Create(Descriptor, modifier.GetLocation(), additionalLocations:={parameterSyntax.GetLocation()}))
VisualBasicSimplifyObjectCreationDiagnosticAnalyzer.vb (1)
57context.ReportDiagnostic(DiagnosticHelper.Create(Descriptor, variableDeclarator.GetLocation(), styleOption.Notification.Severity,
VisualBasicUseInferredMemberNameDiagnosticAnalyzer.vb (1)
56nameColonEquals.GetLocation(),
VisualBasicUseIsNotDiagnosticAnalyzer.vb (1)
75ImmutableArray.Create(notExpression.GetLocation()),
Microsoft.CodeAnalysis.VisualBasic.EditorFeatures.UnitTests (4)
Diagnostics\Suppression\SuppressionTests.vb (4)
1017context.ReportDiagnostic(Diagnostic.Create(_descriptor, ns.Name.GetLocation())) 1032context.ReportDiagnostic(Diagnostic.Create(_descriptor, f.Declarators.First().Names.First.GetLocation())) 1733context.ReportDiagnostic(Diagnostic.Create(_descriptor, ns.Name.GetLocation())) 1748context.ReportDiagnostic(Diagnostic.Create(_descriptor, f.Declarators.First().Names.First.GetLocation()))
Microsoft.CodeAnalysis.VisualBasic.Emit.UnitTests (1)
CodeGen\CodeGenTuples.vb (1)
9042Assert.Equal(nc.Name.GetLocation(), sym.Symbol.Locations(0)) ' Incorrect location
Microsoft.CodeAnalysis.VisualBasic.ExpressionEvaluator.ExpressionCompiler (2)
CompilationContext.vb (1)
426syntax.GetLocation(),
Symbols\EENamedTypeSymbol.vb (1)
265Return ImmutableArray.Create(_syntax.GetLocation())
Microsoft.CodeAnalysis.VisualBasic.Features (13)
CodeFixes\MoveToTopOfFile\MoveToTopOfFileCodeFixProvider.vb (3)
105destinationLine = root.Options.Last().GetLocation().GetLineSpan().EndLinePosition.Line + 1 143destinationLine = root.Imports.Last().GetLocation().GetLineSpan().EndLinePosition.Line + 1 145destinationLine = root.Options.Last().GetLocation().GetLineSpan().EndLinePosition.Line + 1
Completion\CompletionProviders\OverrideCompletionProvider.vb (3)
206Return methodStatement.GetLocation().SourceSpan.End 213Return lastStatement.GetLocation().SourceSpan.End 223Return lastAccessorStatement.GetLocation().SourceSpan.End
GenerateType\VisualBasicGenerateTypeService.vb (1)
439DirectCast(enclosingNamespace.Parent, NamespaceBlockSyntax).EndNamespaceStatement.GetLocation())
VisualBasicAddAccessibilityModifiersDiagnosticAnalyzer.vb (1)
61Dim additionalLocations = ImmutableArray.Create(member.GetLocation())
VisualBasicQualifyMemberAccessDiagnosticAnalyzer.vb (1)
43Return unaryExpressionSyntax.Operand.GetLocation()
VisualBasicRemoveUnnecessaryByValDiagnosticAnalyzer.vb (1)
29syntaxContext.ReportDiagnostic(Diagnostic.Create(Descriptor, modifier.GetLocation(), additionalLocations:={parameterSyntax.GetLocation()}))
VisualBasicSimplifyObjectCreationDiagnosticAnalyzer.vb (1)
57context.ReportDiagnostic(DiagnosticHelper.Create(Descriptor, variableDeclarator.GetLocation(), styleOption.Notification.Severity,
VisualBasicUseInferredMemberNameDiagnosticAnalyzer.vb (1)
56nameColonEquals.GetLocation(),
VisualBasicUseIsNotDiagnosticAnalyzer.vb (1)
75ImmutableArray.Create(notExpression.GetLocation()),
Microsoft.CodeAnalysis.VisualBasic.Semantic.UnitTests (6)
Diagnostics\DiagnosticAnalyzerTests.vb (3)
42context.ReportDiagnostic(CodeAnalysis.Diagnostic.Create(s_CA9999_UseOfVariableThatStartsWithX, id.GetLocation, id.Identifier.ValueText)) 364location = DirectCast(context.Node, NamespaceBlockSyntax).NamespaceStatement.Name.GetLocation 575Dim sourceLoc = DirectCast(context.Node, FieldDeclarationSyntax).GetLocation
Diagnostics\GetDiagnosticsTests.vb (3)
659location = propertyBlock.PropertyStatement.GetLocation() 663location = eventBlock.EventStatement.GetLocation() 667location = methodBlock.BlockStatement.GetLocation()
Microsoft.CodeAnalysis.VisualBasic.Symbol.UnitTests (1)
SymbolsTests\AnonymousTypes\AnonymousTypesSemanticsTests.vb (1)
185Assert.Equal(member.Locations(0), DirectCast(propertyInitializer, NamedFieldInitializerSyntax).Name.GetLocation())
Microsoft.CodeAnalysis.VisualBasic.Syntax.UnitTests (4)
Parser\ParseDirectives.vb (4)
3187Return CodeAnalysis.Diagnostic.Create(d, varDecl.AsClause.GetLocation) 3294Return CodeAnalysis.Diagnostic.Create(d, varDecl.AsClause.GetLocation) 3625Return CodeAnalysis.Diagnostic.Create(d, varDecl.AsClause.GetLocation) 3652Return CodeAnalysis.Diagnostic.Create(d, varDecl.AsClause.GetLocation)
Microsoft.CodeAnalysis.VisualBasic.Workspaces (1)
Rename\VisualBasicRenameRewriterLanguageService.vb (1)
820Return ImmutableArray.Create(DirectCast(token.Parent, ForEachStatementSyntax).Expression.GetLocation())