Skip to content

Commit 03de06f

Browse files
committed
update comment
1 parent ed304ef commit 03de06f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

misc.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ type importer interface {
1212
ImportName(path string, src string) (name string, goroot bool)
1313
}
1414

15-
// typeName 解析表达式获取类型名字以及是否是导入的
15+
// typeName Parses the expression to get the type name and whether it is imported
1616
func typeName(x ast.Expr) (name string, imported bool) {
1717
switch t := x.(type) {
18-
case *ast.Ident: // 当前包定义的
18+
case *ast.Ident: // Defined by the current package
1919
return t.Name, false
20-
case *ast.SelectorExpr: // 外部导入的
20+
case *ast.SelectorExpr: // Defined by the imported
2121
if _, ok := t.X.(*ast.Ident); ok {
2222
return t.Sel.Name, true
2323
}

0 commit comments

Comments
 (0)