aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLi Jin <dragon-fly@qq.com>2022-07-12 23:36:28 +0800
committerLi Jin <dragon-fly@qq.com>2022-07-12 23:36:28 +0800
commit9beb7e00e8b030fdd7c3ecbad3f7ebe8ca14fda6 (patch)
tree52e272589c1f17d0bfc5725b080a5c5efdcd83f7
parent68e167e9f0b90968ea67b7f21fdc50a48d129173 (diff)
downloadyuescript-9beb7e00e8b030fdd7c3ecbad3f7ebe8ca14fda6.tar.gz
yuescript-9beb7e00e8b030fdd7c3ecbad3f7ebe8ca14fda6.tar.bz2
yuescript-9beb7e00e8b030fdd7c3ecbad3f7ebe8ca14fda6.zip
fix build.
-rwxr-xr-xsrc/yuescript/yue_compiler.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/yuescript/yue_compiler.cpp b/src/yuescript/yue_compiler.cpp
index 468dc23..83bad2e 100755
--- a/src/yuescript/yue_compiler.cpp
+++ b/src/yuescript/yue_compiler.cpp
@@ -56,7 +56,7 @@ using namespace parserlib;
56 56
57typedef std::list<std::string> str_list; 57typedef std::list<std::string> str_list;
58 58
59const std::string_view version = "0.13.0"sv; 59const std::string_view version = "0.13.1"sv;
60const std::string_view extension = "yue"sv; 60const std::string_view extension = "yue"sv;
61 61
62class YueCompilerImpl { 62class YueCompilerImpl {
@@ -7121,8 +7121,8 @@ private:
7121 for (auto branch_ : branches) { 7121 for (auto branch_ : branches) {
7122 auto branch = static_cast<SwitchCase_t*>(branch_); 7122 auto branch = static_cast<SwitchCase_t*>(branch_);
7123 if (auto value = singleValueFrom(branch->valueList); 7123 if (auto value = singleValueFrom(branch->valueList);
7124 value->item.is<simple_table_t>() || 7124 value && (value->item.is<simple_table_t>() ||
7125 value->getByPath<SimpleValue_t, TableLit_t>()) { 7125 value->getByPath<SimpleValue_t, TableLit_t>())) {
7126 if (!firstBranch) { 7126 if (!firstBranch) {
7127 temp.push_back(indent() + "else"s + nll(branch)); 7127 temp.push_back(indent() + "else"s + nll(branch));
7128 pushScope(); 7128 pushScope();