summaryrefslogtreecommitdiffstats
path: root/CompleteStatement.xs
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2013-10-22 02:08:07 -0400
committerJesse Luehrs <doy@tozt.net>2013-10-22 02:08:07 -0400
commit7e101392f826c6fb8a6980028ff94eab61ba8f55 (patch)
treed72488d4ead82c8b57f3d1872dcddf8947cc2a6d /CompleteStatement.xs
parent46f89f90a5eb4b8f298d5511d4f92569bc79c87e (diff)
downloaddevel-completestatement-7e101392f826c6fb8a6980028ff94eab61ba8f55.tar.gz
devel-completestatement-7e101392f826c6fb8a6980028ff94eab61ba8f55.zip
more fiddling
Diffstat (limited to 'CompleteStatement.xs')
-rw-r--r--CompleteStatement.xs8
1 files changed, 6 insertions, 2 deletions
diff --git a/CompleteStatement.xs b/CompleteStatement.xs
index aee013a..503e5f2 100644
--- a/CompleteStatement.xs
+++ b/CompleteStatement.xs
@@ -54,7 +54,7 @@ _parse()
LEAVE;
-int
+SV *
complete_statement(str)
SV *str
PREINIT:
@@ -116,7 +116,11 @@ complete_statement(str)
call_parse();
- RETVAL = (depth == 0);
+ RETVAL = (PL_parser->bufptr != PL_parser->bufend)
+ ? &PL_sv_undef
+ : (depth == 0)
+ ? &PL_sv_yes
+ : &PL_sv_no;
FREETMPS;
LEAVE;