refactored DependencyVisitor (extracted SignatureVisitor)