From ce9338c540ac3397f3d15c442033a618d12c5105 Mon Sep 17 00:00:00 2001 From: Li Jin Date: Sun, 12 Jun 2022 00:20:46 +0800 Subject: remove some invalid codes. --- src/yuescript/yue_compiler.cpp | 7 ------- 1 file changed, 7 deletions(-) (limited to 'src') diff --git a/src/yuescript/yue_compiler.cpp b/src/yuescript/yue_compiler.cpp index 8535b43..3a4ef8c 100755 --- a/src/yuescript/yue_compiler.cpp +++ b/src/yuescript/yue_compiler.cpp @@ -1281,13 +1281,6 @@ private: temp.push_back(clearBuf()); } else if (ast_is(chainValue->items.back())) { chainValue->items.pop_back(); - if (chainValue->items.empty()) { - if (_withVars.empty()) { - throw std::logic_error(_info.errorMessage("short table appending must be called within a with block"sv, x)); - } else { - chainValue->items.push_back(toAst(_withVars.top(), chainValue)); - } - } auto varName = singleVariableFrom(chainValue); bool isScoped = false; if (varName.empty() || !isLocal(varName)) { -- cgit v1.2.3-55-g6feb