From 55a4f49beeb3eefd2534dd2ab0c5df74ff76a77c Mon Sep 17 00:00:00 2001 From: salexdv Date: Wed, 26 May 2021 12:12:52 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D1=80=D0=B0=D0=B1=D0=BE=D1=82?= =?UTF-8?q?=D0=BA=D0=B0=20=D0=BF=D0=BE=D0=B4=D1=81=D0=B2=D0=B5=D1=82=D0=BA?= =?UTF-8?q?=D0=B8=20=D1=81=D0=B8=D0=BD=D1=82=D0=B0=D0=BA=D1=81=D0=B8=D1=81?= =?UTF-8?q?=D0=B0=20=D1=8F=D0=B7=D1=8B=D0=BA=D0=B0=20=D0=B7=D0=B0=D0=BF?= =?UTF-8?q?=D1=80=D0=BE=D1=81=D0=BE=D0=B2=20fixes=20#148?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/bsl_language.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/bsl_language.js b/src/bsl_language.js index 89bc653..390bef5 100644 --- a/src/bsl_language.js +++ b/src/bsl_language.js @@ -331,10 +331,16 @@ define([], function () { keywords: query_keywords, expressions: query_expressions, operators: /[=><+\-*\/%;,]+/, + expBeforeAs: [ + 'КОНЕЦ', 'END' + ], tokenizer: { root: [ - [/([a-zA-Z\u0410-\u044F]+)(\s+)(как|as)(\s+)([a-zA-Z\u0410-\u044F]+)/, [ - {token: 'query'}, + [/([a-zA-Z\u0410-\u044F]+)(\s+)(как|as)(\s+)([a-zA-Z\u0410-\u044F0-9]+)/, [ + { cases: { + '@expBeforeAs': 'query.exp', + '@default': 'query' + }}, {token: 'query'}, {token: 'query.keyword'}, {token: 'query'},