Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IndexOutOfRangeException in UseConcreteTypeAnalyzer #7514

Open
jnm2 opened this issue Dec 21, 2024 · 0 comments
Open

IndexOutOfRangeException in UseConcreteTypeAnalyzer #7514

jnm2 opened this issue Dec 21, 2024 · 0 comments

Comments

@jnm2
Copy link
Contributor

jnm2 commented Dec 21, 2024

Version Used: 17.13.0 Preview 2.1

Analyzer 'Microsoft.NetCore.Analyzers.Performance.UseConcreteTypeAnalyzer' threw an exception of type 'System.IndexOutOfRangeException' with message 'Index was outside the bounds of the array.'.
Exception occurred with following context:
Compilation: Microsoft.CodeAnalysis.Workspaces
IOperation: Invocation
SyntaxTree: D:\Source\roslyn\src\Workspaces\Core\Portable\Storage\SQLite\v2\SQLitePersistentStorage_Threading.cs
SyntaxNode: vt.Item1() [InvocationExpressionSyntax]@[3458..3468) (61,12)-(61,22)

System.IndexOutOfRangeException: Index was outside the bounds of the array.
   at Analyzer.Utilities.AnalyzerOptionsExtensions.TryGetSyntaxTreeForOption(ISymbol symbol, SyntaxTree& tree)
   at Microsoft.NetCore.Analyzers.Performance.UseConcreteTypeAnalyzer.<>c__DisplayClass9_1.<Initialize>b__4(ISymbol symbol)
   at Microsoft.NetCore.Analyzers.Performance.UseConcreteTypeAnalyzer.Collector.HandleInvocation(IInvocationOperation op)
   at Microsoft.CodeAnalysis.Diagnostics.AnalyzerExecutor.ExecuteAndCatchIfThrows_NoLock[TArg](DiagnosticAnalyzer analyzer, Action`1 analyze, TArg argument, Nullable`1 info, CancellationToken cancellationToken)
-----

Suppress the following diagnostics to disable this analyzer: CA1859
@333fred 333fred transferred this issue from dotnet/roslyn Dec 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant