Skip to content

Commit

Permalink
Merge pull request #241 from 1c-syntax/develop
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
nixel2007 authored Jun 12, 2023
2 parents 0285fec + eeb0f8e commit b2b5b2a
Show file tree
Hide file tree
Showing 39 changed files with 111 additions and 54 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
run: ./gradlew --no-daemon javadoc

- name: Set up Python
uses: actions/setup-python@v3
uses: actions/setup-python@v4
with:
python-version: '3.6'
architecture: 'x64'
Expand Down Expand Up @@ -123,7 +123,7 @@ jobs:
cp -R temp/site/. public/dev/en
- name: Deploy
uses: peaceiris/actions-gh-pages@v3.8.0
uses: peaceiris/actions-gh-pages@v3.9.3
with:
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
publish_branch: gh-pages
Expand Down
8 changes: 4 additions & 4 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ plugins {
jacoco
`java-library`
antlr
id("org.sonarqube") version "3.3"
id("org.sonarqube") version "4.2.1.3168"
id("org.cadixdev.licenser") version "0.6.1"
id("com.github.gradle-git-version-calculator") version "1.1.0"
id("io.freefair.javadoc-links") version "6.4.3"
id("io.freefair.javadoc-utf-8") version "6.4.3"
id("com.github.ben-manes.versions") version "0.42.0"
id("io.freefair.javadoc-links") version "6.5.1"
id("io.freefair.javadoc-utf-8") version "6.6.1"
id("com.github.ben-manes.versions") version "0.47.0"
id("me.champeau.gradle.jmh") version "0.5.3"
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
4 changes: 4 additions & 0 deletions src/main/antlr/BSLLexer.g4
Original file line number Diff line number Diff line change
Expand Up @@ -364,6 +364,10 @@ PREPROC_RPAREN: ')';
PREPROC_STRING: '"' (~["\n\r])* '"';
PREPROC_NATIVE
: N A T I V E
;
PREPROC_USE_KEYWORD
:
(RU_I RU_S RU_P RU_O RU_L RU_SOFT_SIGN RU_Z RU_O RU_V RU_A RU_T RU_SOFT_SIGN
Expand Down
17 changes: 12 additions & 5 deletions src/main/antlr/BSLParser.g4
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,22 @@ options {
}

// ROOT
file: shebang? preprocessor* moduleVars? preprocessor* (fileCodeBlockBeforeSub subs)? fileCodeBlock EOF;
file: shebang? moduleAnnotations? preprocessor* moduleVars? preprocessor* (fileCodeBlockBeforeSub subs)? fileCodeBlock EOF;

// moduleAnnotations
preproc_native : HASH PREPROC_NATIVE;
usedLib : (PREPROC_STRING | PREPROC_IDENTIFIER);
use : HASH PREPROC_USE_KEYWORD usedLib;

moduleAnnotations
:
(preproc_native use*)
| (use+ preproc_native? use*)
;

// preprocessor
shebang : HASH PREPROC_EXCLAMATION_MARK (PREPROC_ANY | PREPROC_IDENTIFIER)*;

usedLib : (PREPROC_STRING | PREPROC_IDENTIFIER);
use : PREPROC_USE_KEYWORD usedLib;

regionStart : PREPROC_REGION regionName;
regionEnd : PREPROC_END_REGION;
regionName : PREPROC_IDENTIFIER;
Expand Down Expand Up @@ -91,7 +99,6 @@ preprocessor
| preproc_elsif
| preproc_else
| preproc_endif
| use
)
;

Expand Down
4 changes: 2 additions & 2 deletions src/main/antlr/SDBLParser.g4
Original file line number Diff line number Diff line change
Expand Up @@ -225,9 +225,9 @@ builtInFunctions:
| (doCall=(YEAR | QUARTER | MONTH | DAYOFYEAR | DAY | WEEK | WEEKDAY | HOUR | MINUTE | SECOND) LPAREN date=expression RPAREN)
| (doCall=(BEGINOFPERIOD | ENDOFPERIOD) LPAREN date=expression COMMA periodType=(MINUTE | HOUR | DAY | WEEK | MONTH | QUARTER | YEAR | TENDAYS | HALFYEAR) RPAREN)
| (doCall=DATEADD LPAREN date=expression COMMA periodType=(SECOND | MINUTE | HOUR | DAY | WEEK | MONTH | QUARTER | YEAR | TENDAYS | HALFYEAR) COMMA count=expression RPAREN)
| (doCall=DATEDIFF LPAREN first=expression COMMA second=expression COMMA periodType=(SECOND | MINUTE | HOUR | DAY | MONTH | QUARTER | YEAR) RPAREN)
| (doCall=DATEDIFF LPAREN firstdate=expression COMMA seconddate=expression COMMA periodType=(SECOND | MINUTE | HOUR | DAY | MONTH | QUARTER | YEAR) RPAREN)
| (doCall=(VALUETYPE | PRESENTATION | REFPRESENTATION | GROUPEDBY) LPAREN value=expression RPAREN)
| (doCall=ISNULL LPAREN first=expression COMMA second=expression RPAREN)
| (doCall=ISNULL LPAREN first=logicalExpression COMMA second=logicalExpression RPAREN)
;

// агрегатные ф-ии
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down Expand Up @@ -593,7 +593,8 @@ void checkAsyncModeMapping() {
|| BSLLexer.PREPROC_ANY == i
|| BSLLexer.ANNOTATION_UNKNOWN == i
|| BSLLexer.PREPROC_DELETE_ANY == i
|| BSLLexer.UNKNOWN == i) {
|| BSLLexer.UNKNOWN == i
|| BSLLexer.PREPROC_NATIVE == i) {
assertThat(tokenTypes).doesNotContain(i);
} else {
assertThat(tokenTypes).contains(i);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*
* This file is a part of BSL Parser.
*
* Copyright (c) 2018-2022
* Copyright (c) 2018-2023
* Alexey Sosnoviy <[email protected]>, Nikita Fedkin <[email protected]>, Sergey Batanov <[email protected]>
*
* SPDX-License-Identifier: LGPL-3.0-or-later
Expand Down
Loading

0 comments on commit b2b5b2a

Please sign in to comment.