整理打印
This commit is contained in:
@@ -124,6 +124,14 @@ func parseFunctions(lines []string, exportedFunctions map[string]bool) []ErlangF
|
||||
inFunction = false
|
||||
currentFunction = ErlangFunction{}
|
||||
}
|
||||
|
||||
// 函数结束条件:行以 ; 结束,且括号和花括号匹配
|
||||
if strings.HasSuffix(trimmedLine, ";") && braceCount == 0 && parenCount == 0 {
|
||||
currentFunction.EndLine = i + 1
|
||||
functions = append(functions, currentFunction.ParseComments())
|
||||
inFunction = false
|
||||
currentFunction = ErlangFunction{}
|
||||
}
|
||||
} else {
|
||||
// 不在函数中时,遇到非注释行就清空注释缓存
|
||||
if trimmedLine != "" && !strings.HasPrefix(trimmedLine, "%") {
|
||||
|
||||
Reference in New Issue
Block a user