@@ -15,7 +15,8 @@ protected override void AnalyzeCompilation(CompilationStartAnalysisContext compi
1515 {
1616 var invocationOperation = ( IInvocationOperation ) operationContext . Operation ;
1717
18- if ( IsFileSystemType ( invocationOperation . TargetMethod . ContainingType , GetFileSystemTypeSymbol ( compilationStartContext . Compilation ) ) )
18+ if ( IsFileSystemType ( invocationOperation . TargetMethod . ContainingType ,
19+ GetFileSystemTypeSymbol ( compilationStartContext . Compilation ) ) )
1920 {
2021 Analyze ( operationContext , invocationOperation ) ;
2122 }
@@ -38,7 +39,8 @@ protected override void AnalyzeCompilation(CompilationStartAnalysisContext compi
3839
3940 protected abstract Type GetFileSystemType ( ) ;
4041
41- private INamedTypeSymbol GetFileSystemTypeSymbol ( Compilation compilation ) => compilation . GetTypeByMetadataName ( GetFileSystemType ( ) . FullName ) ;
42+ private INamedTypeSymbol GetFileSystemTypeSymbol ( Compilation compilation ) => compilation . GetTypeByMetadataName ( GetFileSystemType ( )
43+ . FullName ) ;
4244
4345 private static bool IsFileSystemType ( ITypeSymbol typeSymbol , INamedTypeSymbol fileSystemType )
4446 {
@@ -53,6 +55,9 @@ private static bool IsFileSystemType(ITypeSymbol typeSymbol, INamedTypeSymbol fi
5355 protected static bool IsFirstConstructorParameterOfType < T > ( OperationAnalysisContext context , IOperation operation )
5456 {
5557 var parameterTypeSymbol = context . Compilation . GetTypeByMetadataName ( typeof ( T ) . FullName ) ;
56- return ( operation as IObjectCreationOperation ) ? . Arguments . FirstOrDefault ( ) ? . Parameter ? . Type ? . Equals ( parameterTypeSymbol , SymbolEqualityComparer . Default ) ?? false ;
58+
59+ return ( operation as IObjectCreationOperation ) ? . Arguments . FirstOrDefault ( )
60+ ? . Parameter ? . Type ? . Equals ( parameterTypeSymbol , SymbolEqualityComparer . Default )
61+ ?? false ;
5762 }
5863}
0 commit comments