Skip to content
Permalink
Browse files

Merge

  • Loading branch information...
droundy committed Feb 25, 2010
2 parents 83e4d0f + e293e3c commit 7c438fa57413f75a32a90a16123bd2e186db6d8f
Showing with 5 additions and 6 deletions.
  1. +5 −6 parse/parse.go
@@ -64,12 +64,11 @@ var importRegexp *regexp.Regexp = regexp.MustCompile(`"(.+)"`)
func (v *importVisitor) Visit(node interface{}) ast.Visitor {
switch t := node.(type) {
case *ast.ImportSpec:
for _, component := range node.(*ast.ImportSpec).Path {
matches := importRegexp.MatchStrings(string(component.Value))
if len(matches) < 2 {
continue
}

component := node.(*ast.ImportSpec).Path
matches := importRegexp.MatchStrings(string(component.Value))
if len(matches) < 2 {
// skipping this?
} else {
v.imports.Insert(matches[1])
}
}

0 comments on commit 7c438fa

Please sign in to comment.
You can’t perform that action at this time.