next
This commit is contained in:
parent
1b1a420156
commit
99ab0bddd4
1 changed files with 44 additions and 49 deletions
|
@ -242,42 +242,6 @@ function parse(string) {
|
|||
|
||||
}
|
||||
|
||||
function parse_next(string) {
|
||||
|
||||
# constant
|
||||
if (current_match == "constant") {
|
||||
doc_reset()
|
||||
constant = ""
|
||||
|
||||
# variable
|
||||
} else if (current_match == "variable") {
|
||||
doc_reset()
|
||||
variable = ""
|
||||
|
||||
# alias
|
||||
} else if (current_match == "alias") {
|
||||
alias = ""
|
||||
|
||||
# command
|
||||
} else if (current_match == "command") {
|
||||
command = ""
|
||||
|
||||
# task
|
||||
} else if (current_match == "task") {
|
||||
task = ""
|
||||
|
||||
# close
|
||||
} else if (current_match == "close") {
|
||||
doc_reset()
|
||||
current_function = ""
|
||||
|
||||
# match
|
||||
}
|
||||
|
||||
# next
|
||||
line++
|
||||
}
|
||||
|
||||
# ╭──────┬──────╮
|
||||
# │ code │ main │
|
||||
# ╰──────┴──────╯
|
||||
|
@ -288,7 +252,7 @@ function parse_next(string) {
|
|||
# │ code │ main │ parse │
|
||||
# ╰──────┴──────┴───────╯
|
||||
|
||||
parse($0)
|
||||
# TODO parse($0)
|
||||
|
||||
# ╭──────┬──────┬──────╮
|
||||
# │ code │ main │ exit │
|
||||
|
@ -427,7 +391,38 @@ if (action == "doc") {
|
|||
# │ code │ main │ next │
|
||||
# ╰──────┴──────┴──────╯
|
||||
|
||||
parse_next($0)
|
||||
# constant
|
||||
if (current_match == "constant") {
|
||||
doc_reset()
|
||||
constant = ""
|
||||
|
||||
# variable
|
||||
} else if (current_match == "variable") {
|
||||
doc_reset()
|
||||
variable = ""
|
||||
|
||||
# alias
|
||||
} else if (current_match == "alias") {
|
||||
alias = ""
|
||||
|
||||
# command
|
||||
} else if (current_match == "command") {
|
||||
command = ""
|
||||
|
||||
# task
|
||||
} else if (current_match == "task") {
|
||||
task = ""
|
||||
|
||||
# close
|
||||
} else if (current_match == "close") {
|
||||
doc_reset()
|
||||
current_function = ""
|
||||
|
||||
# match
|
||||
}
|
||||
|
||||
# next
|
||||
line++
|
||||
|
||||
# main
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue