Skip to content

Commit 807a49a

Browse files
committed
Remove dead code
1 parent 9c3b492 commit 807a49a

1 file changed

Lines changed: 0 additions & 12 deletions

File tree

StyleCop.Analyzers/StyleCop.Analyzers/GeneratedCodeAnalysisExtensions.cs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -114,12 +114,6 @@ private static bool IsGeneratedDocumentNoCache(SyntaxTree tree, CancellationToke
114114
private static bool HasAutoGeneratedComment(SyntaxTree tree, CancellationToken cancellationToken)
115115
{
116116
var root = tree.GetRoot(cancellationToken);
117-
118-
if (root == null)
119-
{
120-
return false;
121-
}
122-
123117
var firstToken = root.GetFirstToken();
124118
SyntaxTriviaList trivia;
125119
if (firstToken == default(SyntaxToken))
@@ -178,12 +172,6 @@ private static bool IsGeneratedFileName(string filePath)
178172
private static bool IsEmpty(SyntaxTree tree, CancellationToken cancellationToken)
179173
{
180174
var root = tree.GetRoot(cancellationToken);
181-
182-
if (root == null)
183-
{
184-
return false;
185-
}
186-
187175
var firstToken = root.GetFirstToken(includeZeroWidth: true);
188176

189177
return firstToken.IsKind(SyntaxKind.EndOfFileToken)

0 commit comments

Comments
 (0)