diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2024-07-05 15:13:46 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2024-07-05 15:13:46 -0300 |
commit | 93fd6892f85ecd8a4e82d2339016a9f71a42d0e8 (patch) | |
tree | 622b835f00c3d0e2bd63d5e092686c6d6312126b /testes | |
parent | 193bf7919ea97a2d1a98734e1a215ee6d3fc021b (diff) | |
download | lua-93fd6892f85ecd8a4e82d2339016a9f71a42d0e8.tar.gz lua-93fd6892f85ecd8a4e82d2339016a9f71a42d0e8.tar.bz2 lua-93fd6892f85ecd8a4e82d2339016a9f71a42d0e8.zip |
Fixed bug in 'multiline'
'incomplete' was popping error message that should be used in case
there is no more lines to complete the input, that is, 'pushline'
returns NULL, due to end of file.
Diffstat (limited to 'testes')
-rw-r--r-- | testes/main.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/testes/main.lua b/testes/main.lua index 9a86fb5a..17fbcb61 100644 --- a/testes/main.lua +++ b/testes/main.lua | |||
@@ -349,6 +349,11 @@ prepfile("a = [[b\nc\nd\ne]]\n=a") | |||
349 | RUN([[lua -e"_PROMPT='' _PROMPT2=''" -i < %s > %s]], prog, out) | 349 | RUN([[lua -e"_PROMPT='' _PROMPT2=''" -i < %s > %s]], prog, out) |
350 | checkprogout("b\nc\nd\ne\n\n") | 350 | checkprogout("b\nc\nd\ne\n\n") |
351 | 351 | ||
352 | -- input interrupted in continuation line | ||
353 | prepfile("a.\n") | ||
354 | RUN([[lua -i < %s > /dev/null 2> %s]], prog, out) | ||
355 | checkprogout("near <eof>\n") | ||
356 | |||
352 | local prompt = "alo" | 357 | local prompt = "alo" |
353 | prepfile[[ -- | 358 | prepfile[[ -- |
354 | a = 2 | 359 | a = 2 |