File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -40,10 +40,10 @@ function parse_string_or_cmd(ps::ParseState, prefixed = false)
4040 (isempty(str) || (lcp != nothing && isempty(lcp))) && return
4141 (last && str[end ] == ' \n ' ) && return (lcp = " " )
4242 idxstart, idxend = 2 , 1
43- while idxend < sizeof(str) && (lcp == nothing || ! isempty(lcp))
43+ while nextind(str, idxend) - 1 < sizeof(str) && (lcp == nothing || ! isempty(lcp))
4444 idxend = skip_to_nl(str, idxend)
4545 idxstart = nextind(str, idxend)
46- while idxend < sizeof(str)
46+ while nextind(str, idxend) - 1 < sizeof(str)
4747 c = str[nextind(str, idxend)]
4848 if c == ' ' || c == ' \t '
4949 idxend += 1
@@ -58,7 +58,7 @@ function parse_string_or_cmd(ps::ParseState, prefixed = false)
5858 end
5959 end
6060 end
61- if idxstart != idxend + 1
61+ if idxstart != nextind(str, idxend)
6262 prefix = str[idxstart: idxend]
6363 lcp = lcp === nothing ? prefix : longest_common_prefix(lcp, prefix)
6464 end
You can’t perform that action at this time.
0 commit comments