aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/yuescript/yue_compiler.cpp2
-rw-r--r--src/yuescript/yue_parser.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/yuescript/yue_compiler.cpp b/src/yuescript/yue_compiler.cpp
index bcc44d2..eb31ab5 100644
--- a/src/yuescript/yue_compiler.cpp
+++ b/src/yuescript/yue_compiler.cpp
@@ -78,7 +78,7 @@ static std::unordered_set<std::string> Metamethods = {
78 "close"s // Lua 5.4 78 "close"s // Lua 5.4
79}; 79};
80 80
81const std::string_view version = "0.32.8"sv; 81const std::string_view version = "0.32.9"sv;
82const std::string_view extension = "yue"sv; 82const std::string_view extension = "yue"sv;
83 83
84class CompileError : public std::logic_error { 84class CompileError : public std::logic_error {
diff --git a/src/yuescript/yue_parser.cpp b/src/yuescript/yue_parser.cpp
index 194d04d..3d8e315 100644
--- a/src/yuescript/yue_parser.cpp
+++ b/src/yuescript/yue_parser.cpp
@@ -1149,7 +1149,7 @@ YueParser::YueParser() {
1149 check_indent >> comment_line >> and_(stop) | 1149 check_indent >> comment_line >> and_(stop) |
1150 advance >> ensure(comment_line, pop_indent) >> and_(stop); 1150 advance >> ensure(comment_line, pop_indent) >> and_(stop);
1151 1151
1152 EmptyLine = plain_space >> and_(stop); 1152 EmptyLine = +(*set(" \t") >> line_break);
1153 1153
1154 indentation_error = pl::user(not_(pipe_operator | eof()), [](const item_t& item) { 1154 indentation_error = pl::user(not_(pipe_operator | eof()), [](const item_t& item) {
1155 RaiseError("unexpected indent"sv, item); 1155 RaiseError("unexpected indent"sv, item);
@@ -1161,7 +1161,7 @@ YueParser::YueParser() {
1161 return st->lax; 1161 return st->lax;
1162 }); 1162 });
1163 1163
1164 line = *(EmptyLine >> line_break) >> ( 1164 line = -EmptyLine >> (
1165 check_indent_match >> space >> Statement >> *(';' >> space >> (Statement | not_(';'))) | 1165 check_indent_match >> space >> Statement >> *(';' >> space >> (Statement | not_(';'))) |
1166 YueComment | 1166 YueComment |
1167 advance_match >> ensure(space >> (indentation_error | Statement), pop_indent) 1167 advance_match >> ensure(space >> (indentation_error | Statement), pop_indent)