Skip to content

Commit

Permalink
Skip TypeAliasDeclSyntax when parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
dfed committed Dec 12, 2023
1 parent 9afc352 commit 4110914
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Sources/SafeDICore/Visitors/FileVisitor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ public final class FileVisitor: SyntaxVisitor {
.skipChildren
}

public override func visit(_ node: TypeAliasDeclSyntax) -> SyntaxVisitorContinueKind {
.skipChildren
}

public override func visit(_ node: ClassDeclSyntax) -> SyntaxVisitorContinueKind {
visitDecl(node)
}
Expand Down
4 changes: 4 additions & 0 deletions Sources/SafeDICore/Visitors/InstantiableVisitor.swift
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,10 @@ public final class InstantiableVisitor: SyntaxVisitor {
visitDecl(node)
}

public override func visit(_ node: TypeAliasDeclSyntax) -> SyntaxVisitorContinueKind {
.skipChildren
}

// MARK: Public

public private(set) var dependencies = [Dependency]()
Expand Down

0 comments on commit 4110914

Please sign in to comment.