From cfcd5bfaf5c062b495694ab355ed263fec5e48e8 Mon Sep 17 00:00:00 2001 From: Mark Sujew Date: Mon, 18 Nov 2024 12:59:32 +0100 Subject: [PATCH 1/2] Prototype implementation of PL/I Co-authored-by: Benjamin Wilson Co-authored-by: Markus Rudolph Signed-off-by: Mark Sujew --- .eslintrc.json | 13 + .github/workflows/ci.yml | 41 + .gitignore | 11 + .npmrc | 3 + .vscode/extensions.json | 6 + .vscode/launch.json | 88 + code_samples/CHART.pli | 2 +- code_samples/MACROS.pli | 2 +- code_samples/PLI0002.pli | 2 +- code_samples/messages/IBM1295IE.pli | 3 + code_samples/messages/IBM1324IE.pli | 2 + code_samples/messages/IBM1388IE.pli | 3 + package.json | 31 + packages/language/README.md | 1 + packages/language/langium-config.json | 10 + packages/language/package.json | 48 + .../pli-documentation-provider.ts | 63 + packages/language/src/index.ts | 17 + .../src/lsp/pli-completion-provider.ts | 37 + .../src/lsp/pli-node-kind-provider.ts | 59 + .../src/lsp/pli-semantic-highlighting.ts | 91 + packages/language/src/parser/pli-lexer.ts | 58 + .../language/src/parser/pli-token-builder.ts | 41 + packages/language/src/pli-module.ts | 121 + packages/language/src/pli.langium | 666 ++ .../src/references/pli-name-provider.ts | 36 + .../language/src/references/pli-references.ts | 23 + .../src/references/pli-scope-computation.ts | 30 + .../src/references/pli-scope-provider.ts | 86 + .../IBM1295IE-sole-bound-specified.ts | 32 + ...rs-more-than-once-within-exports-clause.ts | 19 + ...ny-parameter-has-NONCONNECTED-attribute.ts | 25 + ...ctions-descriptor-list-has-been-scanned.ts | 37 + .../src/validation/pli-document-validator.ts | 37 + .../language/src/validation/pli-validator.ts | 40 + packages/language/src/validation/utils.ts | 7 + .../src/workspace/pli-builtin-functions.ts | 414 ++ .../src/workspace/pli-index-manager.ts | 18 + .../src/workspace/pli-workspace-manager.ts | 29 + .../language/test/extracted-doc-cases.test.ts | 5614 +++++++++++++++++ packages/language/test/linking.test.ts | 71 + packages/language/test/parsing.test.ts | 615 ++ packages/language/test/validating.test.ts | 82 + .../test/validation-messages/errors.test.ts | 71 + packages/language/tsconfig.json | 12 + packages/language/tsconfig.src.json | 10 + packages/language/tsconfig.test.json | 14 + packages/vscode-extension/.vscodeignore | 3 + packages/vscode-extension/LICENSE | 277 + packages/vscode-extension/README.md | 1 + packages/vscode-extension/esbuild.mjs | 89 + .../language-configuration.json | 28 + packages/vscode-extension/package.json | 59 + .../src/extension/builtin-files.ts | 71 + .../src/extension/main-browser.ts | 53 + .../vscode-extension/src/extension/main.ts | 64 + .../src/language/main-browser.ts | 27 + .../vscode-extension/src/language/main.ts | 24 + .../vscode-extension/syntaxes/pli.manual.json | 79 + packages/vscode-extension/tsconfig.json | 16 + pnpm-lock.yaml | 3931 ++++++++++++ pnpm-workspace.yaml | 2 + scripts/merge-tmlanguage.mjs | 83 + tsconfig.build.json | 14 + tsconfig.json | 27 + vitest.config.ts | 25 + 66 files changed, 13611 insertions(+), 3 deletions(-) create mode 100644 .eslintrc.json create mode 100644 .github/workflows/ci.yml create mode 100644 .gitignore create mode 100644 .npmrc create mode 100644 .vscode/extensions.json create mode 100644 .vscode/launch.json create mode 100644 code_samples/messages/IBM1295IE.pli create mode 100644 code_samples/messages/IBM1324IE.pli create mode 100644 code_samples/messages/IBM1388IE.pli create mode 100644 package.json create mode 100644 packages/language/README.md create mode 100644 packages/language/langium-config.json create mode 100644 packages/language/package.json create mode 100644 packages/language/src/documentation.ts/pli-documentation-provider.ts create mode 100644 packages/language/src/index.ts create mode 100644 packages/language/src/lsp/pli-completion-provider.ts create mode 100644 packages/language/src/lsp/pli-node-kind-provider.ts create mode 100644 packages/language/src/lsp/pli-semantic-highlighting.ts create mode 100644 packages/language/src/parser/pli-lexer.ts create mode 100644 packages/language/src/parser/pli-token-builder.ts create mode 100644 packages/language/src/pli-module.ts create mode 100644 packages/language/src/pli.langium create mode 100644 packages/language/src/references/pli-name-provider.ts create mode 100644 packages/language/src/references/pli-references.ts create mode 100644 packages/language/src/references/pli-scope-computation.ts create mode 100644 packages/language/src/references/pli-scope-provider.ts create mode 100644 packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts create mode 100644 packages/language/src/validation/messages/IBM1324IE-name-occurs-more-than-once-within-exports-clause.ts create mode 100644 packages/language/src/validation/messages/IBM1388IE-NODESCRIPTOR-attribute-is-invalid-when-any-parameter-has-NONCONNECTED-attribute.ts create mode 100644 packages/language/src/validation/messages/IBM1747IS-Function-cannot-be-used-before-the-functions-descriptor-list-has-been-scanned.ts create mode 100644 packages/language/src/validation/pli-document-validator.ts create mode 100644 packages/language/src/validation/pli-validator.ts create mode 100644 packages/language/src/validation/utils.ts create mode 100644 packages/language/src/workspace/pli-builtin-functions.ts create mode 100644 packages/language/src/workspace/pli-index-manager.ts create mode 100644 packages/language/src/workspace/pli-workspace-manager.ts create mode 100644 packages/language/test/extracted-doc-cases.test.ts create mode 100644 packages/language/test/linking.test.ts create mode 100644 packages/language/test/parsing.test.ts create mode 100644 packages/language/test/validating.test.ts create mode 100644 packages/language/test/validation-messages/errors.test.ts create mode 100644 packages/language/tsconfig.json create mode 100644 packages/language/tsconfig.src.json create mode 100644 packages/language/tsconfig.test.json create mode 100644 packages/vscode-extension/.vscodeignore create mode 100644 packages/vscode-extension/LICENSE create mode 100644 packages/vscode-extension/README.md create mode 100644 packages/vscode-extension/esbuild.mjs create mode 100644 packages/vscode-extension/language-configuration.json create mode 100644 packages/vscode-extension/package.json create mode 100644 packages/vscode-extension/src/extension/builtin-files.ts create mode 100644 packages/vscode-extension/src/extension/main-browser.ts create mode 100644 packages/vscode-extension/src/extension/main.ts create mode 100644 packages/vscode-extension/src/language/main-browser.ts create mode 100644 packages/vscode-extension/src/language/main.ts create mode 100644 packages/vscode-extension/syntaxes/pli.manual.json create mode 100644 packages/vscode-extension/tsconfig.json create mode 100644 pnpm-lock.yaml create mode 100644 pnpm-workspace.yaml create mode 100644 scripts/merge-tmlanguage.mjs create mode 100644 tsconfig.build.json create mode 100644 tsconfig.json create mode 100644 vitest.config.ts diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 0000000..8252235 --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,13 @@ +{ + "root": true, + "parser": "@typescript-eslint/parser", + "parserOptions": { + "ecmaVersion": 6, + "sourceType": "module" + }, + "plugins": [ + "@typescript-eslint" + ], + "rules": { + } +} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..271de7a --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,41 @@ +name: Build + +on: + push: + branches: + - main + pull_request: + branches: + - main + +jobs: + build: + name: CI (${{ matrix.os }}) + strategy: + fail-fast: false + matrix: + os: [windows-latest, ubuntu-latest] + runs-on: ${{ matrix.os }} + timeout-minutes: 20 + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Install pnpm + uses: pnpm/action-setup@v4 + with: + version: 9 + - name: Use Node.js + uses: actions/setup-node@v3 + with: + node-version: '18' + cache: 'pnpm' + - name: Build monorepo + shell: bash + run: | + pnpm install + pnpm build + - name: Test monorepo + if: success() || failure() + shell: bash + run: | + pnpm test diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..091a1bf --- /dev/null +++ b/.gitignore @@ -0,0 +1,11 @@ +.vscode/* +!.vscode/extensions.json +!.vscode/launch.json +!.vscode/tasks.json +node_modules/ +dist/ +out/ +**/src/generated +**/syntaxes/pli.merged.json +*.tsbuildinfo +*.vsix \ No newline at end of file diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..b1d0393 --- /dev/null +++ b/.npmrc @@ -0,0 +1,3 @@ +auto-install-peers = true +lockfile = true +link-workspace-packages = true \ No newline at end of file diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000..3e50c0f --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,6 @@ +{ + "recommendations": [ + "langium.langium-vscode", + "vitest.explorer" + ] +} diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..fb34084 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,88 @@ +// A launch configuration that launches the extension inside a new window +// Use IntelliSense to learn about possible attributes. +// Hover to view descriptions of existing attributes. +// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Run Extension", + "type": "extensionHost", + "request": "launch", + "args": [ + "--extensionDevelopmentPath=${workspaceFolder}/packages/vscode-extension", + "${workspaceFolder}/code_samples" + ], + "sourceMaps": true, + "outFiles": [ + "${workspaceFolder}/packages/language/out/**/*.js", + "${workspaceFolder}/packages/vscode-extension/out/**/*.js" + ] + }, + { + "name": "Run Web Extension", + "type": "extensionHost", + "debugWebWorkerHost": true, + "request": "launch", + "args": [ + "--extensionDevelopmentPath=${workspaceFolder}/packages/vscode-extension", + "--extensionDevelopmentKind=web", + "${workspaceFolder}/code_samples" + ], + "sourceMaps": true, + "outFiles": [ + "${workspaceFolder}/packages/language/out/**/*.js", + "${workspaceFolder}/packages/vscode-extension/out/**/*.js" + ] + }, + { + "name": "Attach to Language Server", + "type": "node", + "port": 6009, + "request": "attach", + "skipFiles": [ + "/**" + ], + "sourceMaps": true, + "outFiles": [ + "${workspaceFolder}/packages/language/out/**/*.js", + "${workspaceFolder}/packages/vscode-extension/out/**/*.js", + "${workspaceFolder}/node_modules/langium" + ] + }, + { + "name": "Vitest: Run All", + "type": "node", + "request": "launch", + "skipFiles": [ + "/**", + ], + "cwd": "${workspaceFolder}", + "runtimeExecutable": "pnpm", + "args": [ + "vitest", + "run", + "--no-watch" + ], + "smartStep": true, + "console": "integratedTerminal" + }, + { + "name": "Vitest: Run Selected File", + "type": "node", + "request": "launch", + "autoAttachChildProcesses": true, + "skipFiles": [ + "/**" + ], + "runtimeExecutable": "pnpm", + "args": [ + "vitest", + "run", + "${relativeFile}" + ], + "smartStep": true, + "console": "integratedTerminal" + } + ] +} diff --git a/code_samples/CHART.pli b/code_samples/CHART.pli index 5d76cec..7964452 100644 --- a/code_samples/CHART.pli +++ b/code_samples/CHART.pli @@ -1,4 +1,4 @@ -*PROCESS X(S),A(S),LINECOUNT(60); + /*PROCESS X(S),A(S),LINECOUNT(60); */ /* %M% %I% %D% %T% PUNCH ' IDENTIFY **%M%1(''%M%/%I% %D% %T%'')' PUNCH ' ENTRY PLISTART ' diff --git a/code_samples/MACROS.pli b/code_samples/MACROS.pli index 68ba696..5830d92 100644 --- a/code_samples/MACROS.pli +++ b/code_samples/MACROS.pli @@ -1,4 +1,4 @@ -*PROCESS MI(':'),NEST,X,AG,A,MAR(2,72,1),GN,NUM,STG; + /*PROCESS MI(':'),NEST,X,AG,A,MAR(2,72,1),GN,NUM,STG; */ /*** (CHECK): ***/ diff --git a/code_samples/PLI0002.pli b/code_samples/PLI0002.pli index 23a0b65..e6dff17 100644 --- a/code_samples/PLI0002.pli +++ b/code_samples/PLI0002.pli @@ -37,7 +37,7 @@ /* DECLARE HOST-VARIABLE */ DCL TIMESTAMP CHAR(26); - DCL BUF1_CLOB SQL TYPE IS CLOB_FILE; + DCL BUF1_CLOB; // SQL TYPE IS CLOB_FILE; EXEC SQL DECLARE :BUF1_CLOB VARIABLE CCSID EBCDIC; DCL I FIXED BIN(31); diff --git a/code_samples/messages/IBM1295IE.pli b/code_samples/messages/IBM1295IE.pli new file mode 100644 index 0000000..801ae2a --- /dev/null +++ b/code_samples/messages/IBM1295IE.pli @@ -0,0 +1,3 @@ + TEST: PROCEDURE OPTIONS(MAIN) REORDER; + dcl x(-2) fixed bin; //error: IBM1295IE Sole bound specified is less than 1. An upper bound of 1 is assumed. + END TEST; \ No newline at end of file diff --git a/code_samples/messages/IBM1324IE.pli b/code_samples/messages/IBM1324IE.pli new file mode 100644 index 0000000..54591bc --- /dev/null +++ b/code_samples/messages/IBM1324IE.pli @@ -0,0 +1,2 @@ +0PACK: PACKAGE EXPORTS(TEST, TEST, TEST); //error: TEST has 3 occurences, needed 1 +0END; \ No newline at end of file diff --git a/code_samples/messages/IBM1388IE.pli b/code_samples/messages/IBM1388IE.pli new file mode 100644 index 0000000..7d07555 --- /dev/null +++ b/code_samples/messages/IBM1388IE.pli @@ -0,0 +1,3 @@ +0a: proc( x ) options(nodescriptor); //error: The NODESCRIPTOR attribute is invalid when any parameters have the NONCONNECTED attribute. + dcl x(20) fixed bin nonconnected; +0end a; \ No newline at end of file diff --git a/package.json b/package.json new file mode 100644 index 0000000..926745b --- /dev/null +++ b/package.json @@ -0,0 +1,31 @@ +{ + "name": "pl-one-workspace", + "description": "Base workspace package", + "version": "0.0.1", + "type": "module", + "private": true, + "scripts": { + "watch": "tsc -b tsconfig.build.json --watch", + "build": "pnpm langium:generate && tsc -b tsconfig.build.json && pnpm --dir packages/vscode-extension build && node ./scripts/merge-tmlanguage.mjs", + "build:clean": "pnpm clean && pnpm build", + "lint": "eslint src --ext ts", + "langium:generate": "pnpm --dir packages/language langium:generate", + "langium:watch": "pnpm --dir packages/language langium:watch", + "test": "vitest" + }, + "devDependencies": { + "@types/node": "^18.0.0", + "@typescript-eslint/parser": "~7.13.0", + "@typescript-eslint/eslint-plugin": "~7.13.0", + "eslint": "~8.57.0", + "deepmerge": "^1.5.0", + "langium": "~3.2.0", + "shx": "~0.3.4", + "typescript": "~5.4.5", + "vitest": "^1.6.0" + }, + "volta": { + "node": "18.20.3", + "npm": "10.7.0" + } +} diff --git a/packages/language/README.md b/packages/language/README.md new file mode 100644 index 0000000..257e830 --- /dev/null +++ b/packages/language/README.md @@ -0,0 +1 @@ +# PL1 Language Package \ No newline at end of file diff --git a/packages/language/langium-config.json b/packages/language/langium-config.json new file mode 100644 index 0000000..3bfc983 --- /dev/null +++ b/packages/language/langium-config.json @@ -0,0 +1,10 @@ +{ + "projectName": "Pl1", + "languages": [{ + "id": "pli", + "grammar": "src/pli.langium", + "fileExtensions": [".pli"], + "caseInsensitive": true + }], + "out": "src/generated" +} diff --git a/packages/language/package.json b/packages/language/package.json new file mode 100644 index 0000000..ea4bcfc --- /dev/null +++ b/packages/language/package.json @@ -0,0 +1,48 @@ +{ + "name": "pl-one-language", + "description": "The language specific package", + "version": "0.0.1", + "type": "module", + "engines": { + "node": ">=18.0.0" + }, + "files": [ + "out", + "src" + ], + "main": "./out/index.js", + "module": "./out/index.js", + "exports": { + ".": { + "types": "./out/index.d.ts", + "default": "./out/index.js" + } + }, + "typesVersions": { + "*": { + ".": [ + "out/index" + ] + } + }, + "scripts": { + "clean": "shx rm -fr *.tsbuildinfo out", + "build": "echo 'No build step'", + "build:clean": "npm run clean && npm run build", + "langium:generate": "langium generate", + "langium:watch": "langium generate --watch" + }, + "dependencies": { + "chevrotain": "^11.0.3", + "langium": "~3.2.0", + "vscode-languageserver": "~9.0.1", + "vscode-languageserver-types": "^3.17.5" + }, + "devDependencies": { + "langium-cli": "~3.2.0" + }, + "volta": { + "node": "18.20.3", + "npm": "10.7.0" + } +} diff --git a/packages/language/src/documentation.ts/pli-documentation-provider.ts b/packages/language/src/documentation.ts/pli-documentation-provider.ts new file mode 100644 index 0000000..cc1c03e --- /dev/null +++ b/packages/language/src/documentation.ts/pli-documentation-provider.ts @@ -0,0 +1,63 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode, JSDocDocumentationProvider } from 'langium'; +import { isDeclaredVariable, isDoType3Variable, isLabelPrefix, isProcedureStatement, ProcedureStatement } from '../generated/ast'; + +export class PliDocumentationProvider extends JSDocDocumentationProvider { + + override getDocumentation(node: AstNode): string | undefined { + if (isDeclaredVariable(node)) { + const declaredItem = node.$container; + let text = '```\n' + `DECLARE ${node.name} `; + for (const attribute of declaredItem.attributes) { + text += `${attribute.$cstNode?.text} `; + } + text += '\n```'; + return text; + } else if (isLabelPrefix(node) && isProcedureStatement(node.$container)) { + return this.getProcedureHoverContent(node.$container); + } else if (isProcedureStatement(node)) { + return this.getProcedureHoverContent(node); + } else if (isDoType3Variable(node)) { + return '```\nDECLARE' + node.name + '\n```'; + } + return ''; + } + + private getProcedureHoverContent(node: ProcedureStatement): string | undefined { + let text = '```\n'; + for (const label of node.labels) { + text += `${label.name} `; + } + text += 'PROCEDURE '; + if (node.parameters.length > 0) { + text += '(' + node.parameters.map(e => e.id).join(', ') + ') '; + } + if (node.recursive.length > 0) { + text += 'RECURSIVE '; + } + if (node.order.includes('ORDER')) { + text += 'ORDER '; + } else if (node.order.includes('REORDER')) { + text += 'REORDER '; + } + if (node.options.length > 0) { + text += node.options.map(e => e.$cstNode?.text).join(' '); + } + if (node.returns.length > 0) { + text += node.returns.map(e => e.$cstNode?.text).join(' '); + } + text += '\n```'; + return text; + } + +} \ No newline at end of file diff --git a/packages/language/src/index.ts b/packages/language/src/index.ts new file mode 100644 index 0000000..1566638 --- /dev/null +++ b/packages/language/src/index.ts @@ -0,0 +1,17 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +export * from './pli-module.js'; +export * from './validation/pli-validator.js'; +export * from './generated/ast.js'; +export * from './generated/grammar.js'; +export * from './generated/module.js'; +export * from './workspace/pli-builtin-functions.js'; diff --git a/packages/language/src/lsp/pli-completion-provider.ts b/packages/language/src/lsp/pli-completion-provider.ts new file mode 100644 index 0000000..946758a --- /dev/null +++ b/packages/language/src/lsp/pli-completion-provider.ts @@ -0,0 +1,37 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNodeDescription } from "langium"; +import { CompletionValueItem, DefaultCompletionProvider } from "langium/lsp"; + +export class PliCompletionProvider extends DefaultCompletionProvider { + + protected override createReferenceCompletionItem(nodeDescription: AstNodeDescription): CompletionValueItem { + let detail: string | undefined = undefined; + if (nodeDescription.type === 'ProcedureStatement') { + detail = 'PROCEDURE'; + } else if (nodeDescription.type === 'DeclaredVariable' || nodeDescription.type === 'DoType3Variable') { + detail = 'DECLARE'; + } else if (nodeDescription.type === 'LabelPrefix') { + detail = 'LABEL'; + } + const kind = this.nodeKindProvider.getCompletionItemKind(nodeDescription); + const documentation = this.getReferenceDocumentation(nodeDescription); + return { + nodeDescription, + kind, + documentation, + detail, + sortText: '0' + }; + } + +} \ No newline at end of file diff --git a/packages/language/src/lsp/pli-node-kind-provider.ts b/packages/language/src/lsp/pli-node-kind-provider.ts new file mode 100644 index 0000000..df420da --- /dev/null +++ b/packages/language/src/lsp/pli-node-kind-provider.ts @@ -0,0 +1,59 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode, AstNodeDescription, isAstNodeDescription } from "langium"; +import { DefaultNodeKindProvider } from "langium/lsp"; +import { CompletionItemKind, SymbolKind } from "vscode-languageserver-types"; +import { isLabelPrefix, isNamedElement, isPackage, isProcedureStatement } from "../generated/ast"; + +export class PliNodeKindProvider extends DefaultNodeKindProvider { + override getSymbolKind(node: AstNode | AstNodeDescription): SymbolKind { + const symbol = this.getNode(node); + if (!symbol) { + return SymbolKind.Null; + } + if (isProcedureStatement(symbol)) { + return SymbolKind.Function; + } else if (isNamedElement(symbol)) { + return SymbolKind.Variable; + } else if (isPackage(symbol)) { + return SymbolKind.Namespace; + } else if (isLabelPrefix(symbol)) { + return SymbolKind.Constant; + } else { + return SymbolKind.Variable; + } + } + + override getCompletionItemKind(node: AstNode | AstNodeDescription): CompletionItemKind { + const symbol = this.getNode(node); + if (!symbol) { + return CompletionItemKind.Text; + } + if (isProcedureStatement(symbol)) { + return CompletionItemKind.Function; + } else if (isNamedElement(symbol)) { + return CompletionItemKind.Variable; + } else if (isPackage(symbol)) { + return CompletionItemKind.Module; + } else if (isLabelPrefix(symbol)) { + return CompletionItemKind.Constant; + } + return CompletionItemKind.Variable; + } + + private getNode(node: AstNode | AstNodeDescription): AstNode | undefined { + if (isAstNodeDescription(node)) { + return node.node; + } + return node; + } +} \ No newline at end of file diff --git a/packages/language/src/lsp/pli-semantic-highlighting.ts b/packages/language/src/lsp/pli-semantic-highlighting.ts new file mode 100644 index 0000000..222428e --- /dev/null +++ b/packages/language/src/lsp/pli-semantic-highlighting.ts @@ -0,0 +1,91 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode } from 'langium'; +import { AbstractSemanticTokenProvider, SemanticTokenAcceptor } from 'langium/lsp'; +import { isDeclaredVariable, isDefineAliasStatement, isDoType3Variable, isEndStatement, isLabelPrefix, isLabelReference, isLiteral, isNumberLiteral, isProcedureCall, isProcedureParameter, isProcedureStatement, isReferenceItem, isStringLiteral } from '../generated/ast'; +import { SemanticTokenTypes } from 'vscode-languageserver'; + +export class PliSemanticTokenProvider extends AbstractSemanticTokenProvider { + protected override highlightElement(node: AstNode, acceptor: SemanticTokenAcceptor): void | undefined | 'prune' { + if (isReferenceItem(node)) { + const targetElement = node.ref?.ref; + acceptor({ + node, + property: 'ref', + type: isProcedureStatement(targetElement) ? SemanticTokenTypes.function : SemanticTokenTypes.variable + }); + } else if (isDeclaredVariable(node) || isDoType3Variable(node)) { + acceptor({ + node, + property: 'name', + type: SemanticTokenTypes.variable + }); + } else if (isDefineAliasStatement(node)) { + acceptor({ + node, + property: 'name', + type: SemanticTokenTypes.type + }); + } else if (isProcedureParameter(node)) { + acceptor({ + node, + property: 'id', + type: SemanticTokenTypes.parameter + }); + } else if (isEndStatement(node)) { + const container = node.$container; + acceptor({ + node, + property: 'label', + type: isProcedureStatement(container) ? SemanticTokenTypes.function : SemanticTokenTypes.variable + }) + } else if (isLabelReference(node)) { + acceptor({ + node, + property: 'label', + type: SemanticTokenTypes.variable + }) + } else if (isProcedureCall(node)) { + acceptor({ + node, + property: 'procedure', + type: SemanticTokenTypes.function + }); + } else if (isLabelPrefix(node)) { + const container = node.$container; + acceptor({ + node: node, + property: 'name', + type: isProcedureStatement(container) ? SemanticTokenTypes.function : SemanticTokenTypes.variable + }); + } else if (isNumberLiteral(node)) { + acceptor({ + node, + property: 'value', + type: SemanticTokenTypes.number + }); + } else if (isStringLiteral(node)) { + acceptor({ + node, + property: 'value', + type: SemanticTokenTypes.string + }); + } else if (isLiteral(node)) { + acceptor({ + node, + property: 'multiplier', + type: SemanticTokenTypes.number + }); + } + } + +} diff --git a/packages/language/src/parser/pli-lexer.ts b/packages/language/src/parser/pli-lexer.ts new file mode 100644 index 0000000..8e6126b --- /dev/null +++ b/packages/language/src/parser/pli-lexer.ts @@ -0,0 +1,58 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { DefaultLexer, LexerResult } from "langium"; + +const NEWLINE = '\n'.charCodeAt(0); + +export class Pl1Lexer extends DefaultLexer { + + override tokenize(text: string): LexerResult { + const lines = this.splitLines(text); + const adjustedLines = lines.map(line => this.adjustLine(line)); + const adjustedText = adjustedLines.join(''); + return super.tokenize(adjustedText); + } + + private splitLines(text: string): string[] { + const lines: string[] = []; + for (let i = 0; i < text.length; i++) { + const start = i; + while (i < text.length && text.charCodeAt(i) !== NEWLINE) { + i++; + } + lines.push(text.substring(start, i + 1)); + } + return lines; + } + + private adjustLine(line: string): string { + let eol = ''; + if (line.endsWith('\r\n')) { + eol = '\r\n'; + } else if (line.endsWith('\n')) { + eol = '\n'; + } + const prefixLength = 1; + const lineLength = line.length - eol.length; + if (lineLength < prefixLength) { + return ' '.repeat(lineLength) + eol; + } + const lineEnd = 72; + const prefix = ' '.repeat(prefixLength); + let postfix = ''; + if (lineLength > lineEnd) { + postfix = ' '.repeat(lineLength - lineEnd); + } + return prefix + line.substring(prefixLength, Math.min(lineEnd, lineLength)) + postfix + eol; + } + +} diff --git a/packages/language/src/parser/pli-token-builder.ts b/packages/language/src/parser/pli-token-builder.ts new file mode 100644 index 0000000..4e6257e --- /dev/null +++ b/packages/language/src/parser/pli-token-builder.ts @@ -0,0 +1,41 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { TokenType, TokenVocabulary } from "chevrotain"; +import { DefaultTokenBuilder, Grammar, GrammarUtils, RegExpUtils, stream, TokenBuilderOptions } from "langium"; + +export class PliTokenBuilder extends DefaultTokenBuilder { + + override buildTokens(grammar: Grammar, options?: TokenBuilderOptions): TokenVocabulary { + const reachableRules = stream(GrammarUtils.getAllReachableRules(grammar, false)); + const terminalTokens: TokenType[] = this.buildTerminalTokens(reachableRules); + const tokens: TokenType[] = this.buildKeywordTokens(reachableRules, terminalTokens, options); + const id = terminalTokens.find(e => e.name === 'ID')!; + + for (const keywordToken of tokens) { + if (/[a-zA-Z]/.test(keywordToken.name)) { + keywordToken.CATEGORIES = [id]; + } + } + + terminalTokens.forEach(terminalToken => { + const pattern = terminalToken.PATTERN; + if (typeof pattern === 'object' && pattern && 'test' in pattern && RegExpUtils.isWhitespace(pattern) || terminalToken.name === 'ExecFragment') { + tokens.unshift(terminalToken); + } else { + tokens.push(terminalToken); + } + }); + const execFragment = tokens.find(e => e.name === 'ExecFragment')!; + execFragment.START_CHARS_HINT = ['S', 'C']; + return tokens; + } +} diff --git a/packages/language/src/pli-module.ts b/packages/language/src/pli-module.ts new file mode 100644 index 0000000..168345f --- /dev/null +++ b/packages/language/src/pli-module.ts @@ -0,0 +1,121 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { type Module, inject } from 'langium'; +import { createDefaultModule, createDefaultSharedModule, PartialLangiumSharedServices, type DefaultSharedModuleContext, type LangiumServices, type LangiumSharedServices, type PartialLangiumServices } from 'langium/lsp'; +import { Pl1GeneratedModule, Pl1GeneratedSharedModule } from './generated/module.js'; +import { Pl1Validator, registerValidationChecks } from './validation/pli-validator.js'; +import { Pl1Lexer } from './parser/pli-lexer.js'; +import { PliTokenBuilder } from './parser/pli-token-builder.js'; +import { PliScopeComputation } from './references/pli-scope-computation.js'; +import { PliDocumentValidator } from './validation/pli-document-validator.js'; +import { PliSemanticTokenProvider } from './lsp/pli-semantic-highlighting.js'; +import { PliNameProvider } from './references/pli-name-provider.js'; +import { PliReferences } from './references/pli-references.js'; +import { PliScopeProvider } from './references/pli-scope-provider.js'; +import { PliNodeKindProvider } from './lsp/pli-node-kind-provider.js'; +import { PliDocumentationProvider } from './documentation.ts/pli-documentation-provider.js'; +import { PliCompletionProvider } from './lsp/pli-completion-provider.js'; +import { PliIndexManager } from './workspace/pli-index-manager.js'; +import { PliWorkspaceManager } from './workspace/pli-workspace-manager.js'; + +/** + * Declaration of custom services - add your own service classes here. + */ +export type Pl1AddedServices = { + validation: { + Pl1Validator: Pl1Validator + } +} + +/** + * Union of Langium default services and your custom services - use this as constructor parameter + * of custom service classes. + */ +export type Pl1Services = LangiumServices & Pl1AddedServices + +/** + * Dependency injection module that overrides Langium default services and contributes the + * declared custom services. The Langium defaults can be partially specified to override only + * selected services, while the custom services must be fully specified. + */ +export const PliModule: Module = { + documentation: { + DocumentationProvider: services => new PliDocumentationProvider(services) + }, + validation: { + Pl1Validator: () => new Pl1Validator(), + DocumentValidator: services => new PliDocumentValidator(services) + }, + parser: { + Lexer: services => new Pl1Lexer(services), + TokenBuilder: () => new PliTokenBuilder() + }, + references: { + ScopeComputation: services => new PliScopeComputation(services), + NameProvider: () => new PliNameProvider(), + References: services => new PliReferences(services), + ScopeProvider: services => new PliScopeProvider(services) + }, + lsp: { + SemanticTokenProvider: services => new PliSemanticTokenProvider(services), + CompletionProvider: services => new PliCompletionProvider(services) + } +}; + +export const PliSharedModule: Module = { + lsp: { + NodeKindProvider: () => new PliNodeKindProvider() + }, + workspace: { + IndexManager: services => new PliIndexManager(services), + WorkspaceManager: services => new PliWorkspaceManager(services) + } +}; + +/** + * Create the full set of services required by Langium. + * + * First inject the shared services by merging two modules: + * - Langium default shared services + * - Services generated by langium-cli + * + * Then inject the language-specific services by merging three modules: + * - Langium default language-specific services + * - Services generated by langium-cli + * - Services specified in this file + * + * @param context Optional module context with the LSP connection + * @returns An object wrapping the shared services and the language-specific services + */ +export function createPliServices(context: DefaultSharedModuleContext): { + shared: LangiumSharedServices, + pli: Pl1Services +} { + const shared = inject( + createDefaultSharedModule(context), + Pl1GeneratedSharedModule, + PliSharedModule + ); + const pli = inject( + createDefaultModule({ shared }), + Pl1GeneratedModule, + PliModule + ); + shared.ServiceRegistry.register(pli); + registerValidationChecks(pli); + if (!context.connection) { + // We don't run inside a language server + // Therefore, initialize the configuration provider instantly + shared.workspace.ConfigurationProvider.initialized({}); + } + return { shared, pli }; +} diff --git a/packages/language/src/pli.langium b/packages/language/src/pli.langium new file mode 100644 index 0000000..85771f2 --- /dev/null +++ b/packages/language/src/pli.langium @@ -0,0 +1,666 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +grammar Pl1 + +entry PliProgram: + (statements+=TopLevelStatement)*; + +TopLevelStatement: Package | PackageLevelStatements | Directives; + +Directives: SkipDirective | PopDirective | PushDirective | LineDirective | NoteDirective | PageDirective | PrintDirective | IncludeDirective | NoPrintDirective | ProcessDirective | ProcincDirective; + +// Defined on p. 90 +Package: + prefix=ConditionPrefix? + name=FeatureID ':' + 'PACKAGE' + exports=Exports? + reserves=Reserves? + options=Options? ';' + statements+=PackageLevelStatements* + end=EndStatement ';'; + +ConditionPrefix: ('(' items+=ConditionPrefixItem ')' ':')+; + +ConditionPrefixItem: conditions+=Condition (',' conditions+=Condition)*; + +Exports: + 'EXPORTS' '(' (all?='*' | (procedures+=FeatureID (',' procedures+=FeatureID)*)) ')'; + +Reserves: 'RESERVES' '(' (all?='*' | (variables+=FeatureID (',' variables+=FeatureID)*)) ')'; + +// TODO refine based on p. 126 +Options: 'OPTIONS' '(' items+=OptionsItem (','? items+=OptionsItem)* ')'; + +OptionsItem: + SimpleOptionsItem | + CMPATOptionsItem | + LinkageOptionsItem | + NoMapOptionsItem; + +LinkageOptionsItem: 'LINKAGE' '(' value=('CDECL' | 'OPTLINK' | 'STDCALL' | 'SYSTEM') ')'; + +CMPATOptionsItem: 'CMPAT' '(' value=('V1' | 'V2' | 'V3') ')'; + +NoMapOptionsItem: type=('NOMAP' | 'NOMAPIN' | 'NOMAPOUT') ('(' (parameters+=FeatureID (',' parameters+=FeatureID)*)? ')')?; + +SimpleOptionsItem: value=( + // BEGIN/PACKAGE statement + 'ORDER' | 'REORDER' | 'NOCHARGRAPHIC' | 'CHARGRAPHIC' | 'NOINLINE' | 'INLINE' | 'MAIN' | 'NOEXECOPS' | + // ENTRY declaration + 'COBOL' | 'FORTRAN' | 'BYADDR' | 'BYVALUE' | 'DESCRIPTOR' | 'NODESCRIPTOR' | + 'IRREDUCIBLE' | 'REDUCIBLE' | 'NORETURN' | 'REENTRANT' | + // PACKAGE + 'FETCHABLE' | 'RENT' | 'AMODE31' | 'AMODE64' | + // PROCEDURE statement + 'DLLINTERNAL' | 'FROMALIEN' | 'RETCODE' | 'ASSEMBLER' | /* abbr */ 'ASM' | 'WINMAIN' | + // Undocumented (?) + 'INTER' | 'RECURSIVE' + ); + +PackageLevelStatements: DeclareStatement | DefineAliasStatement | DefineOrdinalStatement | DefineStructureStatement | DefaultStatement | ProcedureStatement; + +ProcedureStatement: + (labels+=LabelPrefix)* + ('PROC' | 'PROCEDURE' | xProc?='XPROC' | xProc?='XPROCEDURE') + ('(' (parameters+=ProcedureParameter (',' parameters+=ProcedureParameter)*)? ')')? + // These can appear in any order: + ( + returns+=ReturnsOption | + options+=Options | + recursive+='RECURSIVE' | + (order+=('ORDER' | 'REORDER')) | + (('EXTERNAL' | 'EXT') ('(' environmentName+=Expression ')')?) | + scope+=ScopeAttribute + )* ';' + statements+=ProcedureLevelStatement* + ('PROC' | 'PROCEDURE')? end=EndStatement ';'; + + +ScopeAttribute returns string: ('STATIC' | 'DYNAMIC'); + +LabelPrefix: name=FeatureID ':'; + +EntryStatement: + 'ENTRY' + ('(' (parameters+=ProcedureParameter (',' parameters+=ProcedureParameter)*)? ')')? + ((('EXTERNAL' | 'EXT') ('(' environmentName+=Expression ')')?) | + variable+='VARIABLE' | + limited+='LIMITED' | + returns+=ReturnsOption | + options+=Options)* ';'; + +ProcedureLevelStatement: Statement | ProcedureStatement; + +// #region Statements + +Statement: + condition=ConditionPrefix? (labels+=LabelPrefix)* value=Unit; + +Unit: DeclareStatement | AllocateStatement | AssertStatement | AssignmentStatement | AttachStatement + | BeginStatement | CallStatement | CancelThreadStatement | CloseStatement | DefaultStatement | DefineAliasStatement | DefineOrdinalStatement | DefineStructureStatement + | DelayStatement | DeleteStatement | DetachStatement | DisplayStatement | DoStatement + | EntryStatement | ExecStatement | ExitStatement | FetchStatement | FlushStatement | FormatStatement + | FreeStatement | GetStatement | GoToStatement + | IfStatement | IncludeDirective | IterateStatement + | LeaveStatement | LineDirective | LocateStatement + | NoPrintDirective | NoteDirective | NullStatement + | OnStatement | OpenStatement + | PageDirective | PopDirective | PrintDirective + | ProcessDirective | ProcincDirective | PushDirective + | PutStatement + | QualifyStatement + | ReadStatement | ReinitStatement | ReleaseStatement | ResignalStatement + | ReturnStatement | RevertStatement | RewriteStatement + | SelectStatement | SignalStatement | SkipDirective | StopStatement + | WaitStatement | WriteStatement; + +AllocateStatement: ('ALLOCATE' | 'ALLOC') variables+=AllocatedVariable (',' variables+=AllocatedVariable)* ';'; + +AllocatedVariable: level=NUMBER? var=ReferenceItem attribute=AllocateAttribute?; + +AllocateAttribute: AllocateDimension + | AllocateType + | AllocateLocationReference + | InitialAttribute; + +AllocateLocationReference: ('IN' '(' area=LocatorCall ')' ('SET' '(' locatorVariable=LocatorCall ')')? | 'SET' '(' locatorVariable=LocatorCall ')'); + +AllocateDimension: dimensions=Dimensions; + +AllocateType: type=AllocateAttributeType dimensions=Dimensions?; + +AllocateAttributeType returns string: 'CHAR' | 'CHARACTER' | 'BIT' | 'GRAPHIC' | 'UCHAR' | 'WIDECHAR' | 'AREA'; + +AssertStatement: 'ASSERT' ( + true?='TRUE' '(' actual=Expression ')' + | false?='FALSE' '(' actual=Expression ')' + | compare?='COMPARE' '(' actual=Expression ',' expected=Expression (',' operator=STRING_TERM)? ')' + | unreachable?='UNREACHABLE' + ) + ('TEXT' displayExpression=Expression)?; + +AssignmentStatement: refs+=LocatorCall (',' refs+=LocatorCall)* operator=AssignmentOperator expression=Expression (',' 'BY' ('NAME' | 'DIMACROSS' dimacrossExpr=Expression))? ';'; + +AssignmentOperator returns string: '=' | '+=' | '-=' | '*=' | '/=' | '|=' | '&=' | '||=' | '**=' | '¬=' | '^=' | '<>'; + +AttachStatement: 'ATTACH' reference=LocatorCall ('THREAD' '(' task=LocatorCall ')') (environment?='ENVIRONMENT' '(' ('TSTACK' '(' tstack=Expression ')')? ')')? ';'; + +BeginStatement: 'BEGIN' options=Options? recursive?='RECURSIVE'? (order?='ORDER' | reorder?='REORDER')? ';' + statements+=Statement* + end=EndStatement ';'; + +EndStatement: (labels+=LabelPrefix)* 'END' label=LabelReference?; + +CallStatement: 'CALL' call=ProcedureCall ';'; + +CancelThreadStatement: 'CANCEL' 'THREAD' '(' thread=LocatorCall ')' ';'; + +CloseStatement: 'CLOSE' 'FILE' '(' (files+=MemberCall | files+='*') ')' (','? 'FILE' '(' (files+=MemberCall | files+='*') ')')* ';'; + +DefaultStatement: ('DEFAULT' | 'DFT') expressions+=DefaultExpression (',' expressions+=DefaultExpression)* ';'; + +DefaultExpression: expression=DefaultExpressionPart attributes+=DeclarationAttribute*; + +DefaultExpressionPart: 'DESCRIPTORS' expression=DefaultAttributeExpression | ('RANGE' '(' identifiers=DefaultRangeIdentifiers ')' | '(' expression=DefaultAttributeExpression ')'); + +DefaultRangeIdentifiers: (identifiers+=('*' | DefaultRangeIdentifierItem) (',' identifiers+=('*' | DefaultRangeIdentifierItem))*); + +DefaultRangeIdentifierItem: from=FeatureID (':' to=FeatureID)?; + +DefaultAttributeExpression: items+=DefaultAttributeExpressionNot ((operators+=('AND' | 'OR') items+=DefaultAttributeExpressionNot)*)?; + +DefaultAttributeExpressionNot: (not?='NOT')? value=DefaultAttribute; + +DefaultAttribute returns string: + 'ABNORMAL' | 'ALIGNED' | 'AREA' | 'ASSIGNABLE' | 'AUTOMATIC' + | 'BACKWARDS' | 'BASED' | 'BIT' | 'BUFFERED' | 'BUILTIN' | 'BYADDR' | 'BYVALUE' | 'BIN' | 'BINARY' + | 'CHARACTER' | 'CHAR' | 'COMPLEX' | 'CONDITION' | 'CONNECTED' | 'CONSTANT' | 'CONTROLLED' | 'CTL' + | 'DECIMAL' | 'DEC' | 'DIMACROSS' + | 'EVENT' | 'EXCLUSIVE' | 'EXTERNAL' | 'EXT' + | 'FILE' | 'FIXED' | 'FLOAT' | 'FORMAT' + | 'GENERIC' | 'GRAPHIC' + | 'HEX' | 'HEXADEC' + | 'IEEE' | 'INONLY' | 'INOUT' | 'INTERNAL' | 'INT' | 'IRREDUCIBLE' | 'INPUT' + | 'KEYED' + | 'LABEL' | 'LIST' + | 'MEMBER' + | 'NATIVE' | 'NONASSIGNABLE' | 'NONASGN' | 'NONCONNECTED' | 'NONNATIVE' | 'NONVARYING' | 'NORMAL' + | 'OFFSET' | 'OPTIONAL' | 'OPTIONS' | 'OUTONLY' | 'OUTPUT' + | 'PARAMETER' | 'POINTER' | 'PTR' | 'POSITION' | 'PRECISION' | 'PREC' | 'PRINT' + | 'RANGE' | 'REAL' | 'RECORD' | 'RESERVED' | 'RETURNS' + | 'SEQUENTIAL' | 'SIGNED' | 'STATIC' | 'STREAM' | 'STRUCTURE' + | 'TASK' | 'TRANSIENT' + | 'UNAL' | 'UCHAR' | 'UNALIGNED' | 'UNBUFFERED' | 'UNION' | 'UNSIGNED' | 'UPDATE' + | 'VARIABLE' | 'VARYING' | 'VAR' | 'VARYING4' | 'VARYINGZ' | 'VARZ' + | 'WIDECHAR' + + | 'BIGENDIAN' | 'LITTLEENDIAN' + +; + +DefineAliasStatement: ('DEFINE' | xDefine?='XDEFINE') 'ALIAS' name=FeatureID (attributes+=DeclarationAttribute (','? attributes+=DeclarationAttribute)*)? ';'; + +DefineOrdinalStatement: + ('DEFINE' | xDefine?='XDEFINE') 'ORDINAL' name=FQN + '(' ordinalValues=OrdinalValueList ')' + (signed?='SIGNED' | unsigned?='UNSIGNED')? + (('PRECISION' | 'PREC') '(' precision=NUMBER ')')? + (signed?='SIGNED' | unsigned?='UNSIGNED')? + ';'; + +OrdinalValueList: members+=OrdinalValue (',' members+=OrdinalValue)*; + +OrdinalValue: name=FeatureID ('VALUE' '(' value=NUMBER ')')?; + +DefineStructureStatement: ('DEFINE' | xDefine?='XDEFINE') ('STRUCTURE'|'STRUCT') level=NUMBER name=FQN (union?='UNION')? (',' substructures+=SubStructure)* ';'; + +SubStructure: level=NUMBER name=FeatureID attributes+=DeclarationAttribute*; + +DelayStatement: 'DELAY' '(' delay=Expression ')' ';'; + +DeleteStatement: 'DELETE' 'FILE' '(' (file=LocatorCall) ')' ('KEY' '(' key=Expression ')')? ';'; + +DetachStatement: 'DETACH' 'THREAD' '(' reference=LocatorCall ')' ';'; + +DisplayStatement: 'DISPLAY' '(' expression=Expression ')' + ('REPLY' '(' reply=LocatorCall ')')? + ('ROUTCDE' '(' rout+=NUMBER (',' rout+=NUMBER)* ')' ('DESC' '(' desc+=NUMBER (',' desc+=NUMBER)* ')')?)? ';' +; + +DoStatement: + 'DO' + // Note: DoType1 does nothing + (DoType2 | DoType3)? ';' + statements+=Statement* + end=EndStatement ';'; + +DoType2: DoWhile | DoUntil; + +DoWhile: 'WHILE' '(' while=Expression ')' ('UNTIL' '(' until=Expression ')')?; + +DoUntil: 'UNTIL' '(' until=Expression ')' ('WHILE' '(' while=Expression ')')?; + +DoType3: variable=DoType3Variable '=' specifications+=DoSpecification (',' specifications+=DoSpecification)*; + +DoType3Variable: name=ID; + +DoSpecification: exp1=Expression ( + 'TO' to=Expression ('BY' by=Expression)? + | 'BY' by=Expression ('TO' to=Expression)? + | 'UPTHRU' upthru=Expression + | 'DOWNTHRU' downthru=Expression + | 'REPEAT' repeat=Expression + )? + ( whileOrUntil=(DoWhile | DoUntil)?); + +ExecStatement: 'EXEC' query=ExecFragment ';'; + +ExitStatement: {infer ExitStatement} 'EXIT' ';'; + +FetchStatement: 'FETCH' entries+=FetchEntry (',' entries+=FetchEntry)* ';'; + +FetchEntry: name=FeatureID ('SET' '(' set=LocatorCall ')')? ('TITLE' '(' title=Expression ')')?; + +FlushStatement: 'FLUSH' 'FILE' '(' file=(LocatorCall | '*') ')' ';'; + +FormatStatement: 'FORMAT' '(' list=FormatList ')' ';'; + +FormatList: items+=FormatListItem (',' items+=FormatListItem)*; + +FormatListItem: level=FormatListItemLevel? (item=FormatItem | '(' list=FormatList ')'); + +FormatListItemLevel: level=NUMBER | '(' level=Expression ')'; + +FormatItem: AFormatItem | BFormatItem | CFormatItem | EFormatItem | FFormatItem | PFormatItem + | ColumnFormatItem | GFormatItem | LFormatItem | LineFormatItem | PageFormatItem + | RFormatItem | SkipFormatItem | VFormatItem | XFormatItem; + +AFormatItem: 'A' ('(' fieldWidth=Expression ')')?; + +BFormatItem: 'B' ('(' fieldWidth=Expression ')')?; + +CFormatItem: 'C' '(' item=(FFormatItem | EFormatItem | PFormatItem)')'; + +FFormatItem: 'F' '(' fieldWidth=Expression (',' fractionalDigits=Expression (',' scalingFactor=Expression)?)? ')'; +EFormatItem: 'E' '(' fieldWidth=Expression ',' fractionalDigits=Expression (',' significantDigits=Expression)? ')'; +PFormatItem: 'P' specification=STRING_TERM; + +ColumnFormatItem: ('COLUMN' | 'COL') '(' characterPosition=Expression ')'; + +GFormatItem: 'G' ('(' fieldWidth=Expression ')')?; + +LFormatItem: {infer LFormatItem} 'L'; + +LineFormatItem: 'LINE' '(' lineNumber=Expression ')'; + +PageFormatItem: {infer PageFormatItem} 'PAGE'; + +RFormatItem: 'R' '(' labelReference=FeatureID ')'; + +SkipFormatItem: 'SKIP' ('(' skip=Expression ')')?; + +VFormatItem: {infer VFormatItem} 'V'; + +XFormatItem: 'X' '(' width=Expression ')'; + +FreeStatement: 'FREE' references+=LocatorCall (',' references+=LocatorCall)* ';'; + +GetStatement: 'GET' ( + {infer GetFileStatement} ('FILE' '(' file=Expression ')')? + (dataSpecification=DataSpecificationOptions)? + (copy?='COPY' ('(' /* TODO REFERENCE */ copyReference=FeatureID ')')?)? + (skip?='SKIP' ('(' skipExpression=Expression ')'))? + | + {infer GetStringStatement} 'STRING' '(' expression=Expression ')' dataSpecification=DataSpecificationOptions + ) +; + +GoToStatement: ('GO' 'TO' | 'GOTO') label=LabelReference ';'; + +IfStatement: 'IF' expression=Expression 'THEN' unit=Statement ('ELSE' else=Statement)?; + +IncludeDirective: ('%INCLUDE' | '%XINCLUDE') items+=IncludeItem (',' items+=IncludeItem)* ';'; + +IncludeItem: file=(STRING_TERM|ID) | ddname?='ddname' '(' file=(STRING_TERM|ID) ')'; + +IterateStatement: 'ITERATE' label=LabelReference? ';'; + +LeaveStatement: 'LEAVE' label=LabelReference? ';'; + +LineDirective: '%LINE' ('(' line=NUMBER ',' file=STRING_TERM ')') ';'; + +LocateStatement: + 'LOCATE' variable=LocatorCall + 'FILE' '(' file=ReferenceItem ')' + ('SET' '(' set=LocatorCall /* TODO Pointer-Reference? */ ')')? + ('KEYFROM' '(' keyfrom=Expression ')')? + ';' +; + +NoPrintDirective: {infer NoPrintDirective} '%NOPRINT' ';'; + +NoteDirective: '%NOTE' '(' message=Expression (',' code=Expression)? ')' ';'; + +NullStatement: {infer NullStatement} ';'; + +OnStatement: 'ON' conditions+=Condition (',' conditions+=Condition)* snap?='SNAP'? (system?='SYSTEM' ';' | onUnit=Statement); + +Condition: KeywordCondition | NamedCondition | FileReferenceCondition; + +KeywordCondition: keyword=( + 'ANYCONDITION' | 'ANYCOND' | 'AREA' | 'ASSERTION' | 'ATTENTION' + | 'CONFORMANCE' | 'CONVERSION' + | 'ERROR' + | 'FINISH' + | 'FIXEDOVERFLOW' | 'FOFL' + | 'INVALIDOP' + | 'OVERFLOW' | 'OFL' + | 'SIZE' | 'STORAGE' | 'STRINGRANGE' | 'STRINGSIZE' | 'SUBSCRIPTRANGE' + | 'UNDERFLOW' | 'UFL' + | 'ZERODIVIDE' | 'ZDIV' +); + +NamedCondition: 'CONDITION' '(' name=FeatureID ')'; + +FileReferenceCondition: keyword=('ENDFILE' | 'ENDPAGE'| 'KEY'|'NAME'|'RECORD'|'TRANSMIT'|'UNDEFINEDFILE'|'UNDF') ('(' fileReference=ReferenceItem ')')?; + +OpenStatement: 'OPEN' options+=OpenOptionsGroup (',' options+=OpenOptionsGroup)* ';'; + +OpenOptionsGroup: + 'FILE' '(' file=ReferenceItem ')' + (stream?='STREAM' | record?='RECORD')? + (input?='INPUT' | output?='OUTPUT' | update?='UPDATE')? + ((sequential?=('SEQUENTIAL'|'SEQL') | direct?='DIRECT')? (unbuffered?=('UNBUFFERED'|'UNBUF') | buffered?=('BUF'|'BUFFERED'))?)? + keyed?='KEYED'? + print?='PRINT'? + ('TITLE' '(' title=Expression ')')? + ('LINESIZE' '(' lineSize=Expression ')')? + ('PAGESIZE' '(' pageSize=Expression ')')? +; + +PageDirective: {infer PageDirective} '%PAGE' ';'; + +PopDirective: {infer PopDirective} '%POP' ';'; + +PrintDirective: {infer PrintDirective} '%PRINT' ';'; + +ProcessDirective: ('*PROCESS' | '%PROCESS') (compilerOptions+=CompilerOptions (',' compilerOptions+=CompilerOptions))? ';'; + +CompilerOptions: value='TODO'; + +ProcincDirective: ('%PROCINC' | '*PROCINC') datasetName=FeatureID ';'; + +PushDirective: {infer PushDirective} '%PUSH' ';'; + +PutStatement: 'PUT' + ( + {infer PutFileStatement} items+=(PutItem | DataSpecificationOptions)* + | + {infer PutStringStatement} ('STRING' '(' stringExpression=Expression ')' dataSpecification=DataSpecificationOptions) + ) ';' +; + +PutItem: attribute=PutAttribute ('(' expression=Expression ')')?; + +PutAttribute returns string: 'PAGE' | 'LINE' | 'SKIP' | 'FILE'; + +DataSpecificationOptions: ( + ('LIST'? '(' dataList=DataSpecificationDataList ')') + | data?='DATA' ('(' dataListItems+=DataSpecificationDataListItem (',' dataListItems+=DataSpecificationDataListItem)* ')')? + | edit?='EDIT' ('(' dataLists+=DataSpecificationDataList ')' '(' formatLists+=FormatList ')')+ +); + +DataSpecificationDataList: items+=DataSpecificationDataListEntry (',' items+=DataSpecificationDataListEntry)*; + +DataSpecificationDataListEntry: DataSpecificationDataListItem | DataSpecificationDataListItem3DO; + +DataSpecificationDataListItem: value=Expression; + +DataSpecificationDataListItem3DO: '(' list=DataSpecificationDataList 'DO' do=DoType3 ')'; + +QualifyStatement: + 'QUALIFY' ';' + statements+=Statement* + end=EndStatement ';' +; + +ReadStatement: 'READ' 'FILE' '(' fileReference=LocatorCall ')' + ( + 'IGNORE' '(' ignore=Expression ')' + | ('INTO' '(' intoRef=LocatorCall ')' | 'SET' '(' set=LocatorCall ')') ('KEY' '(' key=Expression ')' | 'KEYTO' '(' keyto=LocatorCall ')')? + )? ';' +; + +ReinitStatement: 'REINIT' reference=LocatorCall ';'; + +ReleaseStatement: 'RELEASE' (star?='*' | references+=FeatureID (',' references+=FeatureID)*) ';'; + +ResignalStatement: {infer ResignalStatement} 'RESIGNAL' ';'; + +ReturnStatement: 'RETURN' ('(' expression=Expression ')')? ';'; + +RevertStatement: 'REVER' conditions+=Condition (',' conditions+=Condition)* ';'; + +RewriteStatement: 'REWRITE' 'FILE' '(' file=LocatorCall ')' ('FROM' '(' from=LocatorCall ')')? ('KEY' '(' key=Expression ')')? ';'; + +// Ensure via validation that `Otherwise` appears last +SelectStatement: + 'SELECT' ('(' on=Expression ')')? ';' + (statements+=(WhenStatement | OtherwiseStatement))* + end=EndStatement ';' +; + +WhenStatement: 'WHEN' '(' conditions+=Expression (',' conditions+=Expression)* ')' unit=Statement /* maybe? ';' */; + +OtherwiseStatement: ('OTHERWISE' | 'OTHER') unit=Statement /* maybe? ';' */; + +SignalStatement: 'SIGNAL' condition+=Condition ';'; + +SkipDirective: '%SKIP' ('(' lines=Expression ')')? ';'; + +StopStatement: {infer StopStatement} 'STOP' ';'; + +WaitStatement: 'WAIT' 'THREAD' '(' task=LocatorCall ')' ';'; + +WriteStatement: 'WRITE' 'FILE' '(' fileReference=LocatorCall ')' 'FROM' '(' from=LocatorCall ')' ('KEYFROM' '(' keyfrom=Expression ')' | 'KEYTO' '(' keyto=LocatorCall ')')? ';'; + +// #endregion + +InitialAttribute: (('INITIAL' | 'INIT') ( + direct?='(' items+=InitialAttributeItem (',' items+=InitialAttributeItem)* ')' + | call?='CALL' procedureCall=ProcedureCall + | to?='TO' '(' content=InitialToContent ')' '(' items+=InitialAttributeItem (',' items+=InitialAttributeItem)* ')' + ) + | across?='INITACROSS' '(' expressions+=InitAcrossExpression (',' expressions+=InitAcrossExpression)* ')' + ); + +InitialToContent: (varying=Varying type=CharType? | type=CharType varying=Varying?); + +Varying returns string: 'VARYING' | 'VARYING4' | 'VARYINGZ' | 'NONVARYING'; + +CharType returns string: 'CHAR' | 'UCHAR' | 'WCHAR'; + +InitAcrossExpression: '(' expressions+=Expression (',' expressions+=Expression)* ')'; + +InitialAttributeItem: InitialAttributeItemStar | InitialAttributeSpecification | InitialAttributeExpression; + +InitialAttributeItemStar: {infer InitialAttributeItemStar} '*'; +InitialAttributeExpression: expression=Expression; +InitialAttributeSpecification: '(' (star?='*' | expression=Expression) ')' item=InitialAttributeSpecificationIteration; + +InitialAttributeSpecificationIteration: InitialAttributeItemStar | InitialAttributeExpression | InitialAttributeSpecificationIterationValue; + +InitialAttributeSpecificationIterationValue: '(' items+=InitialAttributeItem (',' items+=InitialAttributeItem)* ')'; + +DeclareStatement: ('DCL' | 'DECLARE' | xDeclare?='XDECLARE' | xDeclare?='XDCL') items+=DeclaredItem (',' items+=DeclaredItem)* ';'; +DeclaredItem: level=NUMBER? (element=DeclaredVariable | element='*' | '(' items+=DeclaredItem (',' items+=DeclaredItem)* ')') attributes+=DeclarationAttribute*; + +type NamedElement = DeclaredVariable | DoType3Variable | ProcedureStatement; +type NamedType = DefineAliasStatement; + +DeclaredVariable: name=ID; + +DeclarationAttribute: InitialAttribute | DateAttribute | HandleAttribute | DefinedAttribute | PictureAttribute | EnvironmentAttribute | DimensionsDataAttribute | ValueAttribute | ValueListFromAttribute | ValueListAttribute | ValueRangeAttribute | ComputationDataAttribute | EntryAttribute | LikeAttribute | TypeAttribute; + +DateAttribute: 'DATE' ('(' pattern=STRING_TERM ')')?; + +DefinedAttribute: ('DEFINED' | 'DEF') (reference=MemberCall | '(' reference=MemberCall ')') (('POSITION' | 'POS') '(' position=Expression ')')?; + +PictureAttribute: ('PICTURE' | 'WIDEPIC' | 'PIC') picture=STRING_TERM?; + +DimensionsDataAttribute: ('DIMENSION' | 'DIM')? dimensions=Dimensions; + +TypeAttribute: 'TYPE' (type=[NamedType:ID] | '(' type=[NamedType:ID] ')'); + +ComputationDataAttribute: type=DataAttributeType dimensions=Dimensions?; + +ValueAttribute: 'VALUE' '(' (items+=ValueAttributeItem (',' items+=ValueAttributeItem)* | value=Expression) ')'; + +ValueAttributeItem: attributes+=DeclarationAttribute+; + +ValueListAttribute: 'VALUELIST' '(' (values+=Expression (',' values+=Expression)*)? ')'; + +ValueListFromAttribute: 'VALUELISTFROM' from=LocatorCall; + +ValueRangeAttribute: 'VALUERANGE' '(' (values+=Expression (',' values+=Expression)*)? ')'; + +DataAttributeType returns string: DefaultAttribute; + +LikeAttribute: 'LIKE' reference=LocatorCall; + +HandleAttribute: 'HANDLE' ('(' size=NUMBER ')')? (type=[NamedType:ID] | '(' type=[NamedType:ID] ')'); + +Dimensions: '(' (dimensions+=DimensionBound (',' dimensions+=DimensionBound)*)? ')'; + +/** + * Attention! This naming has an explanation: + * - When only bound1 is given, it is the upper bound. + * - Otherwise bound1 is the lower and bound2 is the upper bound! + * Keep in mind, that `DimensionBound: upper=Bound | lower=Bound ':' upper=Bound;` is expensive because of the long common prefix. + */ +DimensionBound: bound1=Bound (':' bound2=Bound)?; + +Bound: (expression='*' | expression=Expression ('REFER' '(' refer=LocatorCall ')')?); + +// ONLY FOR FILES +EnvironmentAttribute: ('ENVIRONMENT' | 'ENV') '(' items+=EnvironmentAttributeItem* ')'; + +EnvironmentAttributeItem: environment=ID ('(' (args+=Expression (','? args+=Expression)*)? ')')?; + +EntryAttribute: + ( + limited+='LIMITED' + )* + 'ENTRY' + ('(' attributes+=EntryDescription (',' attributes+=EntryDescription)* ')')? + ( + options+=Options | + variable+='VARIABLE' | + limited+='LIMITED' | + returns+=ReturnsOption | + (('EXTERNAL' | 'EXT') ('(' environmentName+=Expression ')')?) + )* + +; + +ReturnsOption: 'RETURNS' '(' returnAttribute=DeclarationAttribute* ')'; + +EntryDescription: EntryParameterDescription | EntryUnionDescription; + +EntryParameterDescription: (attributes+=DeclarationAttribute+ | star?='*' attributes+=DeclarationAttribute*); + +EntryUnionDescription: init=NUMBER attributes+=DeclarationAttribute* ',' prefixedAttributes+=PrefixedAttribute*; + +PrefixedAttribute: level=NUMBER attribute=DeclarationAttribute*; + +ProcedureParameter: id=FeatureID; + +ReferenceItem: ref=[NamedElement:FeatureID] dimensions=Dimensions?; + +Expression: BitOrExpression; + + +// Note for expressions: Documentation uses '¬' to denote inversion or negation. The language actually uses '^' + +// Priority 7 +BitOrExpression infers Expression: BitAndExpression ({infer BitOrExpression.left=current} op=('|' | '¬' | '^') right=BitAndExpression)*; + +// Priority 6 +BitAndExpression infers Expression: CompExpression ({infer BitAndExpression.left=current} op='&' right=CompExpression)*; + +// Priority 5 +CompExpression infers Expression: ConcatExpression ({infer CompExpression.left=current} op=('<' | '¬<' | '<=' | '=' | '¬=' | '^=' | '<>' | '>=' | '>' | '¬>') right=ConcatExpression)*; + +// Priority 4 +ConcatExpression infers Expression: AddExpression ({infer ConcatExpression.left=current} op=('||' | '!!') right=AddExpression)*; + +// Priority 3 +AddExpression infers Expression: MultExpression ({infer AddExpression.left=current} op=('+' | '-' ) right=MultExpression)*; + +// Priority 2 +MultExpression infers Expression: ExpExpression ({infer MultExpression.left=current} op=('*' | '/' ) right=ExpExpression)*; + +// Priority 1 +ExpExpression infers Expression: PrimaryExpression ({infer ExpExpression.left=current} op='**' right=PrimaryExpression)*; + +PrimaryExpression infers Expression: + Literal + | '(' Expression ')' + | UnaryExpression + | LocatorCall; + +MemberCall: + element=ReferenceItem + ({infer MemberCall.previous=current} + "." element=ReferenceItem + )*; + +LocatorCall: + element=MemberCall + ({infer LocatorCall.previous=current} + (pointer?="->" | handle?="=>") element=MemberCall + )*; + +ProcedureCall: procedure=[ProcedureStatement:ID] ('(' (args+=(Expression | '*') (',' args+=(Expression | '*'))*)? ')')?; + +LabelReference: label=[LabelPrefix:ID]; + +UnaryExpression: op=('+' | '-' | '¬' | '^') expr=Expression; + +ConstantExpression: Literal; + +Literal: ('(' multiplier=NUMBER ')')? value=(StringLiteral | NumberLiteral); + +StringLiteral: value=STRING_TERM; +NumberLiteral: value=NUMBER; + +FQN returns string: ID ('.' ID)*; +FeatureID returns string: ID; + +hidden terminal WS: /\s+/; +terminal ExecFragment: /(?<=EXEC\s*)[a-zA-Z]+\s[^;]*/i; +terminal ID: /[$@#_a-zA-Z][\w_$@#]*/; +/** + * Includes both fixed and non-fixed (with and without mantissa) + */ +terminal NUMBER: FULL_NUM /([bB]|[iI])*/; +// terminal WRAPPED_NUM: ("'" (FULL_NUM | HEX_CHAR*) "'") /([xX][uU]|[xX][nN]|[bB]4|[bB]3|[bB][xX]|[bB]|[gG][xX]|[gG]|[uU][xX]|[wW][xX]|[xX]|[iI])*/; +// terminal fragment HEX_CHAR: /[0-9a-fA-F]/; +terminal fragment NUM: /([0-9][0-9_]*(\.[0-9_]+)?)|(\.[0-9_]+)/; +terminal fragment FULL_NUM: NUM MANTISSA?; +terminal fragment MANTISSA: /[eEsSdDqQ][-+]?[0-9]+/; +// This terminal combines WRAPPED_NUM and normal strings +terminal STRING_TERM: /("(""|\\.|[^"\\])*"|'(''|\\.|[^'\\])*')([xX]|[aA]|[eE]|[xX][uU]|[xX][nN]|[bB]4|[bB]3|[bB][xX]|[bB]|[gG][xX]|[gG]|[uU][xX]|[wW][xX]|[xX]|[iI])*/; + +hidden terminal ML_COMMENT: /\/\*[\s\S]*?\*\//; +hidden terminal SL_COMMENT: /\/\/[^\n\r]*/; \ No newline at end of file diff --git a/packages/language/src/references/pli-name-provider.ts b/packages/language/src/references/pli-name-provider.ts new file mode 100644 index 0000000..44e513b --- /dev/null +++ b/packages/language/src/references/pli-name-provider.ts @@ -0,0 +1,36 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode, CstNode, DefaultNameProvider } from "langium"; +import { isProcedureStatement } from "../generated/ast"; + +export class PliNameProvider extends DefaultNameProvider { + override getName(node: AstNode): string | undefined { + if (isProcedureStatement(node)) { + const label = node.labels[0]; + return label?.name || undefined; + } else { + return super.getName(node); + } + } + override getNameNode(node: AstNode): CstNode | undefined { + if (isProcedureStatement(node)) { + const label = node.labels[0]; + if (label) { + return this.getNameNode(label); + } else { + return undefined; + } + } else { + return super.getNameNode(node); + } + } +} \ No newline at end of file diff --git a/packages/language/src/references/pli-references.ts b/packages/language/src/references/pli-references.ts new file mode 100644 index 0000000..8936747 --- /dev/null +++ b/packages/language/src/references/pli-references.ts @@ -0,0 +1,23 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode, DefaultReferences, FindReferencesOptions, ReferenceDescription, Stream } from "langium"; +import { isLabelPrefix, isProcedureStatement } from "../generated/ast"; + +export class PliReferences extends DefaultReferences { + override findReferences(targetNode: AstNode, options: FindReferencesOptions): Stream { + if (isLabelPrefix(targetNode) && isProcedureStatement(targetNode.$container!)) { + return this.findReferences(targetNode.$container!, options); + } else { + return super.findReferences(targetNode, options); + } + } +} \ No newline at end of file diff --git a/packages/language/src/references/pli-scope-computation.ts b/packages/language/src/references/pli-scope-computation.ts new file mode 100644 index 0000000..c01fff8 --- /dev/null +++ b/packages/language/src/references/pli-scope-computation.ts @@ -0,0 +1,30 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode, AstNodeDescription, AstUtils, DefaultScopeComputation, LangiumDocument, PrecomputedScopes } from "langium"; +import { CancellationToken } from "vscode-languageserver"; + +export class PliScopeComputation extends DefaultScopeComputation { + + override async computeExports(document: LangiumDocument, cancelToken = CancellationToken.None): Promise { + return this.computeExportsForNode(document.parseResult.value, document, AstUtils.streamAllContents, cancelToken); + } + + protected override processNode(node: AstNode, document: LangiumDocument, scopes: PrecomputedScopes): void { + const container = AstUtils.findRootNode(node); + if (container) { + const name = this.nameProvider.getName(node); + if (name) { + scopes.add(container, this.descriptions.createDescription(node, name, document)); + } + } + } +} diff --git a/packages/language/src/references/pli-scope-provider.ts b/packages/language/src/references/pli-scope-provider.ts new file mode 100644 index 0000000..b697298 --- /dev/null +++ b/packages/language/src/references/pli-scope-provider.ts @@ -0,0 +1,86 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstUtils, DefaultScopeProvider, DocumentCache, EMPTY_SCOPE, MapScope, ReferenceInfo, Scope, URI, UriUtils } from "langium"; +import { DeclaredVariable, IncludeDirective, isDeclaredVariable, isIncludeDirective, isMemberCall } from "../generated/ast"; +import { LangiumServices } from "langium/lsp"; + +export class PliScopeProvider extends DefaultScopeProvider { + + protected readonly globalDocumentScopeCache: DocumentCache; + + constructor(services: LangiumServices) { + super(services); + this.globalDocumentScopeCache = new DocumentCache(services.shared); + } + + protected override getGlobalScope(referenceType: string, context: ReferenceInfo): Scope { + return this.globalDocumentScopeCache.get(AstUtils.getDocument(context.container).uri, referenceType, () => { + const allIncludes = AstUtils.streamAst(AstUtils.getDocument(context.container).parseResult.value).filter(isIncludeDirective); + const allFiles = this.getUrisFromIncludes(AstUtils.getDocument(context.container).uri, allIncludes.toArray()); + return new MapScope(this.indexManager.allElements(referenceType, allFiles)); + }); + } + + private getUrisFromIncludes(relative: URI, includes: IncludeDirective[]): Set { + const uris = new Set(); + uris.add(relative.toString()); + const dirname = UriUtils.dirname(relative); + for (const include of includes) { + for (const file of include.items) { + const uri = UriUtils.joinPath(dirname, file.file.substring(1, file.file.length - 1)); + uris.add(uri.toString()); + } + } + // Always add the builtins + uris.add('pli-builtin:/builtins.pli'); + return uris; + } + + override getScope(context: ReferenceInfo): Scope { + if (context.property === 'ref') { + const memberCall = AstUtils.getContainerOfType(context.container, isMemberCall); + if (memberCall?.previous) { + const previouslyReferenced = memberCall.previous.element.ref.ref; + if (previouslyReferenced && isDeclaredVariable(previouslyReferenced)) { + return this.createScopeForNodes(this.findChildren(previouslyReferenced)); + } else { + return EMPTY_SCOPE; + } + } + } + return super.getScope(context); + } + + private findChildren(declared: DeclaredVariable): DeclaredVariable[] { + const declaredItem = declared.$container; + let level = Number(declaredItem.level); + if (isNaN(level) || level < 1) { + level = 1; + } + const result: DeclaredVariable[] = []; + const container = declaredItem.$container; + const index = container.items.indexOf(declaredItem); + for (let i = index + 1; i < container.items.length; i++) { + const item = container.items[i]; + const childLevel = Number(item.level); + if (isNaN(childLevel) || childLevel < level) { + break; + } + if (childLevel === level + 1) { + if(isDeclaredVariable(item.element)) { + result.push(item.element); + } + } + } + return result; + } +} \ No newline at end of file diff --git a/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts b/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts new file mode 100644 index 0000000..6cf68f7 --- /dev/null +++ b/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts @@ -0,0 +1,32 @@ +import { ValidationAcceptor } from "langium"; +import { Bound, DimensionBound, isLiteral, isNumberLiteral, isUnaryExpression } from "../../generated/ast"; + +export function IBM1295IE_sole_bound_specified(bound: DimensionBound, accept: ValidationAcceptor): void { + if(bound.bound2 !== undefined) { + return; + } + const upper = bound.bound1; + if(isBoundNegative(upper) || isBoundZero(upper)) { + accept("error", "Sole bound specified is less than 1. An upper bound of 1 is assumed.", { + node: bound, + property: "bound1", + code: "IBM1295IE" + }); + } +} + +function isBoundNegative(bound: Bound) { + return bound.expression !== '*' + && isUnaryExpression(bound.expression) + && bound.expression.op === '-' + && isLiteral(bound.expression.expr) + && isNumberLiteral(bound.expression.expr.value); +} + +function isBoundZero(bound: Bound): boolean { + return bound.expression !== '*' + && isLiteral(bound.expression) + && isNumberLiteral(bound.expression.value) + //TODO find other cases when it is zero + && bound.expression.value.value === '0'; +} diff --git a/packages/language/src/validation/messages/IBM1324IE-name-occurs-more-than-once-within-exports-clause.ts b/packages/language/src/validation/messages/IBM1324IE-name-occurs-more-than-once-within-exports-clause.ts new file mode 100644 index 0000000..1bf17f8 --- /dev/null +++ b/packages/language/src/validation/messages/IBM1324IE-name-occurs-more-than-once-within-exports-clause.ts @@ -0,0 +1,19 @@ +import { ValidationAcceptor } from "langium" +import { Exports } from "../../generated/ast" + +export function IBM1324IE_name_occurs_more_than_once_within_exports_clause(exports: Exports, accept: ValidationAcceptor): void { + const set = new Set(); + exports.procedures.forEach((procedure, index) => { + if(!set.has(procedure)) { + set.add(procedure) + } else { + accept('error', `The name '${procedure}' occurs more than once in the EXPORTS clause.`, { + code: 'IBM1324IE', + node: exports, + property: "procedures", + index + }); + } + }); +} + diff --git a/packages/language/src/validation/messages/IBM1388IE-NODESCRIPTOR-attribute-is-invalid-when-any-parameter-has-NONCONNECTED-attribute.ts b/packages/language/src/validation/messages/IBM1388IE-NODESCRIPTOR-attribute-is-invalid-when-any-parameter-has-NONCONNECTED-attribute.ts new file mode 100644 index 0000000..96ec0f5 --- /dev/null +++ b/packages/language/src/validation/messages/IBM1388IE-NODESCRIPTOR-attribute-is-invalid-when-any-parameter-has-NONCONNECTED-attribute.ts @@ -0,0 +1,25 @@ +import { ValidationAcceptor } from "langium"; +import { isComputationDataAttribute, isDeclaredVariable, isDeclareStatement, isSimpleOptionsItem, isStatement, ProcedureStatement, SimpleOptionsItem } from "../../generated/ast"; +import { compareIdentifiers, normalizeIdentifier } from "../utils"; + +export function IBM1388IE_NODESCRIPTOR_attribute_is_invalid_when_any_parameter_has_NONCONNECTED_attribute(procedureStatement: ProcedureStatement, accept: ValidationAcceptor): void { + const items = procedureStatement.options.flatMap(o => o.items) + const item = items.find(i => isSimpleOptionsItem(i) && i.value.toUpperCase() === "NODESCRIPTOR") as SimpleOptionsItem|undefined; + if(item) { + const parameterNames = new Set(procedureStatement.parameters.map(p => normalizeIdentifier(p.id))); + const nonConnectedParameters = procedureStatement.statements + .filter(isStatement) + .map(s => s.value) + .filter(isDeclareStatement) + .flatMap(d => d.items) + .filter(i => isDeclaredVariable(i.element) && parameterNames.has(normalizeIdentifier(i.element.name))) + .filter(i => i.attributes.some(a => isComputationDataAttribute(a) && compareIdentifiers(a.type, 'NONCONNECTED'))); + if(nonConnectedParameters.length > 0) { + accept("error", "The NODESCRIPTOR attribute is invalid when any parameters have the NONCONNECTED attribute.", { + code: "IBM1388IE", + node: item, + property: 'value' + }); + } + } +} diff --git a/packages/language/src/validation/messages/IBM1747IS-Function-cannot-be-used-before-the-functions-descriptor-list-has-been-scanned.ts b/packages/language/src/validation/messages/IBM1747IS-Function-cannot-be-used-before-the-functions-descriptor-list-has-been-scanned.ts new file mode 100644 index 0000000..a1557c1 --- /dev/null +++ b/packages/language/src/validation/messages/IBM1747IS-Function-cannot-be-used-before-the-functions-descriptor-list-has-been-scanned.ts @@ -0,0 +1,37 @@ +import { AstUtils, ValidationAcceptor } from "langium"; +import { isDeclaredVariable, isEntryAttribute, MemberCall } from "../../generated/ast"; + +/** + * This validation addresses functions, not procedures. + * TODO check if also procedures are affected + * @see https://www.ibm.com/docs/en/epfz/6.1?topic=codes-compiler-severe-messages-1500-2399#ibm1747i__msgId__1 + */ +export function IBM1747IS_Function_cannot_be_used_before_the_functions_descriptor_list_has_been_scanned(call: MemberCall, accept: ValidationAcceptor): void { + //member call points to variable declaration... + if (!isDeclaredVariable(call.element.ref.ref)) { + return; + } + //...which actually is a function declaration... + const declaration = call.element.ref.ref.$container; + if (!declaration.attributes.some(a => isEntryAttribute(a) && a.returns)) { + return; + } + //... where both function call and function declaration are in the same file... + const callDocument = AstUtils.getDocument(call); + const declarationDocument = AstUtils.getDocument(declaration); + if (callDocument !== declarationDocument) { + return; + } + //...and the declaration happens after the call + const callOffset = call.$cstNode!.offset; + const declarationOffset = declaration.$cstNode!.offset; + if (callOffset > declarationOffset) { + return; + } + //throw error + accept('error', "Function cannot be used before the function's descriptor list has been scanned.", { + code: "IBM1747IS", + node: call, + property: "element" + }); +} \ No newline at end of file diff --git a/packages/language/src/validation/pli-document-validator.ts b/packages/language/src/validation/pli-document-validator.ts new file mode 100644 index 0000000..74eb275 --- /dev/null +++ b/packages/language/src/validation/pli-document-validator.ts @@ -0,0 +1,37 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { AstNode, DefaultDocumentValidator, DiagnosticInfo, DocumentValidator, LangiumDocument, LinkingErrorData, ValidationOptions } from "langium"; +import { Diagnostic } from "vscode-languageserver-types"; + +export class PliDocumentValidator extends DefaultDocumentValidator { + + protected override processLinkingErrors(document: LangiumDocument, diagnostics: Diagnostic[], _options: ValidationOptions): void { + for (const reference of document.references) { + const linkingError = reference.error; + if (linkingError) { + const info: DiagnosticInfo = { + node: linkingError.container, + property: linkingError.property, + index: linkingError.index, + data: { + code: DocumentValidator.LinkingError, + containerType: linkingError.container.$type, + property: linkingError.property, + refText: linkingError.reference.$refText + } satisfies LinkingErrorData + }; + diagnostics.push(this.toDiagnostic('warning', linkingError.message, info)); + } + } + } + +} diff --git a/packages/language/src/validation/pli-validator.ts b/packages/language/src/validation/pli-validator.ts new file mode 100644 index 0000000..b0545be --- /dev/null +++ b/packages/language/src/validation/pli-validator.ts @@ -0,0 +1,40 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import type { ValidationChecks } from 'langium'; +import type { Pl1AstType } from '../generated/ast.js'; +import type { Pl1Services } from '../pli-module.js'; +import { IBM1295IE_sole_bound_specified } from './messages/IBM1295IE-sole-bound-specified.js'; +import { IBM1324IE_name_occurs_more_than_once_within_exports_clause } from './messages/IBM1324IE-name-occurs-more-than-once-within-exports-clause.js'; +import { IBM1388IE_NODESCRIPTOR_attribute_is_invalid_when_any_parameter_has_NONCONNECTED_attribute } from './messages/IBM1388IE-NODESCRIPTOR-attribute-is-invalid-when-any-parameter-has-NONCONNECTED-attribute.js'; +import { IBM1747IS_Function_cannot_be_used_before_the_functions_descriptor_list_has_been_scanned } from './messages/IBM1747IS-Function-cannot-be-used-before-the-functions-descriptor-list-has-been-scanned.js'; + +/** + * Register custom validation checks. + */ +export function registerValidationChecks(services: Pl1Services) { + const registry = services.validation.ValidationRegistry; + const validator = services.validation.Pl1Validator; + const checks: ValidationChecks = { + DimensionBound: [IBM1295IE_sole_bound_specified], + Exports: [IBM1324IE_name_occurs_more_than_once_within_exports_clause], + MemberCall: [IBM1747IS_Function_cannot_be_used_before_the_functions_descriptor_list_has_been_scanned], + ProcedureStatement: [IBM1388IE_NODESCRIPTOR_attribute_is_invalid_when_any_parameter_has_NONCONNECTED_attribute], + }; + registry.register(checks, validator); +} + +/** + * Implementation of custom validations. + */ +export class Pl1Validator { + +} diff --git a/packages/language/src/validation/utils.ts b/packages/language/src/validation/utils.ts new file mode 100644 index 0000000..457f827 --- /dev/null +++ b/packages/language/src/validation/utils.ts @@ -0,0 +1,7 @@ +export function normalizeIdentifier(id: T): Uppercase { + return id.toUpperCase() as Uppercase; +} + +export function compareIdentifiers(lhs: T, rhs: T) { + return normalizeIdentifier(lhs) === normalizeIdentifier(rhs); +} \ No newline at end of file diff --git a/packages/language/src/workspace/pli-builtin-functions.ts b/packages/language/src/workspace/pli-builtin-functions.ts new file mode 100644 index 0000000..7a7aef0 --- /dev/null +++ b/packages/language/src/workspace/pli-builtin-functions.ts @@ -0,0 +1,414 @@ +export const Builtins = ` // Mathematical functions + ABS: PROC (value) RETURNS (); + END; + + CEIL: PROC (value) RETURNS (); + END; + + COMPLEX: PROC (real, imag) RETURNS (COMPLEX); + END; + + CONJG: PROC (value) RETURNS (COMPLEX); + END; + + FLOOR: PROC (value) RETURNS (); + END; + + IMAG: PROC (value) RETURNS (); + END; + + MAX: PROC (value1, value2) RETURNS (); + END; + + MAXVAL: PROC (array) RETURNS (); + END; + + MIN: PROC (value1, value2) RETURNS (); + END; + + MINVAL: PROC (array) RETURNS (); + END; + + MOD: PROC (value1, value2) RETURNS (); + END; + + RANDOM: PROC () RETURNS (); + END; + + REAL: PROC (value) RETURNS (); + END; + + REM: PROC (value1, value2) RETURNS (); + END; + + ROUND: PROC (value) RETURNS (); + END; + + ROUNDAWAYFROMZERO: PROC (value) RETURNS (); + END; + + ROUNDTOEVEN: PROC (value) RETURNS (); + END; + + SIGN: PROC (value) RETURNS (); + END; + + TRUNC: PROC (value) RETURNS (); + END; + + // Array handling functions + ALL: PROC (array) RETURNS (); + END; + + ANY: PROC (array) RETURNS (); + END; + + DIMENSION: PROC (array) RETURNS (); + END; + + HBOUND: PROC (array) RETURNS (); + END; + + HBOUNDACROSS: PROC (array) RETURNS (); + END; + + INARRAY: PROC (array, value) RETURNS (); + END; + + LBOUND: PROC (array) RETURNS (); + END; + + LBOUNDACROSS: PROC (array) RETURNS (); + END; + + POLY: PROC (array, value) RETURNS (); + END; + + PROD: PROC (array) RETURNS (); + END; + + QUICKSORT: PROC (array) RETURNS (); + END; + + QUICKSORTX: PROC (array, fn) RETURNS (); + END; + + SUM: PROC (array) RETURNS (); + END; + + // Buffer management functions + COMPARE: PROC (buffer1, buffer2) RETURNS (); + END; + + HEXENCODE: PROC (buffer) RETURNS (); + END; + + HEXENCODE8: PROC (buffer) RETURNS (); + END; + + HEXIMAGE: PROC (buffer) RETURNS (); + END; + + HEXIMAGE8: PROC (buffer) RETURNS (); + END; + + MEMCONVERT: PROC (buffer, from, to) RETURNS (); + END; + + MEMCOLLAPSE: PROC (buffer) RETURNS (); + END; + + MEMCU12: PROC (buffer, target) RETURNS (); + END; + + MEMCU14: PROC (buffer, target) RETURNS (); + END; + + MEMCU21: PROC (buffer, target) RETURNS (); + END; + + MEMCU24: PROC (buffer, target) RETURNS (); + END; + + MEMCU41: PROC (buffer, target) RETURNS (); + END; + + MEMCU42: PROC (buffer, target) RETURNS (); + END; + + MEMINDEX: PROC (buffer, value) RETURNS (); + END; + + MEMREPLACE: PROC (buffer, value, replacement) RETURNS (); + END; + + MEMSEARCH: PROC (buffer, value) RETURNS (); + END; + + MEMSEARCHR: PROC (buffer, value) RETURNS (); + END; + + MEMSQUEEZE: PROC (buffer, target, replacement) RETURNS (); + END; + + /** + * Searches for the first nonoccurrence of any one of the elements of + * a string within a buffer. + */ + MEMVERIFY: PROC (buffer, value) RETURNS (); + END; + + MEMVERIFYR: PROC (buffer, value) RETURNS (); + END; + + WHEREDIFF: PROC (buffer1, buffer2) RETURNS (); + END; + + WSCOLLAPSE: PROC (buffer, target) RETURNS (); + END; + + WSCOLLAPSE16: PROC (buffer, target) RETURNS (); + END; + + WSREPLACE: PROC (buffer, target) RETURNS (); + END; + + WSREPLACE16: PROC (buffer, target) RETURNS (); + END; + + XMLCHAR: PROC (buffer) RETURNS (); + END; + + XMLSCRUB: PROC (buffer) RETURNS (); + END; + + XMLSCRUB16: PROC (buffer) RETURNS (); + END; + + XMLUCHAR: PROC (buffer) RETURNS (); + END; + + // Condition handling builtins + DATAFIELD: PROC () RETURNS (); + END; + ONACTUAL: PROC () RETURNS (); + END; + ONAREA: PROC () RETURNS (); + END; + ONCHAR: PROC () RETURNS (); + END; + ONEXPECTED: PROC () RETURNS (); + END; + ONCODE: PROC () RETURNS (); + END; + ONCONDCOND: PROC () RETURNS (); + END; + ONCONDID: PROC () RETURNS (); + END; + ONCOUNT: PROC () RETURNS (); + END; + ONFILE: PROC () RETURNS (); + END; + ONGSOURCE: PROC () RETURNS (); + END; + ONHBOUND: PROC () RETURNS (); + END; + ONJSONNAME: PROC () RETURNS (); + END; + ONKEY: PROC () RETURNS (); + END; + ONLBOUND: PROC () RETURNS (); + END; + ONLINE: PROC () RETURNS (); + END; + ONLOC: PROC () RETURNS (); + END; + ONOFFSET: PROC () RETURNS (); + END; + ONOPERATOR: PROC () RETURNS (); + END; + ONPACKAGE: PROC () RETURNS (); + END; + ONPROCEDURE: PROC () RETURNS (); + END; + ONSOURCE: PROC () RETURNS (); + END; + ONSUBSCRIPT: PROC () RETURNS (); + END; + ONTEXT: PROC () RETURNS (); + END; + ONUCHAR: PROC () RETURNS (); + END; + ONUSOURCE: PROC () RETURNS (); + END; + ONWCHAR: PROC () RETURNS (); + END; + ONWSOURCE: PROC () RETURNS (); + END; + + // Date and time functions + DATE: PROC () RETURNS (); + END; + + DATEIME: PROC () RETURNS (); + END; + + DAYS: PROC () RETURNS (); + END; + + DAYSTODATE: PROC (days) RETURNS (); + END; + + DAYSTOMICROSECS: PROC (days) RETURNS (); + END; + + DAYSTOSECS: PROC (days) RETURNS (); + END; + + JULIANTOSMF: PROC (julian) RETURNS (); + END; + + MAXDATE: PROC () RETURNS (); + END; + + MICROSECS: PROC () RETURNS (); + END; + + MICROSECSTODATE: PROC (microsecs) RETURNS (); + END; + + MICROSECSTODAYS: PROC (microsecs) RETURNS (); + END; + + MINDATE: PROC () RETURNS (); + END; + + REPATTERN: PROC () RETURNS (); + END; + + SECS: PROC () RETURNS (); + END; + + SECSTODATE: PROC (secs) RETURNS (); + END; + + SECSTODAYS: PROC (secs) RETURNS (); + END; + + SMFTOJULIAN: PROC (smf) RETURNS (); + END; + + STCKETODATE: PROC (stck) RETURNS (); + END; + + STCKTODATE: PROC (stck) RETURNS (); + END; + + TIME: PROC () RETURNS (); + END; + + TIMESTAMP: PROC () RETURNS (); + END; + + UTCDATETIME: PROC () RETURNS (); + END; + + UTCMICROSECS: PROC () RETURNS (); + END; + + UTCSECS: PROC () RETURNS (); + END; + + VALIDDATE: PROC (date) RETURNS (); + END; + + WEEKDAY: PROC (date) RETURNS (); + END; + + Y4DATE: PROC (date) RETURNS (); + END; + + Y4JULIAN: PROC (julian) RETURNS (); + END; + + Y4YEAR: PROC (date) RETURNS (); + END; + + // Encoding and hashing functions + BASE64DECODE: PROC (buffer) RETURNS (); + END; + BASE64DECODE8: PROC (buffer) RETURNS (); + END; + BASE64DECODE16: PROC (buffer) RETURNS (); + END; + BASE64ENCODE: PROC (buffer) RETURNS (); + END; + BASE64ENCODE8: PROC (buffer) RETURNS (); + END; + BASE64ENCODE16: PROC (buffer) RETURNS (); + END; + CHECKSUM: PROC (buffer) RETURNS (); + END; + HEXDECODE: PROC (buffer) RETURNS (); + END; + HEXDECODE8: PROC (buffer) RETURNS (); + END; + SHA1DIGEST: PROC (buffer) RETURNS (); + END; + SHA1FINAL: PROC (buffer) RETURNS (); + END; + SHA1INIT: PROC (buffer) RETURNS (); + END; + SHA1UPDATE: PROC (buffer) RETURNS (); + END; + SHA2DIGESTx: PROC (buffer) RETURNS (); + END; + SHA2FINALx: PROC (buffer) RETURNS (); + END; + SHA2INITx: PROC (buffer) RETURNS (); + END; + SHA2UPDATEx: PROC (buffer) RETURNS (); + END; + SHA3DIGESTx: PROC (buffer) RETURNS (); + END; + SHA3FINALx: PROC (buffer) RETURNS (); + END; + SHA3INITx: PROC (buffer) RETURNS (); + END; + SHA3UPDATEx: PROC (buffer) RETURNS (); + END; + + // Floating point inquiry functions + EPSILON: PROC () RETURNS (); + END; + HUGE: PROC () RETURNS (); + END; + ISFINITE: PROC (value) RETURNS (); + END; + ISINF: PROC (value) RETURNS (); + END; + ISNAN: PROC (value) RETURNS (); + END; + ISNORMAL: PROC (value) RETURNS (); + END; + ISZERO: PROC (value) RETURNS (); + END; + MAXEXP: PROC () RETURNS (); + END; + MINEXP: PROC () RETURNS (); + END; + PLACES: PROC (value) RETURNS (); + END; + RADIX: PROC (value) RETURNS (); + END; + TINY: PROC () RETURNS (); + END; + EXPONENT: PROC (value) RETURNS (); + END; + PRED: PROC (value) RETURNS (); + END; + SCALE: PROC (value, radix) RETURNS (); + END; + SUCC: PROC (value) RETURNS (); + END; + `; \ No newline at end of file diff --git a/packages/language/src/workspace/pli-index-manager.ts b/packages/language/src/workspace/pli-index-manager.ts new file mode 100644 index 0000000..c02d06f --- /dev/null +++ b/packages/language/src/workspace/pli-index-manager.ts @@ -0,0 +1,18 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { DefaultIndexManager, LangiumDocument } from "langium"; + +export class PliIndexManager extends DefaultIndexManager { + override isAffected(document: LangiumDocument, changedUris: Set): boolean { + return false; + } +} \ No newline at end of file diff --git a/packages/language/src/workspace/pli-workspace-manager.ts b/packages/language/src/workspace/pli-workspace-manager.ts new file mode 100644 index 0000000..68a4ea1 --- /dev/null +++ b/packages/language/src/workspace/pli-workspace-manager.ts @@ -0,0 +1,29 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { DefaultWorkspaceManager, LangiumDocument, LangiumDocumentFactory, URI, WorkspaceFolder } from "langium"; +import { Builtins } from "./pli-builtin-functions.js"; +import { LangiumSharedServices } from "langium/lsp"; + +export class PliWorkspaceManager extends DefaultWorkspaceManager { + + private readonly factory: LangiumDocumentFactory; + + constructor(services: LangiumSharedServices) { + super(services); + this.factory = services.workspace.LangiumDocumentFactory; + } + + protected override async loadAdditionalDocuments(_folders: WorkspaceFolder[], _collector: (document: LangiumDocument) => void): Promise { + const document = this.factory.fromString(Builtins, URI.parse('pli-builtin:///builtins.pli')); + _collector(document); + } +} diff --git a/packages/language/test/extracted-doc-cases.test.ts b/packages/language/test/extracted-doc-cases.test.ts new file mode 100644 index 0000000..ec0c359 --- /dev/null +++ b/packages/language/test/extracted-doc-cases.test.ts @@ -0,0 +1,5614 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +/** + * Auto-extracted cases from the: + * - PL/I Language Reference v6.1 + * - PL/I Programming Guide v6.1 + * + * Each case is tagged with a bit of auto-extracted context + a comment referencing the sourcing doc & page number + * + * All cases have been run through the PL/I compiler and passed, and are now being run through the Langium parser to ensure they pass here as well + */ + +import { beforeAll, expect, test } from "vitest"; +import { EmptyFileSystem, type LangiumDocument } from "langium"; +import { parseHelper } from "langium/test"; +import type { PliProgram } from "pl-one-language"; +import { createPliServices } from "pl-one-language"; + +let services: ReturnType; +let parse: ReturnType>; +let parseStmts: ReturnType>; + +beforeAll(async () => { + services = createPliServices(EmptyFileSystem); + parse = parseHelper(services.pli); + + /** + * Helper function to parse a string of PL/I statements, + * wrapping them in a procedure to ensure they are valid + */ + parseStmts = (input: string) => { + return parse(` STARTPR: PROCEDURE OPTIONS (MAIN); +${input} + end STARTPR;`); + } + + // activate the following if your linking test requires elements from a built-in library, for example + await services.shared.workspace.WorkspaceManager.initializeWorkspace([]); +}); + +test('Block block-492.pli', async () => { + // Context: + // + // control. It allows multiple ON-units to get control for the same condition. + // The processing continues as if the ON-unit executing the RESIGNAL did not exist and was never given + // condition to get control. + // The RESIGNAL statement terminates the current ON-unit and allows another ON-unit for the same + // RESIGNAL statement + // attribute. + // Is any condition described in Chapter 16, “Conditions,” on page 349 or defined with the CONDITION + // condition + // If the specified condition is disabled, the SIGNAL statement becomes equivalent to a null statement. + // the condition. The established action is taken unless the condition is disabled. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.398 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + RESIGNAL + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-508.pli', async () => { + // Context: + // + // Example + // A reference with the AREA attribute + // x + // 407 + // Chapter 18. Built-in functions, pseudovariables, and subroutines   + // ATAND + // . + // x + // obtained from the area + // value that indicates the size of the largest single allocation that can be + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.459 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Uarea area(1000); + dcl Pz ptr; + dcl C99z char(99) varyingz based(Pz); + dcl (SizeBefore, SizeAfter) fixed bin(31); + SizeBefore = availablearea(Uarea); /* returns 1000 */ + Alloc C99z in(Uarea); + SizeAfter = availablearea(Uarea); /* returns 896 */ + dcl C9 char(896) based(Pz); + Alloc C9 in(Uarea); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-400.pli', async () => { + // Context: + // + // both specify null ON-units for the same file. + // L2 + // and + // L1 + // “ON-units for file variables” on page 345). In the following example, the statements labelled + // On-units can be established for a file constant through a file variable that represents its value (see + // • As the expression in a RETURN statement. + // • To qualify an input/output condition for ON, SIGNAL, and REVERT statements + // • As an argument to be passed to a function or subroutine + // • In a FILE or COPY option + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.331 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl F file, + G file variable; + G=F; + L1: on endfile(G); + L2: on endfile(F); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-204.pli', async () => { + // Context: + // + // "would be the same as this longer declare: + // func + // The declare for the entry " + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 180 + // Assignments to UNIONs + // description, the member names are not copied. For example, the following declares are valid: + // The LIKE attribute is supported in ENTRY descriptions and in parameter declarations. If used in an ENTRY + // name with the LIKE attribute. + // follows the object variable in the LIKE attribute must be equal to or less than the level-number of the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.232 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl func entry( 1, 2 char(20) var, 2 char(10) var, 2 char(30) var ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-658.pli', async () => { + // Context: + // + // which is a structure declaration: + // For example, assume that PAYRL is a member of the data set SYSLIB and contains the following text, + // compile-time option.) + // %INCLUDE, execution of the preprocessor can be omitted. (This necessitates the use of the INCLUDE + // If the preprocessor input and the included text contain no preprocessor statements other than + // portion of the preprocessor input. + // For example, it is not allowable to have half of a %IF statement in an included text and half in another + // Preprocessor statements, DO-groups, SELECT-groups and procedures in included text must be complete. + // target label in the %GOTO statement must not precede the %GOTO. + // A %GO TO statement in included text can transfer control only to a point within the same include file. The + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.670 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DECLARE 1 PAYROLL, + 2 NAME, + 3 LAST CHARACTER (30) VARYING, + 3 FIRST CHARACTER (15) VARYING, + 3 MIDDLE CHARACTER (3) VARYING, + 2 CURR, + 3 (REGLAR, OVERTIME) FIXED DECIMAL (8,2), + 2 YTD LIKE CURR; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-297.pli', async () => { + // Context: + // + // is encountered or until a %POP directive that restores the previous %PRINT directive is encountered. + // The %NOPRINT directive causes printing of the source listings to be suspended until a %PRINT directive + // %NOPRINT directive + // oriented data transmission,” on page 289. + // For details about the LOCATE statement, see “LOCATE statement” on page 291 in Chapter 11, “Record- + // BUFFERED file for locate mode processing. + // to the location of the next record. The LOCATE statement can be used only with an OUTPUT SEQUENTIAL + // The LOCATE statement allocates storage within an output buffer for a based variable and sets a pointer + // LOCATE statement + // The %LINE directive is invalid unless the LINEDIR compiler option is in effect. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.278 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + %NOPRINT + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-477.pli', async () => { + // Context: + // + // Consider the following example: + // Specifies the currency symbol. + // currency symbol + // type of sign character can appear in each field. + // currency symbol) specifies a currency symbol in the character value of numeric character data. Only one + // The picture characters S, +, and – specify signs in numeric character data. The picture character $ (or the + // Using signs and currency symbols + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 334 + // Currency symbols + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.386 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Price picture '$99V.99'; + Price = 12.45; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-610.pli', async () => { + // Context: + // + // Example + // 551 + // Chapter 18. Built-in functions, pseudovariables, and subroutines   + // SINH + // have the UNALIGNED attribute. + // x + // • All other elements in + // with the NONVARYING and BIT attributes have the ALIGNED attribute. + // x + // • Elements in + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.603 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Scids char(17) init('See you at SCIDS!') static; + dcl Vscids char(20) varying init('See you at SCIDS!') static; + dcl Stg fixed bin(31); + Stg = storage (Scids); /* 17 bytes */ + Stg = currentsize (Scids); /* 17 bytes */ + Stg = size (Vscids); /* 22 bytes */ + Stg = currentsize (Vscids); /* 19 bytes */ + Stg = size (Stg); /* 4 bytes */ + Stg = currentsize (Stg); /* 4 bytes */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-278.pli', async () => { + // Context: + // + // UPTHRU and DOWNTHRU are particularly useful with ordinals. Consider the following example: + // Similarly, the following loop avoids the problem of decrementing an unsigned value equal to zero: + // FIXEDOVERFLOW condition would not be raised by the following loop: + // updated; this can be very useful when there is no value after the terminating value. For instance, the + // When the UPTHRU option is used, the reference is compared to the terminating value before being + // has the value 5: + // i + // In the following example, the do-group executes 5 times and at the end of the loop + // terminating value. + // The UPTHRU and DOWNTHRU options make successive executions of the do-group dependent upon the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.270 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define ordinal Color ( Red value (1), + Orange, + Yellow, + Green, + Blue, + Indigo, + Violet); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-184.pli', async () => { + // Context: + // + // precision: + // However, the following statement specifies both the FIXED BINARY attribute as a default and the + // BINARY: + // For example, the following statement specifies precision for identifiers already known to be FIXED + // precision for FIXED DECIMAL names is to be (8,3). + // influenced by the default statement, because this statement specifies only that the default + // not + // It is + // If it is not declared explicitly, I is given the language-specified default attributes FIXED BINARY(15,0). + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.222 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DFT RANGE(*) FIXED BINARY VALUE(FIXED BINARY(31)); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-129.pli', async () => { + // Context: + // + // To return from a subroutine, the RETURN statement syntax is as follows: + // Return from a subroutine + // of course). + // A procedure with the RETURNS option must contains at least one RETURN statement (with an expression, + // option. + // Conversely, a RETURN statement with an expression is not valid in a procedure without the RETURNS + // A RETURN statement without an expression is not valid in a procedure with the RETURNS option. + // The RETURN statement with an expression should not be used within a procedure with OPTIONS(MAIN). + // immediately following the invocation reference. + // the RETURN statement and returns control to the invoking procedure. Control is returned to the point + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.175 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + RETURN + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-689.pli', async () => { + // Context: + // + // Upper limits + // Lower limits + // (continued) + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 632 + // Limits + // Upper limits + // Lower limits + // (continued) + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.684 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl lower_00813 char + value( ( + '6162636465666768'x + || '696A6B6C6D6E6F70'x + || '7172737475767778'x + || '797ADCDDDEDFE1E2'x + || 'E3E4E5E6E7E8E9EA'x + || 'EBECEDEEEFF0F1F3'x + || 'F4F5F6F7F8F9FAFB'x + || 'FCFDFE'x + ) ); + dcl upper_00813 char + value( ( + '4142434445464748'x + || '494A4B4C4D4E4F50'x + || '5152535455565758'x + || '595AB6B8B9BAC1C2'x + || 'C3C4C5C6C7C8C9CA'x + || 'CBCCCDCECFD0D1D3'x + || 'D4D5D6D7D8D9DADB'x + || 'BCBEBF'x + ) ); + dcl lower_00819 char + value( ( + '6162636465666768'x + || '696A6B6C6D6E6F70'x + || '7172737475767778'x + || '797AE0E1E2E3E4E5'x + || 'E6E7E8E9EAEBECED'x + || 'EEEFF0F1F2F3F4F5'x + || 'F6F8F9FAFBFCFDFE'x + ) ); + dcl upper_00819 char + value( ( + '4142434445464748'x + || '494A4B4C4D4E4F50'x + || '5152535455565758'x + || '595AC0C1C2C3C4C5'x + || 'C6C7C8C9CACBCCCD'x + || 'CECFD0D1D2D3D4D5'x + || 'D6D8D9DADBDCDDDE'x + ) ); + dcl lower_00850 char + value( ( + '6162636465666768'x + || '696A6B6C6D6E6F70'x + || '7172737475767778'x + || '797A818283848586'x + || '8788898A8B8C8D91'x + || '93949596979BA0A1'x + || 'A2A3A4C6D0E4E7EC'x + ) ); + dcl upper_00850 char + value( ( + '4142434445464748'x + || '494A4B4C4D4E4F50'x + || '5152535455565758'x + || '595A9A90B68EB78F'x + || '80D2D3D4D8D7DE92'x + || 'E299E3EAEB9DB5D6'x + || 'E0E9A5C7D1E5E8ED'x + ) ); + dcl lower_00858 char + value( ( + '6162636465666768'x + || '696A6B6C6D6E6F70'x + || '7172737475767778'x + || '797A818283848586'x + || '8788898A8B8C8D91'x + || '93949596979BA0A1'x + || 'A2A3A4C6D0E4E7EC'x + ) ); + dcl upper_00858 char + value( ( + '4142434445464748'x + || '494A4B4C4D4E4F50'x + || '5152535455565758'x + || '595A9A90B68EB78F'x + || '80D2D3D4D8D7DE92'x + || 'E299E3EAEB9DB5D6'x + || 'E0E9A5C7D1E5E8ED'x + ) ); + dcl lower_00871 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '575870798DA1C0CB'x + || 'CDCECFD0DBDCDDDE'x + ) ); + dcl upper_00871 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '7778807CAD5F4AEB'x + || 'EDEEEF5AFBFCFDFE'x + ) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-688.pli', async () => { + // Context: + // + // Upper limits + // Lower limits + // (continued) + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + // 631 + // Appendix A. Limits   + // Limits + // Upper limits + // Lower limits + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.683 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl lower_00280 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424345464749'x + || '52535556575A6A70'x + || '798C8D8E9CA1C0CB'x + || 'CCCECFD0DBDCDEE0'x + ) ); + dcl upper_00280 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626365666769'x + || '727375767771ED80'x + || 'FDACADAE9E7864EB'x + || 'ECEEEF74FBFCFE68'x + ) ); + dcl lower_00284 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4851525354555657'x + || '586A708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_00284 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6871727374757677'x + || '787B80ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_00285 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_00285 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_00297 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424345464749'x + || '5253555657586A70'x + || '7C8C8D8E9CC0CBCC'x + || 'CDCECFD0DBDCDEE0'x + ) ); + dcl upper_00297 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626365666769'x + || '727375767778FD80'x + || '64ACADAE9E71EBEC'x + || 'EDEEEF74FBFCFE68'x + ) ); + dcl lower_00500 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_00500 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-68.pli', async () => { + // Context: + // + // them separately. Consider the following example: + // necessarily go through more than one. To understand the conversion rules, it is convenient to consider + // More than one conversion might be required for a particular operation. The implementation does not + // LIMITS(FIXEDDEC(N1,N2)). + // is the maximum precision for FIXED DECIMAL. This is the value N2 from the compiler option + // N + // • + // LIMITS(FIXEDBIN(M1,M2)). + // is the maximum precision for FIXED BINARY. This is the value M2 from the compiler option + // M + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.127 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl A fixed dec(3,2) init(1.23); + dcl B fixed bin(15,5); + B = A; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-142.pli', async () => { + // Context: + // + // the parent structure. + // parent structure contains a handle to the child structure, but the child structure also contains a handle to + // structure that also contains a handle to the first structure. For instance, in the following example, the + // Unspecified structure definitions are useful when a structure definition contains a handle to a second + // specify its members. + // • An unspecified structure can also be the subject of a later DEFINE STRUCTURE statement that does + // course, cannot be dereferenced either. + // • An unspecified structure cannot be dereferenced, but it can be used to declare a HANDLE which, of + // its members defines an "unspecified structure". + // A DEFINE STRUCTURE statement that merely names the structure to be defined without specifying any of + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.192 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define structure 1 child; + define structure + 1 parent, + 2 first_child handle child, + 2 parent_data fixed bin(31); + define structure + 1 child, + 2 parent handle parent, + 2 next_child handle child, + 2 child_data fixed bin(31); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-21.pli', async () => { + // Context: + // + // of 16 binary digits. + // represents binary floating-point data with a precision + // S + // For example, in the following DECLARE statement, + // The data attributes for declaring binary floating-point variables are BINARY and FLOAT. + // Binary floating-point data + // (4,4) + // .0012 + // (4,0) + // 5280 + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.78 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare S binary float (16); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-20.pli', async () => { + // Context: + // + // represents fixed-point data of 3 digits, 2 of which are fractional. + // D + // The following example specifies that + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 26 + // XN (hex) binary constant + // range -9999999*100 - 9999999*100, in increments of 100. + // holds 7 digits in the + // C + // has a scaling factor of -2. This means that + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.78 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare D decimal fixed real(3,2); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-389.pli', async () => { + // Context: + // + // Combined with DIMACROSS, it can become even easier to add elements to this declaration: + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 270 + // DEFINED and POSITION + // Using INITACROSS, you can simplify this declare by writing it as: + // For example, consider the declaration: + // set of initial values for a structure element in the array. + // attribute specifies a series of comma lists of expressions where each comma list in turn specifies the + // members are scalars in a way that makes it easy to add or delete elements to those arrays. The + // The INITACROSS attribute helps initialize one-dimensional arrays of structures where all the structure + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.322 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 a(*) dimacross + initacross( ( 'DE', 'Germany' ) + ,( 'FE', 'France' ) + ,( 'SP', 'Spain' ) + ) + ,2 b char(2) + ,2 c char(40) var + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-212.pli', async () => { + // Context: + // + // This example is based on the following declaration: + // This example illustrates the difference between the INDFOR attribute and the LIKE attribute. + // Example + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 182 + // Assignments to UNIONs + // the INDFOR attribute is expanded only after all INDFOR attributes have been resolved. + // UNALIGNED attributes are applied to the contained elements of the INDFOR object variable. However, + // The INDFOR attribute is expanded before the defaults are applied and before the ALIGNED and + // attributes are expanded. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.234 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 a, 2 b char(8), 2 c fixed dec(5,0); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-149.pli', async () => { + // Context: + // + // is not. + // Y + // is a valid reference, but + // B + // For example, given the following declares and definitions, + // cannot be referenced by themselves. + // names in a typical untyped structure, the names in a typed structure form their own “name space” and + // You reference a member of a typed structure using the . operator or a handle with the => operator. Unlike + // Typed structure qualification + // Example + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.195 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 A, + 2 B fixed bin, + 2 C fixed bin; + define structure + 1 X, + 2 Y fixed bin, + 2 Z fixed bin; + dcl S type X; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-192.pli', async () => { + // Context: + // + // Consider the following example: + // has bounds of 1 and 8, and its extent is 8. + // List + // three digits. The one dimension of + // is declared as a one-dimensional array of eight elements, each one a fixed-point decimal element of + // List + // Consider the following declaration: + // These examples help you understand declarations of arrays and array dimensions. + // Examples of arrays + // Declaration 2 + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.225 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Table (4,2) fixed dec (3); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-633.pli', async () => { + // Context: + // + // Example + // Name of an ordinal type + // t + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 590 + // BIND + // . + // t + // FIRST returns the first value in the ordinal set + // FIRST + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.642 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define ordinal Color ( Red, + Orange, + Yellow, + Green, + Blue, + Indigo, + Violet ); + display (ordinalname( first(Color) )); /* RED */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-383.pli', async () => { + // Context: + // + // consists of the elements '9.99' of the picture E. + // character string that consists of the elements '999' of the picture E. Z3 is a character-string array that + // Z1 is a character string array that consists of all the elements of the decimal numeric picture E. Z2 is a + // X is a bit string that consists of 40 elements of C, starting at the 20th element. + // Examples + // The base variable must refer to data in connected storage. + // and the base variable must not be subscripted. + // When the defined variable is a bit class aggregate, the POSITION attribute can contain only an integer, + // If the POSITION attribute is omitted, POSITION(1) is the default. + // The expression is evaluated and converted to an integer value at each reference to the defined item. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.318 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL A(20) CHAR(10), + B(10) CHAR(5) DEF (A) POSITION(1); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-382.pli', async () => { + // Context: + // + // X is a bit string that consists of 40 elements of C, starting at the 20th element. + // Examples + // The base variable must refer to data in connected storage. + // and the base variable must not be subscripted. + // When the defined variable is a bit class aggregate, the POSITION attribute can contain only an integer, + // If the POSITION attribute is omitted, POSITION(1) is the default. + // The expression is evaluated and converted to an integer value at each reference to the defined item. + // is the number of characters, bits, graphics, uchars, or widechars in the defined variable. + // where N(b) is the number of characters, bits, graphics, uchars, or widechars in the base variable, and N(d) + // is defined as follows: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.318 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL E PIC'99V.999', + Z1(6) CHAR(1) DEF (E), + Z2 CHAR(3) DEF (E) POS(4), + Z3(4) CHAR(1) DEF (E) POS(2); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-177.pli', async () => { + // Context: + // + // Consider the following example: + // null descriptors). + // • At least one attribute is already present. (The DESCRIPTORS default attributes are not applied to + // same class. + // • The inclusion of any such attributes is not prohibited by the presence of alternative attributes of the + // an explicit entry declaration, if the following conditions are true: + // Specifies that the attributes are included in any parameter descriptors in a parameter descriptor list of + // DESCRIPTORS + // This statement specifies default attributes REAL PICTURE '99999' for all names. + // Specifies all names in the scope of the DEFAULT statement. Consider the following example: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.220 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DEFAULT DESCRIPTORS BINARY; + DCL X ENTRY (FIXED, FLOAT); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-87.pli', async () => { + // Context: + // + // The ENTRY statement can define a secondary entry point to a procedure. Consider the following example: + // of the procedure. + // entry point + // and represents the + // Name + // example, the name of the procedure is + // An application must have exactly one external procedure that has OPTIONS(MAIN). In the following + // statement. A procedure can be a main procedure, a subroutine, or a function. + // A procedure is a sequence of statements delimited by a PROCEDURE statement and a corresponding END + // Procedures + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.145 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Name: procedure; + B: entry; + end Name; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-562.pli', async () => { + // Context: + // + // Example + // does not occur in the buffer, the result is zero. + // x + // If + // is the null string, the result is zero. + // x + // is zero or + // n + // If either the buffer length + // . + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.541 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl cb(128*1024) char(1); + dcl wb(128*1024) widechar(1); + dcl pos fixed bin(31); + /* 128K bytes searched from the right for a numeric */ + pos = memsearchr( addr(cb), stg(cb), '012345789' ); + /* 256K bytes searched from the right for a widechar '0' or '1' */ + pos = memsearchr( addr(wb), stg(wb), '0030_0031'wx ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-563.pli', async () => { + // Context: + // + // Example + // appropriate. + // th position onwards, squeezed and trimmed as + // n + // any collapsing) and then all characters from the + // th character (without + // i + // • The target buffer will include all the characters in the source buffer before the + // • If the target buffer is large enough, the number of bytes that are written to the buffer is returned. + // • If the target buffer is not large enough, a value of -1 is returned. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.542 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl s char(20); + dcl t char(20); + dcl cx fixed bin(31); + + s = '...abc....def...gh..'; + cx = memsqueeze(sysnull(), 0, addr(s), stg(s), '.'); + /* cx = 12 */ + cx = memsqueeze(addr(t), stg(t), addr(s), stg(s), '.'); + /* cx = 12 */ + /* t = '.abc.def.gh.' */ + + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-27.pli', async () => { + // Context: + // + // in this example do compare as equal: + // C + // and + // Z + // To the contrary, + // compare as being equal: + // not + // the same internal hex representation, they do + // determine the length of the string. Consequently, although the strings in the following declarations have + // The null terminator held in a VARYINGZ string is not used in comparisons or assignments, other than to + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.83 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Z char(3) nonvarying init('abc'); + dcl C char(3) varyingz init('abc'); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-692.pli', async () => { + // Context: + // + // Upper limits + // Lower limits + // (continued) + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + // 635 + // Appendix A. Limits   + // Limits + // Upper limits + // Lower limits + // (continued) + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.687 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl lower_01149 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '575870798DA1C0CB'x + || 'CDCECFD0DBDCDDDE'x + ) ); + dcl upper_01149 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '7778807CAD5F4AEB'x + || 'EDEEEF5AFBFCFDFE'x + ) ); + dcl lower_01155 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4951525354555657'x + || '586A709CA1C0CBCD'x + || 'CECFD0DBDDDEE0'x + ) ); + dcl upper_01155 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6971727374757677'x + || '787C809E7B4AEBED'x + || 'EEEF5AFBFDFE7F'x + ) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-214.pli', async () => { + // Context: + // + // twentieth and the twenty-first centuries, it might be declared as follows: + // For example, if a structure is used to hold meteorological data for each month of the year for the + // levels, and members. + // , respectively. The elements of such an array are structures or unions having identical names, + // of unions + // array + // or an + // array of structures + // Specifying the dimension attribute on a structure or union results in an + // Combinations of arrays, structures, and unions + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.237 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Declare 1 Year(1901:2100), + 3 Month(12), + 5 Temperature, + 7 High decimal fixed(4,1), + 7 Low decimal fixed(4,1), + 5 Wind_velocity, + 7 High decimal fixed(3), + 7 Low decimal fixed(3), + 5 Precipitation, + 7 Total decimal fixed(3,1), + 7 Average decimal fixed(3,1), + 3 * char(0); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-215.pli', async () => { + // Context: + // + // are structures: + // B + // and + // A + // contains members that are arrays. In the following example, both + // The need for subscripted qualified references becomes apparent when an array of structures or unions + // qualified reference. + // , which refers to the high temperature in March 1991, is a subscripted + // Temperature.High(1991,3) + // 1991. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.237 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + 1 A (2,2), + 2 B (2), + 3 C fixed bin, + 3 D fixed bin, + 2 E fixed bin; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-286.pli', async () => { + // Context: + // + // The EXIT statement stops the current thread. + // EXIT statement + // For details about the ENTRY statement, see “ENTRY statement” on page 96. + // The ENTRY statement specifies a secondary entry point of a procedure. + // ENTRY statement + // Normal termination of a program occurs when control reaches the END statement of the main procedure. + // If control reaches an END statement for a procedure, it is treated as a RETURN statement. + // “Procedures” on page 94 and “Begin-blocks” on page 112 for more details.) + // the only way to terminate a block's execution, even though each block must have an END statement. (See + // Execution of a block terminates when control reaches the END statement for the block. However, it is not + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.272 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + EXIT + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-329.pli', async () => { + // Context: + // + // Consider the following example: + // The asterisk notation can also be used in a DECLARE statement, but has a different meaning there. + // are all character strings of length 5. + // X + // elements of each generation of + // has bounds (10,20); the second and third generations have bounds (10,10). The + // X + // The first generation of + // Consider the following example: + // dimension of the array, not just one of them. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.294 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Y char(*) ctl, + N fixed bin; + N=20; + allocate Y char(N); + allocate Y; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-194.pli', async () => { + // Context: + // + // its associated name. For example, the items of a payroll record could be declared as follows: + // names are declared with level-numbers greater than 1. A delimiter must separate the level-number and + // A major structure name is declared with the level-number 1. Minor structures, unions, and elementary + // associated names. Level-numbers must be integers. + // A structure is described in a DECLARE statement through the use of level-numbers preceding the + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 176 + // Cross sections of arrays + // represent an elementary variable or an array variable. + // names, which can + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.228 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare 1 Payroll, /* major structure name */ + 2 Name, /* minor structure name */ + 3 Last char(20), /* elementary name */ + 3 First char(15), + 2 Hours, + 3 Regular fixed dec(5,2), + 3 Overtime fixed dec(5,2), + 2 Rate, + 3 Regular fixed dec(3,2), + 3 Overtime fixed dec(3,2); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-317.pli', async () => { + // Context: + // + // interpreted as fixed-point binary. + // is a reference to a piece of storage that contains a value to be + // X + // In the following example, a reference to + // required and how it is interpreted. + // All variables require storage. The attributes specified for a variable describe the amount of storage + // Chapter 9. Storage control + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 236 + // XPROCEDURE + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.288 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X fixed binary(31,0) automatic; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-12.pli', async () => { + // Context: + // + // DECIMAL with a PRECISION of five digits, four to the right of the decimal point: + // has the programmer-defined data attributes of FIXED and + // Pi + // In the following example, the variable + // 1E0 (a decimal floating-point constant). + // fixed-point constant), '1'B (a bit constant), '1' (a character constant), 1B (binary fixed-point constant), or + // The constant 1.0 (a decimal fixed-point constant) is different from the constants 1 (another decimal + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 18 + // Nondata attributes + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.70 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Pi fixed decimal(5,4) initial(3.1416); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-385.pli', async () => { + // Context: + // + // containing the names of the weekdays. + // strings + // varyingz + // is initialized with the addresses of character + // pdays + // In the following example, + // indicated by the TO keyword. + // the address of the string specified in the INITIAL LIST. Also specifies that the string has the attributes + // Use only with static native pointers. Specifies that the pointer (or array of pointers) is initialized with + // INITIAL TO + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.321 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl pdays(7) static ptr init to(varyingz) + ('Sunday', + 'Monday', + 'Tuesday', + 'Wednesday', + 'Thursday', + 'Friday', + 'Saturday' ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-153.pli', async () => { + // Context: + // + // is valid. + // x(1).b(2) + // However, given the following typed structure, only + // Example 2 + // have the same meaning. + // a(1,2).b + // , and + // a.b(1,2) + // , + // a(1).b(2) + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.196 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define structure + 1 t, + 2 b(4) fixed bin, + 2 c(5) fixed bin; + dcl x(3) type t; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-152.pli', async () => { + // Context: + // + // Consider the following example: + // Example 1 + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 144 + // Typed structure qualification + // For details, see “Combinations of arrays, structures, and unions” on page 186. + // structures or unions that have identical names, levels, and members. + // You can specify the dimension attribute on typed structures or unions. The resulting arrays contain + // Combinations of arrays and typed structures or unions + // attribute” on page 142, the following code obtains the system date and displays the time: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.196 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 a(3), + 2 b(4) fixed bin, + 2 c(5) fixed bin; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-31.pli', async () => { + // Context: + // + // false. However, if the window started at 1950, the comparison would return true. + // statement is 'windowed'. This means that if the window started at 1900, the comparison would return + // In the following code fragment, if the DATE attribute is honored, the comparison in the second display + // WINDOW compile-time option. + // you specify in the + // window + // comparable representation. This process converts 2-digit years using the + // Implicit commoning means that the compiler generates code to convert the dates to a common, + // which are discussed later. + // comparand is generally treated as if it had the same DATE attribute, although some exceptions apply + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.93 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl a pic'(6)9' date; + dcl b pic'(6)9' def(a); + dcl c pic'(6)9' date; + dcl d pic'(6)9' def(c); + b = '670101'; + d = '010101'; + display( b || ' < ' || d || ' ?' ); + display( a < c ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-629.pli', async () => { + // Context: + // + // This example is based on the following code fragment: + // Example of using XMLCHAR + // case in which they were declared. + // CASE(ASIS) suboption of the XML compiler option can be used to specify that the names appear in the + // By default the names of the variables in the generated XML output are all in upper case. The + // Note: + // • Leading and trailing blanks are trimmed wherever possible. + // • Numeric and bit data is converted to character. + // • When a variable has the XMLOMIT attribute, the field is omitted if it has a null value. + // structure. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.634 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl buffer char(800); + dcl written fixed bin(31); + dcl next pointer; + dcl left fixed bin(31); + dcl + 1 a, + 2 a1, + 3 b1 char(8), + 3 b2 char(8), + 2 a2, + 3 c1 fixed bin, + 3 c2 fixed dec(5,1); + b1 = ' t1'; + b2 = 't2'; + c1 = 17; + c2 = -29; + next = addr(buffer); + left = stg(buffer); + written = xmlchar( a, next, left ); + next += written; + left -= written; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-291.pli', async () => { + // Context: + // + // This example is based on the following declarations. + // Example + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 224 + // IF + // AND or OR infix operators will also be short-circuited. + // Naturally, an expression formed (possibly recursively) from the above and the NOT prefix operator and the + // – VALIDDATE + // – VALID + // – UNALLOCATED + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.276 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl A bit(1); + dcl B bit(1); + dcl C bit(2); + dcl D bit(2); + dcl P pointer; + dcl BX based fixed bin(31); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-530.pli', async () => { + // Context: + // + // Example 1 + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 448 + // HBOUNDACROSS + // HEXIMAGE built-in function. + // in storage. If an exact image is required, use the + // x + // This function does not return an exact image of + // Note: + // bytes will be converted. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.500 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Sweet char(5) init('Sweet'); + dcl Sixteen fixed bin(31) init(16) littleendian; + dcl XSweet char(size(Sweet)*2+(size(Sweet)-1)/4); + dcl XSixteen char(size(Sixteen)*2+(size(Sixteen)-1)/4); + XSweet = hex(Sweet,'-'); + /* '53776565-74' */ + XSweet = heximage(addr(Sweet),length(Sweet),'-'); + /* '53776565-74' */ + XSixteen = hex(Sixteen,'-'); + /* '00000010' - bytes reversed */ + XSixteen = heximage(addr(Sixteen),stg(Sixteen),'-'); + /* '10000000' - bytes NOT reversed */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-399.pli', async () => { + // Context: + // + // file constants. The file constants can subsequently be assigned to the file variable. + // are declared as + // Acct2 + // and + // Acct1 + // is declared as a file variable, and + // Account + // In the following declaration, + // 46. + // The VARIABLE attribute is implied under the circumstances described in “VARIABLE attribute” on page + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.331 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Account file variable, + Acct1 file, + Acc2 file; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-471.pli', async () => { + // Context: + // + // 329 + // Chapter 14. Picture specification characters   + // Digits and decimal points + // each of which is a digit (0 through 9). See the following example: + // A string of n 9 picture characters specifies that the item is a nonvarying character-string of length n, + // character data because the corresponding character cannot be a blank for character data.) + // 9 picture specification character for numeric character data is different from the specification for + // Specifies that the associated position in the data item contains a decimal digit. (Note that the + // 9 + // decimal values. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.381 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl digit picture'9', + Count picture'999', + XYZ picture '(10)9'; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-183.pli', async () => { + // Context: + // + // BINARY: + // For example, the following statement specifies precision for identifiers already known to be FIXED + // precision for FIXED DECIMAL names is to be (8,3). + // influenced by the default statement, because this statement specifies only that the default + // not + // It is + // If it is not declared explicitly, I is given the language-specified default attributes FIXED BINARY(15,0). + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 170 + // DEFAULT + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.222 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DFT RANGE(*) VALUE(FIXED BINARY(31)); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-236.pli', async () => { + // Context: + // + // This code sums up all the row elements: + // Example 1 + // These examples illustrate the structure assignment using the BY DIMACROSS option. + // Example of assigning a structure using BY DIMACROSS + // The second assignment statement is the same as the following statement: + //  2  + // The first assignment statement is the same as the following statements: + //  1  + //  2  + //  1  + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.257 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 x, + 2 a fixed bin(31), + 2 b fixed bin(31), + 2 c fixed bin(31), + 2 d fixed bin(31); + dcl 1 xa(17) dimacross like x; + dcl jx fixed bin; + x = 0; + do jx = lboundacross( xa ) to hboundacross( xa ); + x = x + xa, by dimacross( jx ); + end; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-209.pli', async () => { + // Context: + // + // would be ambiguous: + // aa3_array + // resolved, otherwise the reference + // The following example is valid, but only because the LIKE references are expanded after they are all + // 181 + // Chapter 7. Data declarations   + // Assignments to UNIONs + // : + // F + // is declared before + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.233 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 aa(30) + ,5 aa1 char( 5) + ,5 aa2 fixed bin(31) + ,5 aa3_array(30) + ,7 aa3_1 fixed dec(15,2) + ,7 aa3_2 fixed dec(15,2) + ,7 aa3_3 fixed dec(11,4) + ,7 aa3_4 fixed dec(7,3) + ; + dcl bb like aa; + dcl cc like + aa3_array; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-208.pli', async () => { + // Context: + // + // : + // F + // is declared before + // E + // and + // C + // is declared before + // B + // The following declarations are valid, but only because + // have the results shown in the following example: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.232 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 a, 2 a1 fixed bin; + dcl 1 b, 2 b1 like a; + dcl 1 c, 2 c1 like b; + + dcl 1 d, 2 d1 fixed bin; + dcl 1 e like d; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-393.pli', async () => { + // Context: + // + // . + // 3.1416 + // is allocated, it is initialized to the value + // Pi + // In the following example, when + // (padded on the right to 10 characters) is assigned to it. + // 'John Doe' + // , the character constant + // Name + // In the following example, when storage is allocated for + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.324 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Pi fixed dec(5,4) init(3.1416); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-392.pli', async () => { + // Context: + // + // (padded on the right to 10 characters) is assigned to it. + // 'John Doe' + // , the character constant + // Name + // In the following example, when storage is allocated for + // These examples illustrate how variables are initialized upon allocation. + // Examples + // the initial values are not assigned; for area variables, the area is not implicitly initialized to EMPTY. + // When storage for based variables is allocated through the ALLOCATE or the AUTOMATIC built-in functions, + // LOCATE statements for based variables), any specified initial value is assigned with each allocation. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.324 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Name char(10) init('John Doe'); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-300.pli', async () => { + // Context: + // + // The %PAGE directive allows you to start a new page in the compiler source listings. + // %PAGE directive + // organization,” on page 89. + // For details about the PACKAGE statement, see “Packages” on page 91 in Chapter 5, “Program + // declarations and procedures contained in the package, unless the names are declared again. + // The PACKAGE statement defines a package. A package forms a name scope that is shared by all + // PACKAGE statement + // For details about the OTHERWISE statement, see “SELECT statement” on page 232. + // preceding WHEN statements fails. + // In a select-group, the OTHERWISE statement specifies the unit to be executed when every test of the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.279 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + %PAGE + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-166.pli', async () => { + // Context: + // + // See the following example: + // to uppercase. + // The environment name must be a character string constant, and is used as is without any translation + // the compilation unit. The environment name is known instead. + // When so specified, the name being declared effectively becomes internal and is not known outside of + // Specifies the name by which the procedure or variable is known outside of the compilation unit. + // environment-name + // : INT for INTERNAL, EXT for EXTERNAL + // Abbreviations + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.206 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X entry external ('koala'); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-28.pli', async () => { + // Context: + // + // Consider the following example: + // converted to an arithmetic value. + // Numeric picture specification describes a character string that can be assigned only data that can be + // fixed-point or floating-point value. + // attribute with a numeric picture specification. The data item is the character representation of a decimal + // A numeric character data item is the value of a variable that has been declared with the PICTURE + // Numeric character data + // • The use of WX can limit the portability of a program. + // '0031'wx (and not as '3100'wx). + // format). So, for example, the widechar value for the character '1' should always be specified as + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.91 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Price picture '999V99'; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-29.pli', async () => { + // Context: + // + // digits, signs, and the location of the assumed decimal point are assigned. Consider the following example: + // arithmetic variable, the editing characters are not included in the assignment operation—only the actual + // assignment operation. However, if a numeric character item is assigned to another numeric character or + // when the item is printed or treated as a character string, the editing characters are included in the + // numeric character data item, and such characters are actually stored within the data item. Consequently, + // arithmetic items or character strings are processed. Editing characters can be specified for insertion into a + // on the decimal point like coded arithmetic data, it is processed differently from the way either coded + // Although numeric character data is in character form, like character strings, and although it is aligned + // automatically, but they require extra processing time. + // be converted either to decimal fixed-point or to decimal floating-point format. Such conversions are done + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.91 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Price picture '$99V.99', + Cost character (6), + Amount fixed decimal (6,2); + Price = 12.28; + Cost = '$12.28'; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-516.pli', async () => { + // Context: + // + // is too short to contain the result. + // y + // This example shows a conversion from graphic to character. However, + // Example 2 + // .A.B.C.D.E.F + // .A.B.C.D.E.F + // .A.B.C.D.E.F + // A is assigned + // Intermediate Result + // For X with value + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.472 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X graphic(6); + dcl A char (12); + A = char(X,11); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-679.pli', async () => { + // Context: + // + // preprocessor output generated is as follows: + // value replaces the function reference and the result is inserted into the preprocessor output. Thus, the + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 624 + // Preprocessor examples + // and returns the concatenated value, that is, the string Z (3), to the point of invocation. The returned + // corresponding parameter. VALUE then performs a concatenation of these arguments and the parentheses + // in a previous assignment statement), and 3 is converted to fixed-point to conform to the attribute of its + // However, before the arguments A and 3 are passed to VALUE, A is replaced by its value Z (assigned to A + // name. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.676 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DECLARE (Z(10),Q) FIXED; + Q = 6+Z( 3); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-191.pli', async () => { + // Context: + // + // Consider the following declaration: + // These examples help you understand declarations of arrays and array dimensions. + // Examples of arrays + // Declaration 2 + // Declaration 1 + // As an example, the following declarations are equivalent: + // built-in functions. + // an array in a BY DIMACROSS assignment or as an argument to the LBOUNDACROSS or HBOUNDACROSS + // attribute is not an array. The children of the variable are arrays. However, the variable might be used as + // Unlike a variable declared with the DIMENSION attribute, a variable declared with the DIMACROSS + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.225 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare List fixed decimal(3) dimension(8); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-380.pli', async () => { + // Context: + // + // V is a two-dimensional array that consists of all the elements in the character string A. + // Examples + // Aggregates of fixed-length widechar variables + // Fixed-length widechar variables + // • The widechar class, which consists of the following variables: + // Aggregates of fixed-length uchar variables + // Fixed-length uchar variables + // • The uchar class, which consists of the following variables: + // Aggregates of fixed-length graphic variables + // Fixed-length graphic variables + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.317 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL B(10) CHAR(1), + W CHAR(10) DEF B; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-528.pli', async () => { + // Context: + // + // contain the result. + // This example shows a conversion from CHARACTER to GRAPHIC. However, the target is too short to + // Example 2 + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 446 + // GRAPHIC + // b is a DBCS blank. + // . + // where + // A is assigned + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.498 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X char (10) varying; + dcl A graphic (8); + A = graphic(X); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-486.pli', async () => { + // Context: + // + // Example 1 + // variable when the ON-unit is established. + // An ON statement that specifies a file variable refers to the file constant that is the current value of the + // ON-units for file variables + // situation, use the following technique: + // to be exceeded, a message is printed and the application is terminated. To avoid a loop caused by this + // raising the ERROR condition again. In any situation where a loop can cause the maximum nesting level + // A loop can occur if an ERROR condition raised in an ERROR ON-unit executes the same ERROR ON-unit, + // environment of the ON-unit in which the condition was raised. + // descendent ON-unit. A normal return from a dynamically descendent ON-unit reestablishes the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.396 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl F file, + G file variable; + G = F; + L1: on endfile(G); + L2: on endfile(F); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-22.pli', async () => { + // Context: + // + // Consider this example: + // The data attributes for declaring decimal floating-point variables are DECIMAL and FLOAT. + // Decimal floating-point data + // ) + // z/OS + // ( + // (109) + // 1Q0b + // ) + // AIX + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.79 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Light_years decimal float(5); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-23.pli', async () => { + // Context: + // + // 15: + // as a variable that can represent character data with a length of + // User + // The following statement declares + // Examples + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 30 + // BIT, CHARACTER, GRAPHIC, UCHAR and WIDECHAR + // See “REFER option (self-defining data)” on page 251 for the description of the REFER option. + // REFER + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.82 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare User character (15); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-115.pli', async () => { + // Context: + // + // applied only for the second parameter. + // Defaults are not applied if an asterisk is specified. For example, in the following declaration, defaults are + // order. + // parameter, but the structuring must be identical. The attributes for a particular level can appear in any + // For a structure-union descriptor, the descriptor level-numbers need not be the same as those of the + // structure-union-descr (structure-union-descriptor) + // See “OPTIONAL attribute” on page 117. + // OPTIONAL + // No conversions are done. + // • OPTIONAL + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.167 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X entry(* optional, aligned); /* defaults applied for 2nd parm */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-548.pli', async () => { + // Context: + // + // Example + // must have the type CHARACTER(1) NONVARYING type. + // z + // Expression. If specified, + // z + // the attributes FIXED BINARY(31,0), it is converted to them. + // does not have + // n + // must have a computational type and should have a character type. If + // n + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.525 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Source char value('One Hundred SCIDS Marks'); + dcl Target char(30); + Target = left (Source, length(Target), '*'); + /* 'One Hundred SCIDS Marks*******' */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-549.pli', async () => { + // Context: + // + // Example + // options, it returns a FIXED BIN(31) value. + // Under the CMPAT(V3) compiler option, LOCATION returns a FIXED BIN(63) value. Under all other CMPAT + // that must have a constant value. + // y + // • The value of a variable + // that must have constant extents. + // y + // • The extent of a variable + // if LOC(x) is used to set either of the following: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.526 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 Table static, + 2 Tab2loc fixed bin(15) nonasgn init(loc(Tab2)), + /* location is 0; gets initialized to 8 */ + 2 Tab3loc fixed bin(15) nonasgn init(loc(Tab3)), + /* location is 2; gets initialized to 808 */ + 2 Length fixed bin nonasgn init(loc(End)), + /* location is 4 */ + 2 * fixed bin, + 2 Tab2(20,20) fixed bin, + /* location is 8 */ + 2 Tab3(20,20) fixed bin, + /* location is 808 */ + 2 F2_loc fixed bin nonasgn init(loc(F2)), + /* location is 1608; gets initialized to 1612 */ + 2 F2_bitloc fixed bin nonasgn init(bitloc(F2)), + /* location is 1610; gets initialized to 1 */ + 2 Flags, /* location is 1612 */ + 3 F1 bit(1), + 3 F2 bit(1), /* bitlocation is 1 */ + 3 F3 bit(1), + 2 Bits(16) bit, /* location is 1613 */ + 2 End char(0); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-436.pli', async () => { + // Context: + // + // list. Consider the following example: + // The variable referenced in the STRING option should not be referenced by name or by alias in the data + // . + // Outprt + // write the record into the file + // are assigned. The WRITE statement specifies that record transmission is used to + // Hours*Rate + // expression + // and of the + // Pay# + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.354 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare S char(8) init('YYMMDD'); + put string (S) edit + (substr (S, 3, 2), '/', + substr (S, 5, 2), '/', + substr (S, 1, 2)) + (A); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-305.pli', async () => { + // Context: + // + // A common use of %PUSH and %POP directives is in included files and macros. + // first-out basis, by using the %POP directive. + // a “push down” stack on a last-in, first-out basis. You can restore this saved status later, also on a last-in, + // The %PUSH directive allows you to save the current status of the %PRINT and %NOPRINT directives in + // %PUSH directive + // The %PROCINC directive is used to override compiler options. + // “%PROCINC directive” on page 229 + // Related information + // The *PROCINC directive is a synonym for the %PROCINC directive. + // *PROCINC directive + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.281 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + %PUSH + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-239.pli', async () => { + // Context: + // + // : + // xa + // This code exchanges the entries in the first and seventeenth columns of + // Example 2 + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 206 + // Multiple assignments + // The assignment inside the loop is equivalent to the following statements: + // This code sums up all the row elements: + // Example 1 + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.258 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 x, + 2 a fixed bin(31), + 2 b fixed bin(31), + 2 c fixed bin(31), + 2 d fixed bin(31); + dcl 1 xa(17) dimacross like x; + dcl y like x; + x = xa, by dimacross( 1 ); + y = xa, by dimacross( 17 ); + xa = y, by dimacross( 1 ); + xa = x, by dimacross( 17 ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-403.pli', async () => { + // Context: + // + // This example illustrates attribute merging for an explicit opening of a file by using a file variable. + // Example of file variable + // PRINT, OUTPUT, and EXTERNAL. + // after implication are STREAM, PRINT, and OUTPUT. Attributes after default application are STREAM, + // Attributes after merge caused by execution of the OPEN statement are STREAM and PRINT. Attributes + // constant. + // This example illustrates attribute merging for an explicit opening of a file that is specified by a file + // Example of file constant + // RECORD + // KEYED + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.336 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Account file variable, + (Acct1,Acct2) file + output; + Account = Acct1; + open file(Account) print; + Account = Acct2; + open file(Account) record unbuf; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-402.pli', async () => { + // Context: + // + // constant. + // This example illustrates attribute merging for an explicit opening of a file that is specified by a file + // Example of file constant + // RECORD + // KEYED + // OUTPUT, STREAM + // PRINT + // RECORD, KEYED + // DIRECT + // RECORD + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.336 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Listing file stream; + open file(Listing) print; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-379.pli', async () => { + // Context: + // + // Examples + // Aggregates of fixed-length widechar variables + // Fixed-length widechar variables + // • The widechar class, which consists of the following variables: + // Aggregates of fixed-length uchar variables + // Fixed-length uchar variables + // • The uchar class, which consists of the following variables: + // Aggregates of fixed-length graphic variables + // Fixed-length graphic variables + // • The graphic class, which consists of the following variables: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.317 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL A CHAR(100), + V(10,10) CHAR(1) DEF A; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-475.pli', async () => { + // Context: + // + // . + // 7.6200 + // , but its arithmetic value is + // '762.00' + // printed, it appears as + // is + // Rate + // In the following example, decimal point alignment during assignment occurs on the character V. If + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 332 + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.384 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Rate picture '9V99.99'; + Rate = 7.62; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-613.pli', async () => { + // Context: + // + // The following are invalid STRING targets: + // The following are valid STRING targets: + // STRINGOFGRAPHIC compiler options specifies that it should be CHARACTER. + // • If any of the base elements have the GRAPHIC type, then the type returned is GRAPHIC unless the + // • If any of the base elements are PICTUREs, then the type returned has CHARACTER type. + // The type of string returned has the same type as one of these base elements with these exceptions: + // • If applied to an array, all elements in the array are subject to the restrictions as described previously. + // – All widechar strings + // – All uchar strings + // – All graphic strings + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.606 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 A, + 2 B bit(8) aligned, + 2 C bit(2), + 2 D bit(8) aligned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-181.pli', async () => { + // Context: + // + // These statements are equivalent to the following declaration: + // Consider the following example: + // integer, and can include the REFER option or can be specified as an asterisk. + // The size of AREA data, or length of BIT, CHARACTER, or GRAPHIC data can be an expression or an + // default of 15). + // attributes of FIXED BINART, but the precision 31 from the VALUE option (rather than the system + // will receive the system default + // I + // I; and DEFAULT RANGE(*) VALUE( FIXED BIN(31) );, the variable + // attributes, but before the system defaults for size, length and precision. So, for example, given DCL + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.221 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DECLARE B FIXED DECIMAL(10), + C FLOAT DECIMAL(14), + A AREA(2000); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-180.pli', async () => { + // Context: + // + // Consider the following example: + // integer, and can include the REFER option or can be specified as an asterisk. + // The size of AREA data, or length of BIT, CHARACTER, or GRAPHIC data can be an expression or an + // default of 15). + // attributes of FIXED BINART, but the precision 31 from the VALUE option (rather than the system + // will receive the system default + // I + // I; and DEFAULT RANGE(*) VALUE( FIXED BIN(31) );, the variable + // attributes, but before the system defaults for size, length and precision. So, for example, given DCL + // These size, length and precision specifications in a VALUE clause are applied after the system default + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.221 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DEFAULT RANGE(A:C) + VALUE (FIXED DEC(10), + FLOAT DEC(14), + AREA(2000)); + DECLARE B FIXED DECIMAL, + C FLOAT DECIMAL, + A AREA; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-375.pli', async () => { + // Context: + // + // Y is a character string that consists of the first 5 characters of B. + // element identified by the subscript expressions L, M, and N. + // A. X2 is a two-dimensional array that consists of the fifth plane of A. X3 is an element that consists of the + // X1 is a three-dimensional array that consists of the first two elements of each row, column and plane of + // Examples + // defined variable is a varying string of the same maximum length. + // A base variable can be, or can contain, a varying string, provided that the corresponding part of the + // In simple defining of an area, the size of the defined area must be equal to the size of the base area. + // the base string. + // In simple defining of a string, the length of the defined string must be less than or equal to the length of + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.316 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL C AREA(500), + Z AREA(500) DEF C; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-374.pli', async () => { + // Context: + // + // element identified by the subscript expressions L, M, and N. + // A. X2 is a two-dimensional array that consists of the fifth plane of A. X3 is an element that consists of the + // X1 is a three-dimensional array that consists of the first two elements of each row, column and plane of + // Examples + // defined variable is a varying string of the same maximum length. + // A base variable can be, or can contain, a varying string, provided that the corresponding part of the + // In simple defining of an area, the size of the defined area must be equal to the size of the base area. + // the base string. + // In simple defining of a string, the length of the defined string must be less than or equal to the length of + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.316 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL B CHAR(10), + Y CHAR(5) DEF B; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-506.pli', async () => { + // Context: + // + // The following example is not a multiple declaration: + // scopes. + // The abbreviations for built-in functions have separate declarations (explicit or contextual) and name + // • Any other qualifications on using the function or pseudovariable + // • A description of any arguments + // • A description of the value returned or, for a pseudovariable, the value set + // • A heading showing the syntax of the reference + // In general, each description has the following format: + // detailed descriptions for each function, subroutine, and pseudovariable. + // This section lists the built-in functions, subroutines, and pseudovariables in alphabetic order and provides + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.452 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl (Dim, Dimension) builtin; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-594.pli', async () => { + // Context: + // + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 538 + // ROUND + // values: + // point instructions are used, these successive roundings of 3.1415926d0 would produce the following + // what a naive user expects. For example, if compiled with USAGE(ROUND(ANS)) and IEEE binary floating + // Note that under USAGE(ROUND(ANS)), the rounding is a base 2 rounding, and the results may not be + // where where b = 2 (=radix(x)) and e = exponent(x): + // Under the compiler option USAGE(ROUND(ANS)), the value of the result is given by the following formula, + // source. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.590 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl x float bin(53) init( 3.1415926d0 ); + display( round(x,1) ); /* 4.000000000000000E+0000 */ + display( round(x,2) ); /* 3.000000000000000E+0000 */ + display( round(x,3) ); /* 3.000000000000000E+0000 */ + display( round(x,4) ); /* 3.250000000000000E+0000 */ + display( round(x,5) ); /* 3.125000000000000E+0000 */ + display( round(x,6) ); /* 3.125000000000000E+0000 */ + display( round(x,7) ); /* 3.156250000000000E+0000 */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-479.pli', async () => { + // Context: + // + // Consider the following example: + // represents negative values. The T can appear anywhere a '9' picture specification character occurs. + // 337 + // Chapter 14. Picture specification characters   + // Credit, debit, overpunched and zero replacement + // the input data represents positive values, and one of the characters } through R if the input data + // On output, T specifies that the associated position contains one of the characters { through I if + // values, and that the characters } through R represent negative values. + // On input, T specifies that the characters { through I and the digits 0 through 9 represent positive + // T + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.389 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Credit picture 'ZZV9T'; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-478.pli', async () => { + // Context: + // + // Consider the following example: + // character (-). The rules are identical to those for the currency symbol. + // Specifies the plus sign character (+) if the data value is >=0; otherwise, it specifies the minus sign + // S + // symbols” on page 333. + // For information about specifying a character as a currency symbol, refer to “Defining currency + // . + // 12.45 + // . Its arithmetic value is + // '$12.45' + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.386 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Root picture 'S999'; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-94.pli', async () => { + // Context: + // + // entry variable that is used in a procedure reference, as in the following example: + // ) can also be assigned to an + // Readin + // . The entry constant ( + // statement-3 + // and execution begins with + // Errt + // 99 + // Chapter 5. Program organization   + // Procedure activation + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.151 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Readin entry, + Ent1 entry variable; + Ent1 = Readin; + call Ent1; + call Readin; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-299.pli', async () => { + // Context: + // + // OTHERWISE statements. + // execution. It is often used to denote null action for THEN and ELSE clauses and for WHEN and + // The null statement causes no operation to be performed and does not modify sequential statement + // null statement + // 227 + // Chapter 8. Statements and directives   + // %NOPRINT + // the setting of various compiler options. + // Generated messages of severity S, E, or W might cause termination of compilation, depending upon + // Generated messages of severity U cause immediate termination of preprocessing and compilation. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.279 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-302.pli', async () => { + // Context: + // + // The %PRINT directive causes printing of the source listings to be resumed. + // %PRINT directive + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 228 + // null + // For an example, see “%PUSH directive” on page 230. + // The most common use of the %PUSH and %POP directives is in included files and macros. + // the most recent %PUSH directive. + // The %POP directive allows you to restore the status of the %PRINT and %NOPRINT directives saved by + // %POP directive + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.280 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + %PRINT + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-165.pli', async () => { + // Context: + // + // . + // X + // procedure + // , as declared in + // 1 + // is + // B + // . The output for + // 2 + // , which is + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.204 */ + + + X: proc options(main); + dcl (A,B) char(1) init('1'); + call Y; + return; + Y: proc; + dcl 1 C, + 3 A char(1) init('2'); + put data(A,B); + return; + end Y; + end X; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-150.pli', async () => { + // Context: + // + // a type as a variable name as well. + // Type names are also in a separate name space from declared names. Therefore, you can use the name of + // is not. + // Y + // is a valid reference, but + // B + // For example, given the following declares and definitions, + // cannot be referenced by themselves. + // names in a typical untyped structure, the names in a typed structure form their own “name space” and + // You reference a member of a typed structure using the . operator or a handle with the => operator. Unlike + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.195 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define alias Hps pointer; + declare Hps type Hps; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-309.pli', async () => { + // Context: + // + // Qualify blocks can also be nested. For example, you can nest a qualify block inside the block above: + // PAINT.RED, PAINT.ORANGE, and so on. The name of the qualify block must be unique to its block. + // means you can declare a variable as having type PAINT.COLOR and that you can refer to the constants + // The names inside a qualify block must be unique to that block, but not to their containing blocks. This + // etc. + // define PAINT as a qualifier to the ORDINAL type COLOR and as a qualifier to the values RED, ORANGE, + // For example, the statements: + // DECLARE statements in it must specify scalars with the VALUE attribute. + // A qualify block can contain only DECLARE, DEFINE, and QUALIFY statements, and the only valid + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.282 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + paint: qualify; + define ordinal color ( red, orange, yellow ); + depth: qualify; + define ordinal intensity ( high, medium, low ); + end depth; + end paint; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-532.pli', async () => { + // Context: + // + // Example 1 + // HEXIMAGE8 built-in function. + // in storage. If an exact image is required, use the + // x + // This function does not return an exact image of + // Note: + // 449 + // Chapter 18. Built-in functions, pseudovariables, and subroutines   + // HEX8 + // bytes will be converted. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.501 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Sweet char(5) init('Sweet'); + dcl Sixteen fixed bin(31) init(16) littleendian; + dcl XSweet char(size(Sweet)*2+(size(Sweet)-1)/4); + dcl XSixteen char(size(Sixteen)*2+(size(Sixteen)-1)/4); + XSweet = hex8(Sweet,'-'); + /* '53776565-74'a */ + XSweet = heximage8(addr(Sweet),length(Sweet),'-'); + /* '53776565-74'a */ + XSixteen = hex8(Sixteen,'-'); + /* '00000010' - bytes reversed */ + XSixteen = heximage8(addr(Sixteen),stg(Sixteen),'-'); + /* '10000000' - bytes NOT reversed */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-473.pli', async () => { + // Context: + // + // Consider the following example: + // The V character cannot appear more than once in a picture specification. + // specification. This can cause the assigned value to be truncated, if necessary, to an integer. + // of a picture specification of a floating-point decimal value), a V is assumed at the right end of the field + // If no V character appears in the picture specification of a fixed-point decimal value (or in the first field + // condition is raised if enabled.) + // at either end. (If significant digits are truncated on the left, the result is undefined and the SIZE + // aligned on the V character. Therefore, an assigned value can be truncated or extended with zero digits + // fractional value of the assigned value, after modification by the optional scaling factor F(±x), are + // does not specify that an actual decimal point or decimal comma is inserted. The integer value and + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.381 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Value picture 'Z9V999'; + Value = 12.345; + dcl Cvalue char(5); + Cvalue = Value; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-687.pli', async () => { + // Context: + // + // Upper limits + // Lower limits + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + // code page that will be uppercased or lowercased. + // denotes the + // c + // . + // c + // for the supported values of + // upperc + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.682 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl lower_00037 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_00037 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_00273 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424445464748'x + || '4951525354555657'x + || '586A708C8D8E9CC0'x + || 'CBCDCECFD0DBDDDE'x + ) ); + dcl upper_00273 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626465666768'x + || '6971727374757677'x + || '78E080ACADAE9E4A'x + || 'EBEDEEEF5AFBFDFE'x + ) ); + dcl lower_00277 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454648'x + || '4951525354555657'x + || '586A8C8D8EA1C0CB'x + || 'CCCDCECFD0DBDDDE'x + ) ); + dcl upper_00277 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656668'x + || '6971727374757677'x + || '787CACADAEFC7BEB'x + || 'ECEDEEEF5BFBFDFE'x + ) ); + dcl lower_00278 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424445464849'x + || '525354555657586A'x + || '70798C8D8E9CA1C0'x + || 'CBCDCECFD0DBDDDE'x + ) ); + dcl upper_00278 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626465666869'x + || '727374757677787C'x + || '80E0ACADAE9EFC7B'x + || 'EBEDEEEF5BFBFDFE'x + ) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-222.pli', async () => { + // Context: + // + // Example: The usage of the ASSERT COMPARE statement + // that are used in this example. + // The following example shows the usage of the ASSERT COMPARE statement. You must code the routines + // 197 + // Chapter 8. Statements and directives   + // statements. You must code the routines that are used in this example. + // The following example shows the usage of the ASSERT TRUE, ASSERT FALSE and ASSERT UNREACHABLE + // Example: The usage of the ASSERT TRUE, ASSERT FALSE and ASSERT UNREACHABLE statements + // • Any other type, then the strings will be null strings. + // • ORDINALs, then the strings will be their ORDINALNAME values. + // + + const doc: LangiumDocument = await parse(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.249 */ + + + asserts: package; + + main: proc options(main); + + dcl n fixed bin; + + n = 1; + assert compare(n,1); + assert compare(n,2) text("n not equal to 2"); + assert unreachable; + end; + + ibmpasc: + proc( packagename_ptr, procname_ptr, assert_sourceline, + actual_addr, actual_length, + expected_addr, expected_length, + text_addr, text_length ) + ext( '_IBMPASC') + options( byvalue linkage(optlink) ); + + dcl packagename_ptr pointer; + dcl procname_ptr pointer; + dcl assert_sourceline fixed BINARY(31); + dcl actual_addr pointer; + dcl actual_length fixed BINARY(31); + dcl expected_addr pointer; + dcl expected_length fixed BINARY(31); + dcl text_addr pointer; + dcl text_length fixed BINARY(31); + + dcl assert_packagename char(100) var based(packagename_ptr); + dcl assert_procname char(100) var based(procname_ptr); + dcl assert_text char(text_length) based(text_addr); + dcl actual_text char(actual_length) based(actual_addr); + dcl expected_text char(expected_length) + based(expected_addr); + + put skip edit( 'compare code hit on line ', + trim(assert_sourceline), + ' in ', + assert_packagename, + ':', assert_procname ) + ( a ); + + if text_length = 0 then; + else + put skip list( assert_text ); + + if actual_length = 0 then; + else + put skip list( actual_text ); + + if expected_length = 0 then; + else + put skip list( expected_text ); + + end; + end; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-450.pli', async () => { + // Context: + // + // Example 2 + // Output stream: + // Input stream: + // The following example shows data-directed transmission (both input and output). + // Example 1 + // quotation mark contained within the character string is represented by two successive quotation marks. + // For character data, the contents of the character string are written out enclosed in quotation marks. Each + // expression. + // numeric character variable does not represent a valid optionally signed arithmetic constant or a complex + // Data-directed output is not valid for subsequent data-directed input when the character-string value of a + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.358 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl 1 A, + 2 B FIXED, + 2 C, + 3 D FIXED; + A.B = 2; + A.D = 17; + put data (A); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-637.pli', async () => { + // Context: + // + // The preprocessor would produce the output text: + // replacement text and regular text. For example, suppose that the input text is as follows: + // . Such a null statement can be used to concatenate + // %; + // statement when it is specified in the form + // Preprocessor statements should be on separate lines from normal text. The one exception is the null + // delimiters. + // Replacement values must not contain % symbols, unmatched quotation marks, or unmatched comment + // been made. + // insertion of a value into the preprocessor output takes place only after all possible replacements have + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.647 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl BC fixed bin(31); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-196.pli', async () => { + // Context: + // + // and variant parts. For example, records in a client file can be declared as follows: + // Unions can be used to declare variant records that would typically contain a common part, a selector part, + // A union, like a structure, is declared through the use of level-numbers preceding the associated names. + // programmer determines which member is used. + // to the storage required by the largest member. Normally, only one member is used at any time and the + // level are members of the union and occupy the same storage. The storage occupied by the union is equal + // Like a structure, a union can be at any level including level 1. All elements of a union at the next deeper + // 177 + // Chapter 7. Data declarations   + // Unions + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.229 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Declare 1 Client, + 2 Number pic '999999', + 2 Type bit(1), + 2 * bit(7), + 2 Name union, + 3 Individual, + 5 Last_Name char(20), + 5 First_Name union, + 7 First char(15), + 7 Initial char(1), + 3 Company char(35), + 2 * char(0); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-67.pli', async () => { + // Context: + // + // Examples + // • Type functions: BIND, CAST, FIRST, LAST, RESPEC, SIZE, and VALUE + // PROCEDURENAME, RANK, SOURCEFILE, SOURCELINE, and WCHARVAL + // – Miscellaneous functions: BYTE, CHARVAL, COLLATE, INDICATORS, PACKAGENAME, POPCNT, + // STORAGE, and SYSNULL + // – Storage-control functions: BINARYVALUE, LENGTH, NULL, OFFSETVALUE, POINTERVALUE, SIZE, + // LBOUNDACROSS + // – Array-handling functions: DIMACROSS, DIMENSION, HBOUND, HBOUNDACROSS, LBOUND, and + // – Precision-handling + // – Integer manipulation + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.124 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl Max_names fixed bin value (1000), + Name_size fixed bin value (30), + Addr_size fixed bin value (20), + Addr_lines fixed bin value (4); + dcl 1 Name_addr(Max_names), + 2 Name char(Name_size), + 2 * union, + 3 Address char(Addr_lines*Addr_size), /* address */ + 3 addr(Addr_lines) char(Addr_size), + 2 * char(0); + dcl One_Name_addr char(size(Name_addr(1))); /* 1 name/addr*/ + dcl Two_Name_addr char(length(One_Name_addr) + *2); /* 2 name/addrs */ + dcl Name_or_addr char(max(Name_size,Addr_size)) based; + dcl Ar(10) pointer; + dcl Ex entry( dim(lbound(Ar):hbound(Ar)) pointer); + dcl Identical_to_Ar( lbound(Ar):hbound(Ar) ) pointer; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-315.pli', async () => { + // Context: + // + // The STOP statement stops the current application. + // STOP statement + // %PAGE directive is executed in place of the %SKIP directive. + // is greater than the number of lines remaining on the page, the equivalent of a + // n + // the default is 1. If + // is omitted, + // n + // Specifies the number of lines to be skipped. It must be an integer in the range 1 - 999. If + // n + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.285 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + STOP + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-172.pli', async () => { + // Context: + // + // declaration: + // specified for the corresponding parameter in the invoked procedure. For example, consider the following + // If no description list is given in an ENTRY declaration, the attributes for the argument must match those + // alignment attributes are shown in Table 8 on page 21 and Table 7 on page 19. + // precision as indicated in Table 40 on page 168. The language-specified defaults for scope, storage and + // If a precision is not specified in an arithmetic declaration, the DEFAULT compiler option determines the + // with the attributes FIXED BINARY(p,q). + // attributes. Therefore, a declaration with the attributes BINARY(p,q) is always equivalent to a declaration + // If a scaling factor is specified in the precision attribute, the attribute FIXED is applied before any other + // • If DEFAULT(ANS) is in effect, all variables are given the attributes REAL FIXED BINARY(31,0). + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.218 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X entry; + call X( 1 ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-387.pli', async () => { + // Context: + // + // For example, consider the declaration: + // set of initial values for a structure element in the array. + // attribute specifies a series of comma lists of expressions where each comma list in turn specifies the + // members are scalars in a way that makes it easy to add or delete elements to those arrays. The + // The INITACROSS attribute helps initialize one-dimensional arrays of structures where all the structure + // INITACROSS + // in the preceding example, the following assignment is illegal: + // pdays + // in read-only storage and an attempt to change it could result in a protection exception. Given the array + // You should not change a value identified by a pointer initialized with INITIAL TO. The value can be placed + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.321 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 a(3) + ,2 b char(2) + init( 'DE', 'FR', 'SP' ) + ,2 c char(40) var + init( 'Germany', 'France', 'Spain' ) + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-25.pli', async () => { + // Context: + // + // . + // Zuser + // and 16 bytes for + // User + // bytes for + // is null-terminated. The storage allocated is 17 + // Zuser + // , + // User + // a maximum length of 15. However, unlike + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.82 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare User character (15) varying; + declare Zuser character (15) varyingz; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-480.pli', async () => { + // Context: + // + // the following example: + // input data represents negative values; otherwise, it contains one of the digits 0 through 9. Consider + // On output, R specifies that the associated position contains one of the characters } through R if the + // through 9 represent positive values. + // On input, R specifies that the characters } through R represent negative values and the digits 0 + // R + // input data represents positive values; otherwise, it contains one of the digits, 0 through 9. + // On output, I specifies that the associated position contains one of the characters { through I if the + // values. + // On input, I specifies that the characters { through I and the digits 0 through 9 represent positive + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.389 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl X fixed decimal(3); + get edit (x) (P'R99'); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-24.pli', async () => { + // Context: + // + // The following example shows the declaration of a bit variable: + // 15: + // as a variable that can represent character data with a length of + // User + // The following statement declares + // Examples + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 30 + // BIT, CHARACTER, GRAPHIC, UCHAR and WIDECHAR + // See “REFER option (self-defining data)” on page 251 for the description of the REFER option. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.82 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare Symptoms bit (64); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-589.pli', async () => { + // Context: + // + // substring f in the string x will be replaced by the substring t. + // BINARY(31,0). The default value for i is 1. i must be non-negative. If i is 0, all occurrences of the + // be replaced by the substring t. i must have a computational type and is converted to FIXED + // An optional expression that specifies the maximum number of times that the substring f should + // i + // STRINGRANGE condition will be raised if enabled, and the result will be a null character string. + // BINARY(31,0). The default value for n is 1. If n is less than 1 or greater than the length(x), the + // begins searching for the substring f. n must have a computational type and is converted to FIXED + // An optional expression that specifies a location within the string x, from where the compiler + // n + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.587 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl ein char(50) var init( 'reserved from #date# till #date#.' ); + dcl aus char(80) var; + + dcl f char(6); + dcl t char(10); + + f = '#date#'; + t = '2018/05/01'; + + aus = replace( ein, f, t ); + /* 'reserved from 2018/05/01 till #date#.' */ + aus = replace( ein, f, t, 16 ); + /* 'reserved from #date# till 2018/05/01.' */ + aus = replace( ein, f, t, 1, 2 ); + /* 'reserved from 2018/05/01 till 2018/05/01.' */ + aus = replace( ein, f, t, 16, 1 ); + /* 'reserved from #date# till 2018/05/01.' */ + aus = replace( ein, f, t, 1, 0 ); + /* 'reserved from 2018/05/01 till 2018/05/01.' */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-147.pli', async () => { + // Context: + // + // that gets a handle to this typed structure: + // ), and declares the C function + // tm + // The following example defines several named types, a structure type ( + // Example 2 + // previous DEFINE ALIAS statement. See the following example: + // The TYPE attribute can be used in a DEFINE ALIAS statement to specify an alias for a type defined in a + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 142 + // HANDLE attribute + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.194 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define alias int fixed bin(31); + define alias time_t fixed bin(31); + define structure + 1 tm + ,2 tm_sec type int /* seconds after the minute (0-61) */ + ,2 tm_min type int /* minutes after the hour (0-59) */ + ,2 tm_hour type int /* hours since midnight (0-23) */ + ,2 tm_mday type int /* day of the month (1-31) */ + ,2 tm_mon type int /* months since January (0-11) */ + ,2 tm_year type int /* years since 1900 */ + ,2 tm_wday type int /* days since Sunday (0-6) */ + ,2 tm_yday type int /* days since January 1 (0-365) */ + ,2 tm_isdst type int /* Daylight Saving Time flag */ + ; + dcl localtime ext('localtime') + entry( nonasgn byaddr type time_t ) + returns( byvalue handle tm ); + dcl time ext('time') + entry( byvalue pointer ) + returns( byvalue type time_t ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-321.pli', async () => { + // Context: + // + // . PL/I does not resolve this type of declaration dependency. + // Str2 + // , but not for + // Str1 + // allocated is correct for + // either to a restricted expression or to an initialized static variable. In the following example, the length + // be initialized + // N + // If the declare statements are located in the same block, PL/I requires that the variable + // is invoked. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.290 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl N fixed bin (15) init(10), + M fixed bin (15) init(N), + Str1 char(N), + Str2 char(M); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-146.pli', async () => { + // Context: + // + // previous DEFINE ALIAS statement. See the following example: + // The TYPE attribute can be used in a DEFINE ALIAS statement to specify an alias for a type defined in a + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 142 + // HANDLE attribute + // Consider the following code: + // Example 1 + // Specifies the name of a QUALIFY block. + // y + // Specifies the name of a previously defined alias, defined structure, or ordinal type. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.194 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define alias Word fixed bin(31); + define alias Short type word; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-52.pli', async () => { + // Context: + // + // Consider the following example: + // A pseudovariable represents a target field. + // Pseudovariables + // 53 + // Chapter 3. Expressions and references   + // Order of evaluation + // and record I/O statements. + // assignment symbol (in this case A). Assignment to variables can also occur in stream I/O, DO, DISPLAY, + // , the target is the variable on the left of the + // A = B; + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.105 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare A character(10), + B character(30); + substr(A,6,5) = substr(B,20,5); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-690.pli', async () => { + // Context: + // + // Upper limits + // Lower limits + // (continued) + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + // 633 + // Appendix A. Limits   + // Limits + // Upper limits + // Lower limits + // (continued) + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.685 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl lower_00920 char + value( ( + '6162636465666768'x + || '696A6B6C6D6E6F70'x + || '7172737475767778'x + || '797AE0E1E2E3E4E5'x + || 'E6E7E8E9EAEBECED'x + || 'EEEFF0F1F2F3F4F5'x + || 'F6F8F9FAFBFCFE'x + ) ); + dcl upper_00920 char + value( ( + '4142434445464748'x + || '494A4B4C4D4E4F50'x + || '5152535455565758'x + || '595AC0C1C2C3C4C5'x + || 'C6C7C8C9CACBCCCD'x + || 'CECFD0D1D2D3D4D5'x + || 'D6D8D9DADBDCDE'x + ) ); + dcl lower_01026 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4951525354555657'x + || '586A709CA1C0CBCD'x + || 'CECFD0DBDDDEE0'x + ) ); + dcl upper_01026 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6971727374757677'x + || '787C809E7B4AEBED'x + || 'EEEF5AFBFDFE7F'x + ) ); + dcl lower_01047 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_01047 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACBAAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_01140 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_01140 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_01141 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424445464748'x + || '4951525354555657'x + || '586A708C8D8E9CC0'x + || 'CBCDCECFD0DBDDDE'x + ) ); + dcl upper_01141 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626465666768'x + || '6971727374757677'x + || '78E080ACADAE9E4A'x + || 'EBEDEEEF5AFBFDFE'x + ) ); + dcl lower_01142 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454648'x + || '4951525354555657'x + || '586A8C8D8EA1C0CB'x + || 'CCCDCECFD0DBDDDE'x + ) ); + dcl upper_01142 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656668'x + || '6971727374757677'x + || '787CACADAEFC7BEB'x + || 'ECEDEEEF5BFBFDFE'x + ) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-691.pli', async () => { + // Context: + // + // Upper limits + // Lower limits + // (continued) + // Table 88. Supported code page values for LOWERCASE built-in function and UPPERCASE built-in function + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Language Reference + // 634 + // Limits + // Upper limits + // Lower limits + // (continued) + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.686 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl lower_01143 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424445464849'x + || '525354555657586A'x + || '70798C8D8E9CA1C0'x + || 'CBCDCECFD0DBDDDE'x + ) ); + dcl upper_01143 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626465666869'x + || '727374757677787C'x + || '80E0ACADAE9EFC7B'x + || 'EBEDEEEF5BFBFDFE'x + ) ); + dcl lower_01144 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424345464749'x + || '52535556575A6A70'x + || '798C8D8E9CA1C0CB'x + || 'CCCECFD0DBDCDEE0'x + ) ); + dcl upper_01144 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626365666769'x + || '727375767771ED80'x + || 'FDACADAE9E7864EB'x + || 'ECEEEF74FBFCFE68'x + ) ); + dcl lower_01145 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4851525354555657'x + || '586A708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_01145 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6871727374757677'x + || '787B80ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_01146 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_01146 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + dcl lower_01147 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424345464749'x + || '5253555657586A70'x + || '7C8C8D8E9CC0CBCC'x + || 'CDCECFD0DBDCDEE0'x + ) ); + dcl upper_01147 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626365666769'x + || '727375767778FD80'x + || '64ACADAE9E71EBEC'x + || 'EDEEEF74FBFCFE68'x + ) ); + dcl lower_01148 char + value( ( + '8182838485868788'x + || '8991929394959697'x + || '9899A2A3A4A5A6A7'x + || 'A8A9424344454647'x + || '4849515253545556'x + || '5758708C8D8E9CCB'x + || 'CCCDCECFDBDCDDDE'x + ) ); + dcl upper_01148 char + value( ( + 'C1C2C3C4C5C6C7C8'x + || 'C9D1D2D3D4D5D6D7'x + || 'D8D9E2E3E4E5E6E7'x + || 'E8E9626364656667'x + || '6869717273747576'x + || '777880ACADAE9EEB'x + || 'ECEDEEEFFBFCFDFE'x + ) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-216.pli', async () => { + // Context: + // + // Consider the following union: + // member. + // the members requires different alignment and therefore different padding before the beginning of the + // that the first storage locations for each of the members of a union do not overlay each other if each of + // Each of the members, if not a union, is mapped as if it were a member of a structure. This means + // Individual members of a union are mapped the same way as members of the structure. + // Structure and union mapping + // • Storage control and those built-in functions and subroutines that allow structures. + // • Parameters and arguments + // But references to unions or structures that contain unions are limited to the following contexts: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.238 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 A union, + 2 B, + 3 C char(1), + 3 D fixed bin(31), + 2 E, + 3 F char(2), + 3 G fixed bin(31), + 2 H char(8); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-179.pli', async () => { + // Context: + // + // an attribute specification. Consider the following example: + // Attributes that conflict, when applied to a data item, do not necessarily conflict when they appear in + // The INITIAL attribute can be specified. + // the dimension attribute can be applied by default only to explicitly declared names. + // declared explicitly, a subscripted name is contextually declared with the attribute BUILTIN. Therefore, + // Although the DEFAULT statement can specify the dimension attribute for names that have not been + // following example: + // can be specified as an arithmetic constant or an expression and can include the REFER option. See the + // The dimension attribute is allowed, but only as the first item in an attribute specification. The bounds + // 169 + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.221 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DEFAULT RANGE(S) BINARY VARYING; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-178.pli', async () => { + // Context: + // + // following example: + // can be specified as an arithmetic constant or an expression and can include the REFER option. See the + // The dimension attribute is allowed, but only as the first item in an attribute specification. The bounds + // 169 + // Chapter 7. Data declarations   + // DEFAULT + // If FILE is used, it implies the attributes VARIABLE and INTERNAL. + // list of attributes. + // Only those attributes that are necessary to complete the declaration of a data item are taken from the + // range. Attributes in the list can appear in any order and must be separated by blanks. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Language Reference v6.1, pg.221 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DFT RANGE(J) (5); + DFT RANGE(J) (5,5) FIXED; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-271.pli', async () => { + // Context: + // + // The following example shows a procedure-specific message filter control block: + // information back to the compiler indicating how a particular message should be handled. + // The procedure-specific control block contains information about the messages. It is used to pass + // (severity code 4) messages. + // WARNING + // (severity code 8) or + // ERROR + // You can increase the severity of any of the messages but you can decrease the severity only of + // messages. + // The message filtering procedure permits you to either suppress messages or alter the severity of + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.518 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Dcl 1 Uex_MFX native based, + 2 Uex_MFX_Length fixed bin(31), + 2 Uex_MFX_Facility_Id char(3), /* of component writing + message */ + 2 * char(1), + 2 Uex_MFX_Message_no fixed bin(31), + 2 Uex_MFX_Severity fixed bin(15), + 2 Uex_MFX_New_Severity fixed bin(15), /* set by exit proc */ + 2 Uex_MFX_Inserts fixed bin(15), + 2 Uex_MFX_Inserts_Data( 6 refer(Uex_MFX_Inserts) ), + 3 Uex_MFX_Ins_Type fixed bin(7), + 3 Uex_MFX_Ins_Type_Data union unaligned, + 4 * char(8), + 4 Uex_MFX_Ins_Bin8 fixed bin(63), + 4 Uex_MFX_Ins_Bin fixed bin(31), + 4 Uex_MFX_Ins_Str, + 5 Uex_MFX_Ins_Str_Len fixed bin(15), + 5 Uex_MFX_Ins_Str_Addr pointer(32), + 4 Uex_MFX_Ins_Series, + 5 Uex_MFX_Ins_Series_Sep char(1), + 5 Uex_MFX_Ins_Series_Addr pointer(32); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-169.pli', async () => { + // Context: + // + // Table 94. PL/I equivalent for a C file + // What is needed is a pointer (or token) for a file, so this translation can be finessed as follows: + // Table 93. Start of the C declaration for its FILE type + // A C file declaration depends on the platform, but it often starts as follows: + // File type equivalence + // Table 92. Sample enum type equivalence + // . + // stdio.h + // from the C header file + // __device_t + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.400 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define struct 1 file; + define alias file_Handle handle file; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-48.pli', async () => { + // Context: + // + // positions. + // This declaration gives the standard page size, line size, and tabulating + // Table 32. Declaration of PLITABS. + // NONASGN attribute can also be specified when compiling with NORENT. + // recommended that PLITABS should always be declared with the NONASGN attribute, because the + // If compiling with the RENT option, PLITABS must be declared with the NONASGN attribute. It is + // tabs set by the structure, and the Enterprise PL/I library code will not work correctly if this is not true. + // structure must are all valid. This field is supposed to hold the offset to the field specifying the number of + // If your code contains a declare for PLITABS, ensure that the values and the first field in the PLITABS + // information about overriding the tab table, see “Overriding the tab control table” on page 241. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.223 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL 1 PLITABS STATIC EXTERNAL NONASGN, + ( 2 OFFSET INIT (14), + 2 PAGESIZE INIT (60), + 2 LINESIZE INIT (120), + 2 PAGELENGTH INIT (64), + 2 FILL1 INIT (0), + 2 FILL2 INIT (0), + 2 FILL3 INIT (0), + 2 NUMBER_OF_TABS INIT (5), + 2 TAB1 INIT (25), + 2 TAB2 INIT (49), + 2 TAB3 INIT (73), + 2 TAB4 INIT (97), + 2 TAB5 INIT (121)) FIXED BIN (15,0); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-187.pli', async () => { + // Context: + // + // Table 113. Incorrect declaration of qsort + // be declared simply as follows: + // function must not + // qsort + // But because C function pointers are not the same as PL/I ENTRY variables, the C + // Table 112. Sample code to use C qsort function + // following code fragment: + // function could be used with this compare routine to sort an array of integers, as in the + // qsort + // And the C + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.405 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl qsort ext('qsort') + entry( pointer, + fixed bin(31), + fixed bin(31), + entry returns( byvalue fixed bin(31) ) + ) + options( byvalue nodescriptor ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-2.pli', async () => { + // Context: + // + // Consider the following example: + // unprototyped function to a 2-byte FIXED BIN temporary and pass that temporary instead. + // But under NOBIN1ARG, the compiler assigns any 1-byte REAL FIXED BIN argument passed to an + // 25 + // Chapter 1. Using compiler options and facilities   + // Under BIN1ARG, the compiler passes a FIXED BIN argument as is to an unprototyped function. + // unprototyped function. + // This suboption controls how the compiler handles 1-byte REAL FIXED BIN arguments passed to an + // BIN1ARG | NOBIN1ARG + // attribute from a parent. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.81 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl f1 ext entry; + dcl f2 ext entry( fixed bin(15) ); + call f1( 1b ); + call f2( 1b ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-267.pli', async () => { + // Context: + // + // must execute the statement: + // The rules for the restart are the same as for a restart after a system failure. To request the restart, you + // You can request a restart at any point in your program. + // Automatic restart within a program + // automatic step restart without checkpoint processing if another system failure occurs. + // by specifying RD=RNC in the EXEC or JOB statement. By specifying RD=RNC, you are requesting an + // After a system failure occurs, you can still force automatic restart from the beginning of the job step + // of the job step, can still occur if you have specified RD=R in the EXEC or JOB statement. + // If a system failure occurs before any checkpoint has been taken, an automatic restart, from the beginning + // checkpoint if you have specified RD=R (or omitted the RD parameter) in the EXEC or JOB statement. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.512 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + CALL PLIREST; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-283.pli', async () => { + // Context: + // + // The declare for a CMPAT(V3) array descriptor is as follows: + // 469 + // Chapter 26. PL/I descriptors   + // The declare for a CMPAT(V2) array descriptor is as follows: + // The declare for a CMPAT(V1) array descriptor is as follows: + // that the actual upper bound will always match the number of dimensions in the array it describes. + // In the following declares, the upper bound for the arrays is declared as 15, but it should be understood + // Array descriptors + // The possible values for the codepage encoding are defined as follows: + // The declare for a string descriptor under CMPAT(V3) is as follows: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.525 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + 1 dso_v3 based, + 2 dso_v3_rvo fixed bin(63), /* relative virtual origin */ + 2 dso_v3_data(1:15), + 3 dso_v3_stride fixed bin(63), /* multiplier */ + 3 dso_v3_hbound fixed bin(63), /* hbound */ + 3 dso_v3_lbound fixed bin(63); /* lbound */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-137.pli', async () => { + // Context: + // + // string: + // is an input-only CHAR VARYINGZ + // getenv + // In the following declaration, for instance, the first parameter to + // (input-only parameters that can be passed in registers are best declared as BYVALUE). + // This practice is particularly useful for strings and other parameters that cannot be passed in registers + // pass the address of that static area. + // later called with a constant for that parameter, the compiler can put that constant in static storage and + // as NONASSIGNABLE (rather than letting it get the default attribute of ASSIGNABLE). If that procedure is + // If a procedure has a BYADDR parameter that it uses as input only, it is best to declare that parameter + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.369 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl getenv entry( char(*) varyingz nonasgn byaddr, + pointer byaddr ) + returns( native fixed bin(31) optional ) + options( nodescriptor ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-102.pli', async () => { + // Context: + // + // preceded by a PUT statement as follows: + // system prompt by ending your own prompt with a colon. For example, the GET statement could be + // If you include output statements that prompt you for input in your program, you can inhibit the initial + // your program until you enter two or more lines. + // By adding a hyphen to the end of any line that is to continue, you can delay transmission of the data to + // GET statement, a further prompt, which is a plus sign followed by a colon (+:), is displayed. + // enter the required data. If you enter a line that does not contain enough data to complete execution of the + // is executed in the program. The GET statement causes the system to go to the next line. You can then + // You are prompted for input to stream files by a colon (:). You will see the colon each time a GET statement + // to the terminal. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.298 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + PUT SKIP LIST('ENTER NEXT ITEM:'); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-8.pli', async () => { + // Context: + // + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 74 + // But this code would still be valid under NOLAXCTL: + // The following code is illegal under NOLAXCTL: + // with a varying extent, that extent must be specified as an asterisk or as a non-constant expression. + // allocated with a differing extent. NOLAXCTL requires that if a CONTROLLED variable is to be allocated + // Specifying LAXCTL allows a CONTROLLED variable to be declared with a constant extent and yet to be + // LAXCTL | NOLAXCTL + // The default is RULES(LAXCONV). When you specify RULES(NOLAXCONV), the default is ALL. + // Under SOURCE, only those violations that occur in the primary source file are flagged. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.130 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl b bit(n) ctl; + dcl n fixed bin(31) init(8); + alloc b; + alloc b bit(16); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-289.pli', async () => { + // Context: + // + // Table 144. Record types encoded as an ordinal value + // 473 + // Copyright IBM Corp. 1999, 2022 + // Possible record types are encoded as an ordinal value as shown in Table 144 on page 474. + // • Whether the record is continued onto the next record + // • Record type + // The header also has some fields that vary from record to record: + // the number 4. + // A number representing the level of SYSADATA that this file format represents. For this product, it is + // SYSADATA level + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.529 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Define ordinal xin_Rect + (Xin_Rect_Msg value(50), /* Message record */ + Xin_Rect_Fil value(57), /* File record */ + Xin_Rect_Opt value(60), /* Options record */ + Xin_Rect_Sum value(61), /* Summary record */ + Xin_Rect_Rep value(62), /* Replace record */ + Xin_Rect_Src value(63), /* Source record */ + Xin_Rect_Tok value(64), /* Token record */ + Xin_Rect_Sym value(66), /* Symbol record */ + Xin_Rect_Lit value(67), /* Literal record */ + Xin_Rect_Syn value(69), /* Syntax record */ + Xin_Rect_Ord_Type value(80), /* Ordinal type record */ + Xin_Rect_Ord_Elem value(81), /* Ordinal element record */ + Xin_Rect_Ctr value(82) ) /* Counter record */ + prec(15); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-55.pli', async () => { + // Context: + // + // Here is the sample of the PL/I fetched MAIN program: + // Examples + // with DEFAULT(LINKAGE(SYSTEM)). + // OPTIONS(LINKAGE(SYSTEM)) in its ENTRY declaration for the fetched MAIN routine, or be compiled + // • If no parameters are passed to the fetched MAIN program, the fetching program should either specify + // passed char varying string is not parsed for the runtime options. + // messages regarding invalid runtime options. If NOEXECOPS is specified in the fetched MAIN routine, the + // • Avoid passing runtime options because attempts to parse them might produce LE informational + // fetched MAIN routine in the fetching program. + // • You must not specify OPTIONS(ASM) or OPTIONS(NODESCRIPTOR) in the ENTRY declaration for the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.231 */ + + + FMAIN: proc(parm) options(main,noexecops ); + DCL parm char(*) var; + DCL SYSPRINT print; + DCL PLIXOPT CHAR(11) VAR INIT('RPTOPTS(ON)') + STATIC EXTERNAL; + Put skip list("FMAIN parm: "|| parm); + Put skip list("FMAIN finished "); + End FMAIN; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-285.pli', async () => { + // Context: + // + // These are possible values for the dsc_Type field: + // The declare for a descriptor header is as follows: + // type. + // structure, or union). The remaining three bytes are zero unless they are set by the particular descriptor + // Every LE descriptor starts with a 4-byte field. The first byte specifies the descriptor type (scalar, array, + // CMPAT(LE) descriptors + // The declare for a CMPAT(V3) array descriptor is as follows: + // 469 + // Chapter 26. PL/I descriptors   + // The declare for a CMPAT(V2) array descriptor is as follows: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.525 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + dsc_Type_Unset fixed bin(8) value(0), + dsc_Type_Element fixed bin(8) value(2), + dsc_Type_Array fixed bin(8) value(3), + dsc_Type_Structure fixed bin(8) value(4), + dsc_Type_Union fixed bin(8) value(4); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-284.pli', async () => { + // Context: + // + // The declare for a descriptor header is as follows: + // type. + // structure, or union). The remaining three bytes are zero unless they are set by the particular descriptor + // Every LE descriptor starts with a 4-byte field. The first byte specifies the descriptor type (scalar, array, + // CMPAT(LE) descriptors + // The declare for a CMPAT(V3) array descriptor is as follows: + // 469 + // Chapter 26. PL/I descriptors   + // The declare for a CMPAT(V2) array descriptor is as follows: + // The declare for a CMPAT(V1) array descriptor is as follows: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.525 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + 1 dsc_Header based( sysnull() ), + 2 dsc_Type fixed bin(8) unsigned, + 2 dsc_Datatype fixed bin(8) unsigned, + 2 * fixed bin(8) unsigned, + 2 * fixed bin(8) unsigned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-131.pli', async () => { + // Context: + // + // For instance, under RULES(LAXCTL), you can declare a structure as follows: + // that you use the RULES(NOLAXCTL) option to disallow such practice. + // with different extents. However, this coding practice severely impacts performance. It is recommended + // Under RULES(LAXCTL), a CONTROLLED variable can be declared with constant extents and yet allocated + // (NO)LAXCTL + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 308 + // Improving performance + // Specifying RULES(NOGLOBALDO) will cause the compile to flag any code where this is not true. + // It is best that JX be declared in the same PROCEDURE that contains this loop. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.364 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 a controlled, + 2 b char(17), + 2 c char(29); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-11.pli', async () => { + // Context: + // + // members that are not level 1 and are not dot qualified. Consider the following example: + // Specifying RULES(NOLAXQUAL(LOOSE)) causes the compiler to flag any reference to structure + // LOOSE + // excluded from the NOLAXQUAL checking. + // not level 1. References which names start with 'CEE', 'DFH', 'DSN', 'EYU', 'IBM', 'PLI', and 'SQL' are + // Specifying NOLAXQUAL causes the compiler to flag any reference to structure members that are + // LAXQUAL | NOLAXQUAL + // The default is RULES(LAXPUNC). + // flagged with an E-level message; otherwise, it will be flagged with a W-level message. + // parenthesis is meant before the semicolon. Under RULES(NOLAXPUNC), this statement will be + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.133 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 a, + 2 b, + 3 b fixed bin, + 3 c fixed bin; + c = 11; /* would be flagged */ + b.c = 13; /* would not be flagged */ + a.c = 17; /* would not be flagged */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-276.pli', async () => { + // Context: + // + // is declared as follows: + // sample + // For example, suppose that the routine + // address of the string and then the string descriptor itself. + // is still such a pair of pointers. But under the other CMPAT options, the locator/descriptor consists of the + // the second pointer is the address of the descriptor. For strings, under CMPAT(LE), the locator/descriptor + // Except for strings, the locator/descriptor is a pair of pointers. The first pointer is the address of the data; + // descriptor, the address of a locator/descriptor for the argument is passed instead. + // When arguments and their descriptors are passed by locator/descriptor, whenever an argument requires a + // Argument passing by locator/descriptor + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.523 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare sample entry( fixed bin(31), varying char(*) ) + options( byaddr descriptor ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-249.pli', async () => { + // Context: + // + // OSRIN is an zFS file, use the following JCL statement instead: + // ddname + // If the associated + // To run a program by using an OSR in a PDS, you can specify the following DD statement in the JCL: + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 430 + // file into the buffer: + // If the inbound schema file were in an zFS file instead, you could use the following code to read the OSR + // you can increase the initial size of the OSR buffer accordingly. + // following example is in a PDS. The initial size of the OSR buffer is set to 4096. If you have a larger OSR file, + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.486 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + //OSRIN DD DSN=HLQ.XML.OSR(STOCK),DISP=SHR + //OSRIN DD PATH=“/u/HLQ/xml/stock.osr” + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-94.pli', async () => { + // Context: + // + // Table 43. Creating a library member in a PL/I program + // page 228. It copies all the records of the original member except those that contain only blanks. + // The program shown in Table 44 on page 229 updates the member created by the program in Table 43 on + // both can be associated with the same DD statement. + // originally occupied by the member cannot be used again. You must use two files in your PL/I program, but + // the entire member in another part of the library. This is rarely an economic proposition because the space + // To use a PL/I program to add or delete one or more records within a member of a library, you must rewrite + // Example: Updating a library member + // Table 42. Placing a load module in an existing library + // load module in the existing library HPU8.CCLM. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.283 */ + + + //OPT10#3 JOB + //TREX EXEC IBMZCBG + //PLI.SYSIN DD * + NMEM: PROC OPTIONS(MAIN); + DCL IN FILE RECORD SEQUENTIAL INPUT, + OUT FILE RECORD SEQUENTIAL OUTPUT, + P POINTER, + IOFIELD CHAR(80) BASED(P), + EOF BIT(1) INIT('0'B); + OPEN FILE(IN),FILE (OUT); + ON ENDFILE(IN) EOF='1'B; + READ FILE(IN) SET(P); + DO WHILE (¬EOF); + PUT FILE(SYSPRINT) SKIP EDIT (IOFIELD) (A); + WRITE FILE(OUT) FROM(IOFIELD); + READ FILE(IN) SET(P); + END; + CLOSE FILE(IN),FILE(OUT); + END NMEM; + /* + //GO.OUT DD UNIT=SYSDA,DSNAME=HPU8.ALIB(NMEM), + // DISP=(NEW,CATLG),SPACE=(TRK,(1,1,1)), + // DCB=(RECFM=FB,BLKSIZE=3600,LRECL=80) + //GO.IN DD */ +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-309.pli', async () => { + // Context: + // + // Table 162. Declare for the expression kind + // • A prefix op, such as a minus for a negation, will have a child node that describes its operand. + // (and the sibling node of that operand will describe the righthand operator). + // • An infix op, such as a minus for a subtraction, will have a child node that describes its lefthand operand + // expression. Some of these records will have nonzero child nodes; for example: + // The ordinal xin_Exp_Kind identifies the type of an expression for a syntax record that describes an + // • A lexeme record (for the semicolon) + // • A keyword record (for the END keyword) + // The records for the END statement consists of 2 records: + // • A lexeme record (for the semicolon) + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.542 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Define + ordinal + xin_Exp_Kind + ( xin_Exp_Kind_Unset + ,xin_Exp_Kind_Bit_String + ,xin_Exp_Kind_Char_String + ,xin_Exp_Kind_Graphic_String + ,xin_Exp_Kind_Number + ,xin_Exp_Kind_Infix_Op + ,xin_Exp_Kind_Prefix_Op + ,xin_Exp_Kind_Builtin_Rfrnc + ,xin_Exp_Kind_Entry_Rfrnc + ,xin_Exp_Kind_Qualified_Rfrnc + ,xin_Exp_Kind_Unsub_Rfrnc + ,xin_Exp_Kind_Subscripted_Rfrnc + ,xin_Exp_Kind_Type_Func + ,xin_Exp_Kind_Widechar_String + ) prec(8) unsigned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-303.pli', async () => { + // Context: + // + // Table 157. Declare for the token record kind + // The ordinal xin_Tok_Kind identifies the type of the token record. + // Table 156. Declare for a token record + // on which it started and ended. + // recognized by the PL/I compiler. The record also identifies the type of the token plus the column and line + // Each token record assigns a number, called a token index, that is used by later records to refer to a token + // Token records + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 482 + // Table 155. Declare for a source record + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.538 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Define + ordinal + xin_Tok_Kind + ( xin_Tok_Kind_Unset + ,xin_Tok_Kind_Lexeme + ,xin_Tok_Kind_Comment + ,xin_Tok_Kind_Literal + ,xin_Tok_Kind_Identifier + ,xin_Tok_Kind_Keyword + ) prec(8) unsigned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-298.pli', async () => { + // Context: + // + // Consider the following structure: + // • The first child, if any + // • The parent, if any + // • The first sibling, if any + // following: + // If the identifier is part of a structure or union, the symbol record contains a symbol index for each of the + // file and line in which the symbol was declared. + // is indicated by a literal index. Each symbol record contains the file index and source line number for the + // For example, the index can be used as the name of a user variable or constant. The name of the identifier + // refer to the symbol described by this record. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.534 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 a + , 3 b fixed bin + , 3 c fixed bin + , 3 d + , 5 e fixed bin + , 5 f fixed bin + ; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-299.pli', async () => { + // Context: + // + // Table 154. Data type of a variable + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 480 + // The variable's data type is specified by the ordinal shown in Table 154 on page 481. + // specified. + // the symbol index of that variable is specified here. If its position attribute is constant, it is also + // If the variable is declared as defined on another mapped variable that is not an element of an array, + // Defined variables + // symbol index of that variable is specified. + // If the variable is declared as based on another mapped variable that is not an element of an array, the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.536 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define + ordinal + xin_Data_Kind + ( xin_Data_Kind_Unset + ,xin_Data_Kind_Character + ,xin_Data_Kind_Bit + ,xin_Data_Kind_Graphic + ,xin_Data_Kind_Fixed + ,xin_Data_Kind_Float + ,xin_Data_Kind_Picture + ,xin_Data_Kind_Pointer + ,xin_Data_Kind_Offset + ,xin_Data_Kind_Entry + ,xin_Data_Kind_File + ,xin_Data_Kind_Label + ,xin_Data_Kind_Format + ,xin_Data_Kind_Area + ,xin_Data_Kind_Task + ,xin_Data_Kind_Event + ,xin_Data_Kind_Condition + ,xin_Data_Kind_Structure + ,xin_Data_Kind_Union + ,xin_Data_Kind_Descriptor + ,xin_Data_Kind_Ordinal + ,xin_Data_Kind_Handle + ,xin_Data_Kind_Type + ,xin_Data_Kind_Builtin + ,xin_Data_Kind_Generic + ,xin_Data_Kind_Widechar + ) prec(8) unsigned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-101.pli', async () => { + // Context: + // + // Table 49. PL/I structure PLITABS for modifying the preset tab settings + // not be omitted. + // the left margin. The first item in the structure is the offset to the NO_OF_TABS field. The FILL fields must + // TAB1 identifies the position of the second item printed on a line; the first item on a line always starts at + // three tab settings, in positions 30, 60, and 90, and uses the defaults for page size and line size. Note that + // procedure. An example of the PL/I structure is shown in Table 49 on page 242. This example creates + // you must declare to be STATIC EXTERNAL in your MAIN procedure or in a program linked with your MAIN + // To supply this tab table, include a PL/I structure in your source program with the name PLITABS, which + // NONASGN attribute can also be specified when compiling with NORENT. + // recommended that PLITABS should always be declared with the NONASGN attribute, because the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.297 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL 1 PLITABS STATIC EXT NONASGN, + 2 (OFFSET INIT(14), + PAGESIZE INIT(60), + LINESIZE INIT(120), + PAGELENGTH INIT(0), + FILL1 INIT(0), + FILL2 INIT(0), + FILL3 INIT(0), + NO_OF_TABS INIT(3), + TAB1 INIT(30), + TAB2 INIT(60), + TAB3 INIT(90)) FIXED BIN(15,0); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-21.pli', async () => { + // Context: + // + // declared as follows: + // A + // where it would seem to start. For example, consider the AUTOMATIC structure + // The mapping rules of the PL/I language might require that a structure be offset by up to 8 bytes from + // • An "automatic map" that lists, for each block, all AUTOMATIC variables but sorted by hex offset + // • A "static map" that lists all STATIC variables but sorted by hex offset + // However, specifying the MAP option also causes the compiler to produce the following maps: + // This storage offset listing is sorted by block and by variable name, and it also includes only user variables. + // variable. + // The fourth column in the Storage Offset Listing is unlabeled and tells how to find the location of the + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.163 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 A, + 2 B char(2), + 2 C fixed bin(31); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-311.pli', async () => { + // Context: + // + // Table 164. Declare for the lexeme kind + // for instance, as the "concatenate" symbol. + // • In these ordinal names, "dbl" means "double", so that dbl_Vrule is a doubled vertical rule that is used, + // • In these ordinal names, "vrule" means "vertical rule", which is used, for instance, as the "or" symbol. + // The ordinal xin_Lex_Kind identifies the type of a lexeme for a syntax record that describes a lexical unit. + // Table 163. Declare for the number kind + // The ordinal xin_Number_Kind identifies the type of a number for a syntax record that describes a number. + // 487 + // Appendix A. SYSADATA message information   + // Table 162. Declare for the expression kind + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.543 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Define + ordinal + xin_Lex_Kind + ( xin_Lex_Undefined + ,xin_Lex_Period + ,xin_Lex_Colon + ,xin_Lex_Semicolon + ,xin_Lex_Lparen + ,xin_Lex_Rparen + ,xin_Lex_Comma + ,xin_Lex_Equals + ,xin_Lex_Gt + ,xin_Lex_Ge + ,xin_Lex_Lt + ,xin_Lex_Le + ,xin_Lex_Ne + ,xin_Lex_Lctr + ,xin_Lex_Star + ,xin_Lex_Dbl_Colon + ,xin_Lex_Not + ,xin_Lex_Vrule + ,xin_Lex_Dbl_Vrule + ,xin_Lex_And + ,xin_Lex_Dbl_Star + ,xin_Lex_Plus + ,xin_Lex_Minus + ,xin_Lex_Slash + ,xin_Lex_Equals_Gt + ,xin_Lex_Lparen_Colon + ,xin_Lex_Colon_Rparen + ,xin_Lex_Plus_Equals + ,xin_Lex_Minus_Equals + ,xin_Lex_Star_Equals + ,xin_Lex_Slash_Equals + ,xin_Lex_Vrule_Equals + ,xin_Lex_And_Equals + ,xin_Lex_Dbl_Star_Equals + ,xin_Lex_Dbl_Vrule_Equals + ,xin_Lex_Dbl_Slash + ) unsigned prec(16); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-310.pli', async () => { + // Context: + // + // Table 163. Declare for the number kind + // The ordinal xin_Number_Kind identifies the type of a number for a syntax record that describes a number. + // 487 + // Appendix A. SYSADATA message information   + // Table 162. Declare for the expression kind + // • A prefix op, such as a minus for a negation, will have a child node that describes its operand. + // (and the sibling node of that operand will describe the righthand operator). + // • An infix op, such as a minus for a subtraction, will have a child node that describes its lefthand operand + // expression. Some of these records will have nonzero child nodes; for example: + // The ordinal xin_Exp_Kind identifies the type of an expression for a syntax record that describes an + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.543 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Define + ordinal + xin_Number_Kind + ( xin_Number_Kind_Unset + ,xin_Number_Kind_Real_Fixed_Bin + ,xin_Number_Kind_Real_Fixed_Dec + ,xin_Number_Kind_Real_Float_Bin + ,xin_Number_Kind_Real_Float_Dec + ,xin_Number_Kind_Cplx_Fixed_Bin + ,xin_Number_Kind_Cplx_Fixed_Dec + ,xin_Number_Kind_Cplx_Float_Bin + ,xin_Number_Kind_Cplx_Float_Dec + ) prec(8) unsigned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-56.pli', async () => { + // Context: + // + // Here is the sample of the PL/I MAIN program that fetches another PL/I MAIN program: + // Here is the sample of the PL/I fetched MAIN program: + // Examples + // with DEFAULT(LINKAGE(SYSTEM)). + // OPTIONS(LINKAGE(SYSTEM)) in its ENTRY declaration for the fetched MAIN routine, or be compiled + // • If no parameters are passed to the fetched MAIN program, the fetching program should either specify + // passed char varying string is not parsed for the runtime options. + // messages regarding invalid runtime options. If NOEXECOPS is specified in the fetched MAIN routine, the + // • Avoid passing runtime options because attempts to parse them might produce LE informational + // fetched MAIN routine in the fetching program. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.231 */ + + + MainFet: Proc Options(main); + Dcl Parm char(1000) var; + Dcl SYSPRINT print; + Dcl Fmain entry(char(*) var) ; + Put skip list("MainFet: start "); + Parm = 'local-parm'; + Put skip list("MainFet parm: "|| Parm); + Fetch Fmain; + Call Fmain(Parm); + Release Fmain; + Put skip list("MainFet:testcase finished "); + End; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-143.pli', async () => { + // Context: + // + // compiler generates more optimal code for the pair in the union. + // , but the + // b2 + // and + // b1 + // perform the same function as + // b4 + // and + // b3 + // In the following example, the pair of variables + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.372 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl b1 bit(32); + dcl b2 bit(16) def b1; + dcl + 1 * union, + 2 b3 bit(32), + 2 b4 bit(16); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-281.pli', async () => { + // Context: + // + // The declare for a CMPAT(V1) array descriptor is as follows: + // that the actual upper bound will always match the number of dimensions in the array it describes. + // In the following declares, the upper bound for the arrays is declared as 15, but it should be understood + // Array descriptors + // The possible values for the codepage encoding are defined as follows: + // The declare for a string descriptor under CMPAT(V3) is as follows: + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 468 + // The declare for a string descriptor under CMPAT(V1) and CMPAT(V2) is as follows: + // In a string descriptor for a CHARACTER string, the fourth byte encodes the compiler CODEPAGE option. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.524 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + 1 dso_v1 based, + 2 dso_v1_rvo fixed bin(31), /* relative virtual origin */ + 2 dso_v1_data(1:15), + 3 dso_v1_stride fixed bin(31), /* multiplier */ + 3 dso_v1_hbound fixed bin(15), /* hbound */ + 3 dso_v1_lbound fixed bin(15); /* lbound */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-280.pli', async () => { + // Context: + // + // The possible values for the codepage encoding are defined as follows: + // The declare for a string descriptor under CMPAT(V3) is as follows: + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 468 + // The declare for a string descriptor under CMPAT(V1) and CMPAT(V2) is as follows: + // In a string descriptor for a CHARACTER string, the fourth byte encodes the compiler CODEPAGE option. + // In a string descriptor for a nonvarying bit string, the fourth byte gives the bit offset. + // bigendian format). + // is held in littleendian or bigendian format or if the data in a WIDECHAR string is held in littleendian or + // The third byte contains various flags (to indicate, for example, if the string length in a VARYING string + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.524 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define ordinal + ccs_Codepage_Enum + ( ccs_Codepage_01047 value(1) + ,ccs_Codepage_01140 + ,ccs_Codepage_01141 + ,ccs_Codepage_01142 + ,ccs_Codepage_01143 + ,ccs_Codepage_01144 + ,ccs_Codepage_01145 + ,ccs_Codepage_01146 + ,ccs_Codepage_01147 + ,ccs_Codepage_01148 + ,ccs_Codepage_01149 + ,ccs_Codepage_00819 + ,ccs_Codepage_00813 + ,ccs_Codepage_00920 + ,ccs_Codepage_00037 + ,ccs_Codepage_00273 + ,ccs_Codepage_00277 + ,ccs_Codepage_00278 + ,ccs_Codepage_00280 + ,ccs_Codepage_00284 + ,ccs_Codepage_00285 + ,ccs_Codepage_00297 + ,ccs_Codepage_00500 + ,ccs_Codepage_00871 + ,ccs_Codepage_01026 + ,ccs_Codepage_01155 + ) unsigned prec(8); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-135.pli', async () => { + // Context: + // + // For example, under the DEFAULT( NOOVERLAP ) option, the assignment in this example is invalid: + // However, if you use this option, you must ensure that the source and target in assignment do not overlap. + // do not overlap, and it can therefore generate smaller and faster code. + // The DEFAULT(NOOVERALP) option lets the compiler assume that the source and target in an assignment + // NOOVERLAP + // Consequently, if your program logic allows, use DEFAULT(REORDER) to generate superior code. + // their latest values. This effectively prohibits almost all optimization on such variables. + // variables in that block referenced in ON-units (or blocks dynamically descendant from ON-units) have + // The DEFAULT(ORDER) option indicates that the ORDER option is applied to every block, meaning that + // (RE)ORDER + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.367 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl c char(20); + substr(c,2,5) = substr(c,1,5); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-307.pli', async () => { + // Context: + // + // Table 160. Declare for the syntax record kind + // 485 + // Appendix A. SYSADATA message information   + // The ordinal xin_Syn_Kind identifies the type of the syntax record. + // Table 159. Declare for a syntax record (continued) + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 484 + // Table 159. Declare for a syntax record + // Table 158. Node indices assigned to the blocks in a program + // The node indices are assigned to the blocks of the preceding program as follows: + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.541 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Define + ordinal + xin_Syn_Kind + ( xin_Syn_Kind_Unset + ,xin_Syn_Kind_Lexeme + ,xin_Syn_Kind_Asterisk + ,xin_Syn_Kind_Int + ,xin_Syn_Kind_Name + ,xin_Syn_Kind_Expression + ,xin_Syn_Kind_Parenthesized_Expr + ,xin_Syn_Kind_Argument_List + ,xin_Syn_Kind_Keyword + ,xin_Syn_Kind_Proc_Stmt + ,xin_Syn_Kind_Begin_Stmt + ,xin_Syn_Kind_Stmt + ,xin_Syn_Kind_Substmt + ,xin_Syn_Kind_Label + ,xin_Syn_Kind_Invoke_Begin + ,xin_Syn_Kind_Assignment + ,xin_Syn_Kind_Assignment_Byname + ,xin_Syn_Kind_Do_Fragment + ,xin_Syn_Kind_Keyed_List + ,xin_Syn_Kind_Iteration_Factor + ,xin_Syn_Kind_If_Clause + ,xin_Syn_Kind_Else_Clause + ,xin_Syn_Kind_Do_Stmt + ,xin_Syn_Kind_Select_Stmt + ,xin_Syn_Kind_When_Stmt + ,xin_Syn_Kind_Otherwise_Stmt + ,xin_Syn_Kind_Procedure + ,xin_Syn_Kind_Package + ,xin_Syn_Kind_Begin_Block + ,xin_Syn_Kind_Picture + ,xin_Syn_Kind_Raw_Rfrnc + ,xin_Syn_Kind_Generic_Desc + ) prec(8) unsigned; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-128.pli', async () => { + // Context: + // + // . + // field12 + // and + // field11 + // For instance, in the following structure, there is one byte of padding between + // 307 + // Copyright IBM Corp. 1999, 2022 + // Improving performance + // However, padding bytes might be zeroed out. + // structure, and that will usually mean your compilation will be quicker and your code will run much faster. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.363 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 sample ext, + 5 field10 bin fixed(31), + 5 field11 dec fixed(13), + 5 field12 bin fixed(31), + 5 field13 bin fixed(31), + 5 field14 bit(32), + 5 field15 bin fixed(31), + 5 field16 bit(32), + 5 field17 bin fixed(31); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-273.pli', async () => { + // Context: + // + // Code the termination procedure-specific control block as follows: + // message filter procedures and the initialization procedures. + // might also want to write out final statistical reports based on information collected during the error + // You should use the termination procedure to perform any cleanup required, such as closing files. You + // Writing the termination procedure + // Abort compilation + // 16/n + // Reserved for future use + // 8/n + // Reserved for future use + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.520 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Dcl 1 Uex_ISA native based, + 2 Uex_ISA_Length_fixed bin(31); /* storage(Uex_ISA) */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-272.pli', async () => { + // Context: + // + // 463 + // Chapter 25. Using user exits   + // Uex_MFX_Ins_Series_Addr points to this structure: + // The following example shows a procedure-specific message filter control block: + // information back to the compiler indicating how a particular message should be handled. + // The procedure-specific control block contains information about the messages. It is used to pass + // (severity code 4) messages. + // WARNING + // (severity code 8) or + // ERROR + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.519 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 series based, + 2 series_count fixed bin(31), + 2 series_string( 1 refer(series_Count ) ) pointer(32); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-74.pli', async () => { + // Context: + // + // how a DD statement should be associated with the value of a file variable: + // be the same as the value of the file reference. The following example illustrates + // must + // DD statement name + // If the file reference in the statement that explicitly or implicitly opens the file is not a file constant, the + // //DETAIL DD ... + // 3. + // //OLDSAMPL DD ... + // 2. + // //SAMPLE DD ... + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.250 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + DCL PRICES FILE VARIABLE, + RPRICE FILE; + PRICES = RPRICE; + OPEN FILE(PRICES); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-91.pli', async () => { + // Context: + // + // For example, you can use redirection in the following program: + // You can redirect standard input, standard output, and standard error devices to a file. + // Redirecting standard input, output, and error devices under z/OS UNIX + // home directory. + // in the user's + // .profile + // . To set them for a specific user only, add them to the file + // /etc/profile + // the file + // 223 + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.279 */ + + + Hello2: proc options(main); + put list('Hello!'); + end; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-300.pli', async () => { + // Context: + // + // The type of the extent is encoded by the values: + // The type and value of the extent is specified in addition to the symbol index of the returns description. + // String and area variables + // The symbol index of the underlying type is specified. + // Typed variables and handles + // The ordinal type index is specified. + // Ordinal variables + // If the variable has the returns attribute, the symbol index of the returns description is specified. + // Entry variables + // The literal index of the picture specification is specified. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.536 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + ( xin_Extent_Constant value(01) + ,xin_Extent_Star value(02) + ,xin_Extent_Nonconstant value(04) + ,xin_Extent_Refer value(08) + ,xin_Extent_In_Error value(16) + ) + fixed bin; + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-274.pli', async () => { + // Context: + // + // is declared as follows: + // sample + // For example, suppose the routine + // the descriptor list is set to the address of that argument's descriptor. + // descriptor list is set to SYSNULL. For arguments that do require a descriptor, the corresponding pointer in + // of arguments passed. For arguments that do not require a descriptor, the corresponding pointer in the + // This extra argument is a pointer to a list of pointers. The number of entries in this list equals the number + // whenever at least one argument needs a descriptor. + // When arguments and their descriptors are passed with a descriptor list, an extra argument is passed + // Argument passing by descriptor list + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.522 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare sample entry( fixed bin(31), varying char(*) ) + options( byaddr descriptor ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-188.pli', async () => { + // Context: + // + // Table 114. Correct declaration of qsort + // function could be declared as follows: + // qsort + // However, a C function pointer is equivalent to the PL/I type LIMITED ENTRY. Therefore, the C + // only, and so a PL/I ENTRY variable and a C function pointer do not even use the amount of storage. + // as well as an entry point address). But a C function pointer is limited in pointing to a non-nested function + // Recall that a PL/I ENTRY variable might point to a nested function (and thus requires a backchain address + // Table 113. Incorrect declaration of qsort + // be declared simply as follows: + // function must not + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.405 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl qsort ext('qsort') + entry( pointer, + fixed bin(31), + fixed bin(31), + limited entry + returns( byvalue fixed bin(31) ) + ) + options( byvalue nodescriptor ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-220.pli', async () => { + // Context: + // + // as follows: + // For example, to pass a pointer to a singly-linked list of integers, the structure for that list must be declared + // storage. + // • It is recommended to use the RELEASE function to release the fetched routine and its associated + // POINTERs and HANDLEs must have the attributes POINTER(32) and HANDLE(32). + // • If a parameter is a POINTER, HANDLE, or an aggregate containing POINTERs or HANDLEs, then those + // (not array or structure expressions). + // • All array and structure arguments passed to an ENTRY with OPTIONS(AMODE31) must be references + // • Any GOTO statement in one AMODE must not cross over any routines in the opposite AMODE. + // • Any exception that occurs in one AMODE must be handled in that AMODE. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.433 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 list_element based, + 2 list_next pointer(32), + 2 list_int fixed bin(31); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-171.pli', async () => { + // Context: + // + // Table 96. Declarations for filedump program + // are obvious: + // filedump + // Most of the declarations in the INCLUDE file + // Table 95. Sample code to use fopen and fread to dump a file + // 345 + // Chapter 17. ILC with C   + // The code for this program is straightforward: + // . + // fread + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.401 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + define struct 1 file; + define alias file_Handle handle file; + define alias size_t unsigned fixed bin(32); + define alias int signed fixed bin(31); + dcl file type(file_Handle); + dcl read_In fixed bin(31); + dcl buffer char(16); + dcl unprintable char(32) value( substr(collate(),1,32) ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-287.pli', async () => { + // Context: + // + // These are the possible values for the dsc_String_Type field: + //   Enterprise PL/I for z/OS: Enterprise PL/I for z/OS Programming Guide + // 470 + // The declare for a string descriptor is as follows: + // EBCDIC. + // In a string descriptor for a character string, the fourth byte also has a bit indicating if the string data is in + // nonnative format. + // In a string descriptor for a varying string, the fourth byte has a bit indicating if the string length is held in + // CODEPAGE option. + // In a string descriptor for a CHARACTER string, the third byte of the header encodes the compiler + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.526 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + declare + dsc_datatype_unset fixed bin(7) value(0), + dsc_datatype_char_nonvarying fixed bin(7) value(2), + dsc_datatype_char_varyingz fixed bin(7) value(3), + dsc_datatype_char_varying2 fixed bin(7) value(4), + dsc_datatype_char_varying4 fixed bin(7) value(5), + dsc_datatype_bit_nonvarying fixed bin(7) value(6), + dsc_datatype_bit_varying2 fixed bin(7) value(7), + dsc_datatype_bit_varying4 fixed bin(7) value(8), + dsc_datatype_graphic_nonvarying fixed bin(7) value(9), + dsc_datatype_graphic_varyingz fixed bin(7) value(10), + dsc_datatype_graphic_varying2 fixed bin(7) value(11), + dsc_datatype_graphic_varying4 fixed bin(7) value(12), + dsc_datatype_widechar_nonvarying fixed bin(7) value(13), + dsc_datatype_widechar_varyingz fixed bin(7) value(14), + dsc_datatype_widechar_varying2 fixed bin(7) value(15), + dsc_datatype_widechar_varying4 fixed bin(7) value(16), + dsc_datatype_uchar_nonvarying fixed bin(7) value(17), + dsc_datatype_uchar_varyingz fixed bin(7) value(18), + dsc_datatype_uchar_varying2 fixed bin(7) value(19), + dsc_datatype_uchar_varying4 fixed bin(7) value(20); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-215.pli', async () => { + // Context: + // + // PLIXOPT variable as follows: + // runtime option. You can declare the + // XPLINK=ON + // but you must use the PLIXOPT variable to specify the + // are linked with XPLINK and the PL/I modules are not. PL/I can still link to and call XPLINK libraries + // Because this PL/I sample program calls Java, the program must link to the Java library. The Java libraries + // This section applies to 31-bit only. + // Note: + // Linking the PL/I program with the Java library + // include files are provided in the PL/I SIBMZSAM data set. + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.424 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + Dcl PLIXOPT Char(40) Varying Ext Static Init( 'XPLINK(ON)'e ); + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); + +test('Block block-12.pli', async () => { + // Context: + // + // members that do not include the level-1 name. Consider the following example: + // Specifying RULES(NOLAXQUAL(STRICT)) causes the compiler to flag any reference to structure + // STRICT + // members that are not level 1 and are not dot qualified. Consider the following example: + // Specifying RULES(NOLAXQUAL(LOOSE)) causes the compiler to flag any reference to structure + // LOOSE + // excluded from the NOLAXQUAL checking. + // not level 1. References which names start with 'CEE', 'DFH', 'DSN', 'EYU', 'IBM', 'PLI', and 'SQL' are + // Specifying NOLAXQUAL causes the compiler to flag any reference to structure members that are + // LAXQUAL | NOLAXQUAL + // + + const doc: LangiumDocument = await parseStmts(` /* Enterprise PL/I for z/OS Programming Guide v6.1, pg.133 */ + + MAINTP: PROCEDURE OPTIONS (MAIN); + + dcl + 1 a, + 2 b, + 3 b fixed bin, + 3 c fixed bin; + c = 11; /* would be flagged */ + b.c = 13; /* would be flagged */ + a.c = 17; /* would not be flagged */ + END MAINTP; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); +}); diff --git a/packages/language/test/linking.test.ts b/packages/language/test/linking.test.ts new file mode 100644 index 0000000..0c0fb07 --- /dev/null +++ b/packages/language/test/linking.test.ts @@ -0,0 +1,71 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { describe, test } from "vitest"; + +describe('Validating', () => { + + test('empty test', () => { + }); +}); +// import { afterEach, beforeAll, describe, expect, test } from "vitest"; +// import { EmptyFileSystem, type LangiumDocument } from "langium"; +// import { expandToString as s } from "langium/generate"; +// import { clearDocuments, parseHelper } from "langium/test"; +// import type { Model } from "pl-one-language"; +// import { createPl1Services, isModel } from "pl-one-language"; +// +// let services: ReturnType; +// let parse: ReturnType>; +// let document: LangiumDocument | undefined; +// +// beforeAll(async () => { +// services = createPl1Services(EmptyFileSystem); +// parse = parseHelper(services.Pl1); +// +// // activate the following if your linking test requires elements from a built-in library, for example +// // await services.shared.workspace.WorkspaceManager.initializeWorkspace([]); +// }); +// +// afterEach(async () => { +// document && clearDocuments(services.shared, [ document ]); +// }); +// +// describe('Linking tests', () => { +// +// test('linking of greetings', async () => { +// document = await parse(` +// person Langium +// Hello Langium! +// `); +// +// expect( +// // here we first check for validity of the parsed document object by means of the reusable function +// // 'checkDocumentValid()' to sort out (critical) typos first, +// // and then evaluate the cross references we're interested in by checking +// // the referenced AST element as well as for a potential error message; +// checkDocumentValid(document) +// || document.parseResult.value.greetings.map(g => g.person.ref?.name || g.person.error?.message).join('\n') +// ).toBe(s` +// Langium +// `); +// }); +// }); +// +// function checkDocumentValid(document: LangiumDocument): string | undefined { +// return document.parseResult.parserErrors.length && s` +// Parser errors: +// ${document.parseResult.parserErrors.map(e => e.message).join('\n ')} +// ` +// || document.parseResult.value === undefined && `ParseResult is 'undefined'.` +// || !isModel(document.parseResult.value) && `Root AST object is a ${document.parseResult.value.$type}, expected a 'Model'.` +// || undefined; +// } diff --git a/packages/language/test/parsing.test.ts b/packages/language/test/parsing.test.ts new file mode 100644 index 0000000..9e9069d --- /dev/null +++ b/packages/language/test/parsing.test.ts @@ -0,0 +1,615 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { beforeAll, describe, expect, test } from "vitest"; +import { EmptyFileSystem, type LangiumDocument } from "langium"; +import { parseHelper } from "langium/test"; +import type { PliProgram } from "pl-one-language"; +import { createPliServices } from "pl-one-language"; + +let services: ReturnType; +let parse: ReturnType>; +let parseStmts: ReturnType>; + +beforeAll(async () => { + services = createPliServices(EmptyFileSystem); + parse = parseHelper(services.pli); + + /** + * Helper function to parse a string of PL/I statements, + * wrapping them in a procedure to ensure they are valid + */ + parseStmts = (input: string) => { + return parse(` STARTPR: PROCEDURE OPTIONS (MAIN); +${input} + end STARTPR;`); + } + + // activate the following if your linking test requires elements from a built-in library, for example + await services.shared.workspace.WorkspaceManager.initializeWorkspace([]); +}); + +describe('PL/I Parsing tests', () => { + + // // Handle as validation error + // test.fails('empty program', async () => { + // const doc: LangiumDocument = await parse(``); + // expect(doc.parseResult.lexerErrors).toHaveLength(0); + // expect(doc.parseResult.parserErrors).toHaveLength(0); + // }); + + test('empty program w/ null statement', async () => { + const doc: LangiumDocument = await parseStmts(`;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + // TODO @montymxb this should pass according to the docs, but doesn't work in practice + // test('empty program w/ null %statement', async () => { + // const doc: LangiumDocument = await parseStmts(`%;`); + // expect(doc.parseResult.lexerErrors).toHaveLength(0); + // expect(doc.parseResult.parserErrors).toHaveLength(0); + // }); + + test('Hello World Program', async () => { + const doc = await parse(` + AVERAGE: PROCEDURE OPTIONS (MAIN); + /* Test characters: ^[] € */ + /* AVERAGE_GRADE = SUM / 5; */ + PUT LIST ('PROGRAM TO COMPUTE AVERAGE'); + END AVERAGE;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + describe('Procedures', () => { + test('Simple procedure', async () => { + const doc: LangiumDocument = await parse(` + P1: procedure; + end P1;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Procedure w/ alternate entry point', async () => { + const doc: LangiumDocument = await parseStmts(` + P1: procedure; + B: entry; // secondary entry point into this procedure + end P1;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Procedure with call', async () => { + const doc: LangiumDocument = await parse(` + Control: procedure options(main); + call A('ok'); // invoke the 'A' subroutine + end Control; + A: procedure (VAR1); + declare VAR1 char(3); + put skip list(VAR1); + end A;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Simple recursive procedure w/ recursive stated before returns', async () => { + const doc: LangiumDocument = await parseStmts(` + Fact: proc (Input) recursive returns (fixed bin(31)); + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*Fact(Input-1) ); + end Fact;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Simple recursive procedure w/ recursive stated after returns', async () => { + const doc: LangiumDocument = await parseStmts(` + Fact: proc (Input) returns (fixed bin(31)) recursive; + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*Fact(Input-1) ); + end Fact;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Procedures w/ Order & Reorder options', async () => { + const doc: LangiumDocument = await parseStmts(` + P1: proc Options(Order); + end P1; + P2: proc Options( Reorder ); + end P2; + call P1; + call P2;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Procedure w/ Reorder option & Returns', async () => { + const doc: LangiumDocument = await parseStmts(` + Double: proc (Input) Options(Reorder) returns(fixed bin(31)); + declare Input fixed bin(15); + return( Input * 2); + end Double; + declare X fixed bin(31); + X = Double(5);`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Recursive - Returns - Options for a Procedure in various permutations', async () => { + const doc: LangiumDocument = await parseStmts(` + // returns - options - recursive + F1: proc (Input) returns (fixed bin(31)) Options(Order) recursive; + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*F1(Input-1) ); + end F1; + + // options - returns - recursive + F2: proc (Input) Options(Order) returns (fixed bin(31)) recursive; + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*F2(Input-1) ); + end F2; + + // options - recursive - returns + F3: proc (Input) Options(Order) recursive returns (fixed bin(31)); + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*F3(Input-1) ); + end F3; + + // returns - options - recursive + F4: proc (Input) returns (fixed bin(31)) Options(Order) recursive; + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*F4(Input-1) ); + end F4; + + // returns - recursive - options + F5: proc (Input) returns (fixed bin(31)) recursive Options(Order); + dcl Input fixed bin(15); + if Input <= 1 then + return(1); + else + return( Input*F5(Input-1) ); + end F5; + `); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Options Separate by Commas & Spaces', async () => { + const doc: LangiumDocument = await parseStmts(` + P1: proc Options( Order, Reorder, Recursive ); + end P1; + P2: proc Options( Order Reorder Recursive); + end P2; + P3: proc Options(Order Reorder, Recursive ); + end P3; + P4: proc Options(Order, Reorder Recursive); + end P4;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Complex recursive procedure', async () => { + const doc: LangiumDocument = await parse(` + START: procedure options (main); + dcl I fixed bin(15); + I=1; call A; + A: proc recursive; + declare Ev entry variable static; + if I=1 then + do; I=2; + Ev=B; + call A; end; + else call Ev; + B: proc; + go to Out; + end B; + Out: end A; + end Start; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + }); + + // tests for labels + describe('Label Tests', () => { + + test('empty label, null statement', async () => { + const doc: LangiumDocument = await parseStmts(` main:;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Declared label', async () => { + const doc: LangiumDocument = await parseStmts(` declare Label_x label;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Label assignment', async () => { + const doc: LangiumDocument = await parseStmts(` + declare Label_x label; + Label_a:; + Label_x = Label_a; // label assignments + go to Label_x; // jump to label +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + }); + + // tests fro declarations + describe('Declaration tests', () => { + + test('simple char declarations', async () => { + const doc: LangiumDocument = await parseStmts(` + declare UserA character (15); // 15 character var + declare UserB character (15) varying; // varying + declare UserC character (15) varyingz; // varying w/ null termination + declare A char(5) nonvarying init( ('abc' || '00'x) ); // nonvarying w/ init + declare B char(3) varyingz init ( 'abc' ); // not equal to the one before by the way, null term is not used in varyingz for comparisons, even though it's there implicitly + dcl Z char(3) nonvarying init('abc'); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('char declaration w/ overflow assignment', async () => { + const doc: LangiumDocument = await parseStmts(` + declare Subject char(10); + Subject = 'Transformations'; // will truncate the last 5 chars, emitting a warning (but valid nonetheless) +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('arbitrary length char decl', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl VAL char(*) value('Some text that runs on and on'); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('nested quotes char decl', async () => { + const doc: LangiumDocument = await parseStmts(` + declare User1 character (30) init('Shakespeare''s "Hamlet"'); + declare User2 character (30) init("Shakespeare's ""Hamlet"""); + declare User3 character (30) init('/* blah */'); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Bit declarations', async () => { + const doc: LangiumDocument = await parseStmts(` + declare S bit (64); // 64 bit var + declare Code bit(10); + Code = '110011'B; + Code = '1100110000'B; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Format constants', async () => { + const doc: LangiumDocument = await parseStmts(` + Prntexe: format + ( column(20),A(15), column(40),A(15), column(60),A(15) ); + Prntstf: format + ( column(20),A(10), column(35),A(10), column(50),A(10) ); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Attribute declarations', async () => { + const doc: LangiumDocument = await parseStmts(` + declare Account1 file variable, // file var + Account2 file automatic, // file var too + File1 file, // file constant + File2 file; // file constant +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Value List declaration', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl cmonth char(3) + valuelist( 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', + 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec' ); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('value list from declaration', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl 1 a, + 2 b fixed bin value(31), + 2 c fixed bin value(28), + 2 d fixed bin value(30); + dcl x fixed bin valuelistfrom a; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + // Handle as validation error +// test.fails('fails with duplicate value in value list', async () => { +// const doc: LangiumDocument = await parseStmts(` +// dcl 1 a, +// 2 b fixed bin value(31), +// 2 d fixed bin value(31); +// dcl x fixed bin valuelistfrom a; +// `); +// expect(doc.parseResult.lexerErrors).toHaveLength(0); +// expect(doc.parseResult.parserErrors).toHaveLength(0); +// }); + + test.fails('value list is too long to handle in compiler correctly', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl 1 a, 2 b fixed bin value(31), 2 c fixed bin value(28), 2 d fixed bin value(31); + dcl x fixed bin valuelistfrom a; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('value range declaration', async () => { + const doc: LangiumDocument = await parseStmts(` + define alias numeric_month fixed bin(7) valuerange(1,12); + dcl imonth type numeric_month; // must hold a val between 1 & 12 inclusive + dcl cmonth char(3) // must be one of the 12 months listed + valuelist( 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', + 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec' ); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('multi-declaration', async () => { + const doc: LangiumDocument = await parseStmts(` + declare Result bit(3), + A fixed decimal(1), + B fixed binary (15), // precison lower than 15 will trigger a compiler warning, less than storage allows + C character(2), D bit(4); + `); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + }); + + test('pseduovariables', async () => { + // assigns into a sub-section of A from a sub-string of B + const doc: LangiumDocument = await parseStmts(` + declare A character(10), + B character(30); + substr(A,6,5) = substr(B,20,5); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('assignment from multi-declaration', async () => { + const doc: LangiumDocument = await parseStmts(` + declare Result bit(4), + A fixed decimal(1), + B fixed binary (15), + C character(4), D bit(4); + A = 1.0; + B = 2; + C = 'ABCD'; + D = 1; + Result = A + B < C & D; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + describe('Expressions', () => { + + test('Assorted restricted expressions', async () => { + const doc: LangiumDocument = await parseStmts(` + // from pg. 73 + dcl Max_names fixed bin value (1000), + Name_size fixed bin value (30), + Addr_size fixed bin value (20), + Addr_lines fixed bin value (4); + dcl 1 Name_addr(Max_names), + 2 Name char(Name_size), + 2 * union, + 3 Address char(Addr_lines*Addr_size), /* address */ + 3 addr(Addr_lines) char(Addr_size), + 2 * char(0); + dcl One_Name_addr char(size(Name_addr(1))); /* 1 name/addr*/ + dcl Two_Name_addr char(length(One_Name_addr) + *2); /* 2 name/addrs */ + dcl Name_or_addr char(max(Name_size,Addr_size)) based; + dcl Ar(10) pointer; + dcl Ex entry( dim(lbound(Ar):hbound(Ar)) pointer); + dcl Identical_to_Ar( lbound(Ar):hbound(Ar) ) pointer; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Simple arithmetic expressions', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl A fixed bin(15), B fixed bin(15), C fixed bin(15); + A = 5; + B = 10; + C = A + B; + C = A - B; + C = A * B; + C = A / B; + C = A ** B; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Function invocation', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl A fixed bin(15), B fixed bin(15), Y fixed bin(15), X fixed bin(15); + A = 5; + B = 10; + // will warn about dummy args being gend for ADD, but it's valid + Y = ADD(A,B); + X = Y**3+ADD(A,B); + ADD: procedure (v1,v2) returns(byvalue); + dcl (v1,v2) bin float(32); + return(v1+v2); + end ADD; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + }); + + test('Basic branching', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl A bit(4), + D bit(5); + A=1; + D=1; + if A=1 then go to Y; + else go to X; + X:; + Y:; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + describe('Packages', () => { + + test('Package with main routine', async () => { + const doc: LangiumDocument = await parse(` + Package_Demo: Package exports (T); + T: PROCEDURE OPTIONS (MAIN); + END T; + end Package_Demo; +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + }); + + test('simple PUT', async () => { + // output a string to the stdout + const doc: LangiumDocument = await parseStmts(` put skip list('Hello ' || 'World');`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('simple GET', async () => { + // read a string into a variable 'var' + const doc: LangiumDocument = await parseStmts(` + dcl VAR fixed bin(15); + get list(var); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('fetch', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl A entry; + fetch A title('X'); + fetch A; + + declare ProgA entry; + + // fetch & release storage occupied by ProgA + fetch ProgA; + call ProgA; + release ProgA;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('BEGIN block', async () => { + const doc: LangiumDocument = await parseStmts(` + B: begin; + declare A fixed bin(15); + end B;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test.skip('Subscripted entry invocation', async () => { + const doc: LangiumDocument = await parseStmts(` + declare (A,B,C,D,E) entry; + declare F(5) entry variable initial (A,B,C,D,E); + declare I fixed bin(15), + X fixed bin(15), + Y fixed bin(15), + Z fixed bin(15); + do I = 1 to 5; + call F(I) (X,Y,Z); // each entry call gets args x,y,z + end;`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Optional args', async () => { + const doc: LangiumDocument = await parseStmts(` + dcl Vrtn entry ( + fixed bin, + ptr optional, + float, + * optional); + + // valid calls for this entry point + dcl x ptr; + call Vrtn(10, *, 15.5, 'abcd'); + call Vrtn(10, *, 15.5, *); + call Vrtn(10, addr(x), 15.5, *); + call Vrtn(10, *, 15.5); + call Vrtn(10, addr(x), 15.5); +`); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); + + test('Block 27', async () => { + const doc: LangiumDocument = await parseStmts(` + /* Enterprise PL/I for z/OS Language Reference v6.1, pg.59 */ + A = '/* This is a constant, not a comment */' ; + `); + expect(doc.parseResult.lexerErrors).toHaveLength(0); + expect(doc.parseResult.parserErrors).toHaveLength(0); + }); +}); diff --git a/packages/language/test/validating.test.ts b/packages/language/test/validating.test.ts new file mode 100644 index 0000000..a0dd0f8 --- /dev/null +++ b/packages/language/test/validating.test.ts @@ -0,0 +1,82 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { describe, test } from "vitest"; +// import { beforeAll, describe, expect, test } from "vitest"; +// import { EmptyFileSystem, type LangiumDocument } from "langium"; +// import { expandToString as s } from "langium/generate"; +// import { parseHelper } from "langium/test"; +// import type { Diagnostic } from "vscode-languageserver-types"; +// import type { Model } from "pl-one-language"; +// import { createPl1Services, isModel } from "pl-one-language"; +// +// let services: ReturnType; +// let parse: ReturnType>; +// let document: LangiumDocument | undefined; +// +// beforeAll(async () => { +// services = createPl1Services(EmptyFileSystem); +// const doParse = parseHelper(services.Pl1); +// parse = (input: string) => doParse(input, { validation: true }); +// +// // activate the following if your linking test requires elements from a built-in library, for example +// // await services.shared.workspace.WorkspaceManager.initializeWorkspace([]); +// }); +// +describe('Validating', () => { + + test('empty test', () => { + }); + +// +// test('check no errors', async () => { +// document = await parse(` +// person Langium +// `); +// +// expect( +// // here we first check for validity of the parsed document object by means of the reusable function +// // 'checkDocumentValid()' to sort out (critical) typos first, +// // and then evaluate the diagnostics by converting them into human readable strings; +// // note that 'toHaveLength()' works for arrays and strings alike ;-) +// checkDocumentValid(document) || document?.diagnostics?.map(diagnosticToString)?.join('\n') +// ).toHaveLength(0); +// }); +// +// test('check capital letter validation', async () => { +// document = await parse(` +// person langium +// `); +// +// expect( +// checkDocumentValid(document) || document?.diagnostics?.map(diagnosticToString)?.join('\n') +// ).toEqual( +// // 'expect.stringContaining()' makes our test robust against future additions of further validation rules +// expect.stringContaining(s` +// [1:19..1:26]: Person name should start with a capital. +// `) +// ); +// }); +}); +// +// function checkDocumentValid(document: LangiumDocument): string | undefined { +// return document.parseResult.parserErrors.length && s` +// Parser errors: +// ${document.parseResult.parserErrors.map(e => e.message).join('\n ')} +// ` +// || document.parseResult.value === undefined && `ParseResult is 'undefined'.` +// || !isModel(document.parseResult.value) && `Root AST object is a ${document.parseResult.value.$type}, expected a 'Model'.` +// || undefined; +// } +// +// function diagnosticToString(d: Diagnostic) { +// return `[${d.range.start.line}:${d.range.start.character}..${d.range.end.line}:${d.range.end.character}]: ${d.message}`; +// } diff --git a/packages/language/test/validation-messages/errors.test.ts b/packages/language/test/validation-messages/errors.test.ts new file mode 100644 index 0000000..3bde89a --- /dev/null +++ b/packages/language/test/validation-messages/errors.test.ts @@ -0,0 +1,71 @@ +import { EmptyFileSystem } from "langium"; +import { expectIssue, parseHelper } from "langium/test"; +import { beforeAll, describe, test } from "vitest"; +import { createPliServices, PliProgram } from "../../src"; + +describe('Error messages', () => { + let services: ReturnType; + let parse: ReturnType>; + + beforeAll(async () => { + services = createPliServices(EmptyFileSystem); + parse = (input: string) => parseHelper(services.pli)(input, { validation: true }); + await services.shared.workspace.WorkspaceManager.initializeWorkspace([]); + }); + + describe('IBM1295IE Sole bound specified is less than 1', () => { + test.each([[-5], [0]])(`IBM1295IE: Upper bound is %d`, async (upperBound) => { + const document = await parse(` + TEST: PROCEDURE OPTIONS(MAIN) REORDER; + dcl x(${upperBound}) fixed bin; + END TEST; + `); + const diagnostics = document.diagnostics ?? []; + const result = { document, diagnostics, dispose: undefined! }; + expectIssue(result, { + code: 'IBM1295IE' + }); + }); + }); + + test('IBM1324IE the name occurs more than once in the EXPORTS clause', async () => { + const document = await parse(` +0PACK: PACKAGE EXPORTS(TEST, TEST); +0END; + `); + const diagnostics = document.diagnostics ?? []; + const result = { document, diagnostics, dispose: undefined! }; + expectIssue(result, { + code: 'IBM1324IE' + }); + }); + + test('IBM1388IE_NODESCRIPTOR attribute_is_invalid_when_any_parameter_has_NONCONNECTED_attribute', async () => { + const document = await parse(` +0a: proc( x ) options(nodescriptor); + dcl x(20) fixed bin nonconnected; +0end a; + `); + const diagnostics = document.diagnostics ?? []; + const result = { document, diagnostics, dispose: undefined! }; + expectIssue(result, { + code: 'IBM1388IE' + }); + }); + + + test('IBM1747IS_Function_cannot_be_used_before_the_functions_descriptor_list_has_been_scanned', async () => { + const document = await parse(` + TEST: PROCEDURE OPTIONS(MAIN) REORDER; + dcl a char( csize( x, y ) ); + dcl csize entry( char(2), fixed bin ) + returns( fixed bin ); + END TEST; + `); + const diagnostics = document.diagnostics ?? []; + const result = { document, diagnostics, dispose: undefined! }; + expectIssue(result, { + code: 'IBM1747IS' + }); + }); +}); \ No newline at end of file diff --git a/packages/language/tsconfig.json b/packages/language/tsconfig.json new file mode 100644 index 0000000..25c9de5 --- /dev/null +++ b/packages/language/tsconfig.json @@ -0,0 +1,12 @@ +// this file is required for VSCode to work properly +{ + "extends": "./tsconfig.src.json", + "compilerOptions": { + "noEmit": true, + "rootDir": "." + }, + "include": [ + "src/**/*", + "test/**/*" + ] +} diff --git a/packages/language/tsconfig.src.json b/packages/language/tsconfig.src.json new file mode 100644 index 0000000..b95fbed --- /dev/null +++ b/packages/language/tsconfig.src.json @@ -0,0 +1,10 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "rootDir": "src", + "outDir": "out" + }, + "include": [ + "src/**/*.ts", + ] + } diff --git a/packages/language/tsconfig.test.json b/packages/language/tsconfig.test.json new file mode 100644 index 0000000..d13f58d --- /dev/null +++ b/packages/language/tsconfig.test.json @@ -0,0 +1,14 @@ +{ + "extends": "./tsconfig.src.json", + "compilerOptions": { + "noEmit": true, + "rootDir": "test" + }, + "references": [{ + "path": "./tsconfig.src.json" + }], + "include": [ + "test/**/*.ts", + ] + } + \ No newline at end of file diff --git a/packages/vscode-extension/.vscodeignore b/packages/vscode-extension/.vscodeignore new file mode 100644 index 0000000..9118023 --- /dev/null +++ b/packages/vscode-extension/.vscodeignore @@ -0,0 +1,3 @@ +.vscode/** +.vscode-test/** +src/** \ No newline at end of file diff --git a/packages/vscode-extension/LICENSE b/packages/vscode-extension/LICENSE new file mode 100644 index 0000000..d3087e4 --- /dev/null +++ b/packages/vscode-extension/LICENSE @@ -0,0 +1,277 @@ +Eclipse Public License - v 2.0 + + THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE + PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION + OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + + a) in the case of the initial Contributor, the initial content + Distributed under this Agreement, and + + b) in the case of each subsequent Contributor: + i) changes to the Program, and + ii) additions to the Program; + where such changes and/or additions to the Program originate from + and are Distributed by that particular Contributor. A Contribution + "originates" from a Contributor if it was added to the Program by + such Contributor itself or anyone acting on such Contributor's behalf. + Contributions do not include changes or additions to the Program that + are not Modified Works. + +"Contributor" means any person or entity that Distributes the Program. + +"Licensed Patents" mean patent claims licensable by a Contributor which +are necessarily infringed by the use or sale of its Contribution alone +or when combined with the Program. + +"Program" means the Contributions Distributed in accordance with this +Agreement. + +"Recipient" means anyone who receives the Program under this Agreement +or any Secondary License (as applicable), including Contributors. + +"Derivative Works" shall mean any work, whether in Source Code or other +form, that is based on (or derived from) the Program and for which the +editorial revisions, annotations, elaborations, or other modifications +represent, as a whole, an original work of authorship. + +"Modified Works" shall mean any work in Source Code or other form that +results from an addition to, deletion from, or modification of the +contents of the Program, including, for purposes of clarity any new file +in Source Code form that contains any contents of the Program. Modified +Works shall not include works that contain only declarations, +interfaces, types, classes, structures, or files of the Program solely +in each case in order to link to, bind by name, or subclass the Program +or Modified Works thereof. + +"Distribute" means the acts of a) distributing or b) making available +in any manner that enables the transfer of a copy. + +"Source Code" means the form of a Program preferred for making +modifications, including but not limited to software source code, +documentation source, and configuration files. + +"Secondary License" means either the GNU General Public License, +Version 2.0, or any later versions of that license, including any +exceptions or additional permissions as identified by the initial +Contributor. + +2. GRANT OF RIGHTS + + a) Subject to the terms of this Agreement, each Contributor hereby + grants Recipient a non-exclusive, worldwide, royalty-free copyright + license to reproduce, prepare Derivative Works of, publicly display, + publicly perform, Distribute and sublicense the Contribution of such + Contributor, if any, and such Derivative Works. + + b) Subject to the terms of this Agreement, each Contributor hereby + grants Recipient a non-exclusive, worldwide, royalty-free patent + license under Licensed Patents to make, use, sell, offer to sell, + import and otherwise transfer the Contribution of such Contributor, + if any, in Source Code or other form. This patent license shall + apply to the combination of the Contribution and the Program if, at + the time the Contribution is added by the Contributor, such addition + of the Contribution causes such combination to be covered by the + Licensed Patents. The patent license shall not apply to any other + combinations which include the Contribution. No hardware per se is + licensed hereunder. + + c) Recipient understands that although each Contributor grants the + licenses to its Contributions set forth herein, no assurances are + provided by any Contributor that the Program does not infringe the + patent or other intellectual property rights of any other entity. + Each Contributor disclaims any liability to Recipient for claims + brought by any other entity based on infringement of intellectual + property rights or otherwise. As a condition to exercising the + rights and licenses granted hereunder, each Recipient hereby + assumes sole responsibility to secure any other intellectual + property rights needed, if any. For example, if a third party + patent license is required to allow Recipient to Distribute the + Program, it is Recipient's responsibility to acquire that license + before distributing the Program. + + d) Each Contributor represents that to its knowledge it has + sufficient copyright rights in its Contribution, if any, to grant + the copyright license set forth in this Agreement. + + e) Notwithstanding the terms of any Secondary License, no + Contributor makes additional grants to any Recipient (other than + those set forth in this Agreement) as a result of such Recipient's + receipt of the Program under the terms of a Secondary License + (if permitted under the terms of Section 3). + +3. REQUIREMENTS + +3.1 If a Contributor Distributes the Program in any form, then: + + a) the Program must also be made available as Source Code, in + accordance with section 3.2, and the Contributor must accompany + the Program with a statement that the Source Code for the Program + is available under this Agreement, and informs Recipients how to + obtain it in a reasonable manner on or through a medium customarily + used for software exchange; and + + b) the Contributor may Distribute the Program under a license + different than this Agreement, provided that such license: + i) effectively disclaims on behalf of all other Contributors all + warranties and conditions, express and implied, including + warranties or conditions of title and non-infringement, and + implied warranties or conditions of merchantability and fitness + for a particular purpose; + + ii) effectively excludes on behalf of all other Contributors all + liability for damages, including direct, indirect, special, + incidental and consequential damages, such as lost profits; + + iii) does not attempt to limit or alter the recipients' rights + in the Source Code under section 3.2; and + + iv) requires any subsequent distribution of the Program by any + party to be under a license that satisfies the requirements + of this section 3. + +3.2 When the Program is Distributed as Source Code: + + a) it must be made available under this Agreement, or if the + Program (i) is combined with other material in a separate file or + files made available under a Secondary License, and (ii) the initial + Contributor attached to the Source Code the notice described in + Exhibit A of this Agreement, then the Program may be made available + under the terms of such Secondary Licenses, and + + b) a copy of this Agreement must be included with each copy of + the Program. + +3.3 Contributors may not remove or alter any copyright, patent, +trademark, attribution notices, disclaimers of warranty, or limitations +of liability ("notices") contained within the Program from any copy of +the Program which they Distribute, provided that Contributors may add +their own appropriate notices. + +4. COMMERCIAL DISTRIBUTION + +Commercial distributors of software may accept certain responsibilities +with respect to end users, business partners and the like. While this +license is intended to facilitate the commercial use of the Program, +the Contributor who includes the Program in a commercial product +offering should do so in a manner which does not create potential +liability for other Contributors. Therefore, if a Contributor includes +the Program in a commercial product offering, such Contributor +("Commercial Contributor") hereby agrees to defend and indemnify every +other Contributor ("Indemnified Contributor") against any losses, +damages and costs (collectively "Losses") arising from claims, lawsuits +and other legal actions brought by a third party against the Indemnified +Contributor to the extent caused by the acts or omissions of such +Commercial Contributor in connection with its distribution of the Program +in a commercial product offering. The obligations in this section do not +apply to any claims or Losses relating to any actual or alleged +intellectual property infringement. In order to qualify, an Indemnified +Contributor must: a) promptly notify the Commercial Contributor in +writing of such claim, and b) allow the Commercial Contributor to control, +and cooperate with the Commercial Contributor in, the defense and any +related settlement negotiations. The Indemnified Contributor may +participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial +product offering, Product X. That Contributor is then a Commercial +Contributor. If that Commercial Contributor then makes performance +claims, or offers warranties related to Product X, those performance +claims and warranties are such Commercial Contributor's responsibility +alone. Under this section, the Commercial Contributor would have to +defend claims against the other Contributors related to those performance +claims and warranties, and if a court requires any other Contributor to +pay any damages as a result, the Commercial Contributor must pay +those damages. + +5. NO WARRANTY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, AND TO THE EXTENT +PERMITTED BY APPLICABLE LAW, THE PROGRAM IS PROVIDED ON AN "AS IS" +BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR +IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF +TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR +PURPOSE. Each Recipient is solely responsible for determining the +appropriateness of using and distributing the Program and assumes all +risks associated with its exercise of rights under this Agreement, +including but not limited to the risks and costs of program errors, +compliance with applicable laws, damage to or loss of data, programs +or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY + +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, AND TO THE EXTENT +PERMITTED BY APPLICABLE LAW, NEITHER RECIPIENT NOR ANY CONTRIBUTORS +SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST +PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE +EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under +applicable law, it shall not affect the validity or enforceability of +the remainder of the terms of this Agreement, and without further +action by the parties hereto, such provision shall be reformed to the +minimum extent necessary to make such provision valid and enforceable. + +If Recipient institutes patent litigation against any entity +(including a cross-claim or counterclaim in a lawsuit) alleging that the +Program itself (excluding combinations of the Program with other software +or hardware) infringes such Recipient's patent(s), then such Recipient's +rights granted under Section 2(b) shall terminate as of the date such +litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it +fails to comply with any of the material terms or conditions of this +Agreement and does not cure such failure in a reasonable period of +time after becoming aware of such noncompliance. If all Recipient's +rights under this Agreement terminate, Recipient agrees to cease use +and distribution of the Program as soon as reasonably practicable. +However, Recipient's obligations under this Agreement and any licenses +granted by Recipient relating to the Program shall continue and survive. + +Everyone is permitted to copy and distribute copies of this Agreement, +but in order to avoid inconsistency the Agreement is copyrighted and +may only be modified in the following manner. The Agreement Steward +reserves the right to publish new versions (including revisions) of +this Agreement from time to time. No one other than the Agreement +Steward has the right to modify this Agreement. The Eclipse Foundation +is the initial Agreement Steward. The Eclipse Foundation may assign the +responsibility to serve as the Agreement Steward to a suitable separate +entity. Each new version of the Agreement will be given a distinguishing +version number. The Program (including Contributions) may always be +Distributed subject to the version of the Agreement under which it was +received. In addition, after a new version of the Agreement is published, +Contributor may elect to Distribute the Program (including its +Contributions) under the new version. + +Except as expressly stated in Sections 2(a) and 2(b) above, Recipient +receives no rights or licenses to the intellectual property of any +Contributor under this Agreement, whether expressly, by implication, +estoppel or otherwise. All rights in the Program not expressly granted +under this Agreement are reserved. Nothing in this Agreement is intended +to be enforceable by any entity that is not a Contributor or Recipient. +No third-party beneficiary rights are created under this Agreement. + +Exhibit A - Form of Secondary Licenses Notice + +"This Source Code may also be made available under the following +Secondary Licenses when the conditions for such availability set forth +in the Eclipse Public License, v. 2.0 are satisfied: {name license(s), +version(s), and exceptions or additional permissions here}." + + Simply including a copy of this Agreement, including this Exhibit A + is not sufficient to license the Source Code under Secondary Licenses. + + If it is not possible or desirable to put the notice in a particular + file, then You may include the notice in a location (such as a LICENSE + file in a relevant directory) where a recipient would be likely to + look for such a notice. + + You may add additional accurate notices of copyright ownership. diff --git a/packages/vscode-extension/README.md b/packages/vscode-extension/README.md new file mode 100644 index 0000000..b7eadbd --- /dev/null +++ b/packages/vscode-extension/README.md @@ -0,0 +1 @@ +# PL1 Extension \ No newline at end of file diff --git a/packages/vscode-extension/esbuild.mjs b/packages/vscode-extension/esbuild.mjs new file mode 100644 index 0000000..499f78a --- /dev/null +++ b/packages/vscode-extension/esbuild.mjs @@ -0,0 +1,89 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +//@ts-check +import * as esbuild from 'esbuild'; + +const watch = process.argv.includes('--watch'); +const minify = process.argv.includes('--minify'); + +const success = watch ? 'Watch build succeeded' : 'Build succeeded'; + +function getTime() { + const date = new Date(); + return `[${`${padZeroes(date.getHours())}:${padZeroes(date.getMinutes())}:${padZeroes(date.getSeconds())}`}] `; +} + +function padZeroes(i) { + return i.toString().padStart(2, '0'); +} + +const plugins = [{ + name: 'watch-plugin', + setup(build) { + build.onEnd(result => { + if (result.errors.length === 0) { + console.log(getTime() + success); + } + }); + }, +}]; + +const nodeCtx = await esbuild.context({ + // Entry points for the vscode extension and the language server + entryPoints: ['src/extension/main.ts', 'src/language/main.ts'], + outdir: 'out', + bundle: true, + target: "ES2017", + // VSCode's extension host is still using cjs, so we need to transform the code + format: 'cjs', + // To prevent confusing node, we explicitly use the `.cjs` extension + outExtension: { + '.js': '.cjs' + }, + loader: { '.ts': 'ts' }, + external: ['vscode'], + platform: 'node', + sourcemap: !minify, + minify, + plugins +}); + +const browserCtx = await esbuild.context({ + // Entry points for the vscode extension and the language server + entryPoints: ['src/extension/main-browser.ts', 'src/language/main-browser.ts'], + outdir: 'out', + bundle: true, + target: "ES2017", + format: 'cjs', + loader: { '.ts': 'ts' }, + external: ['vscode'], + platform: 'browser', + sourcemap: !minify, + minify, + plugins +}); + +if (watch) { + await Promise.all([ + nodeCtx.watch(), + browserCtx.watch() + ]); +} else { + await Promise.all([ + nodeCtx.rebuild(), + browserCtx.rebuild() + ]); + await Promise.all([ + nodeCtx.dispose(), + browserCtx.dispose() + ]); +} diff --git a/packages/vscode-extension/language-configuration.json b/packages/vscode-extension/language-configuration.json new file mode 100644 index 0000000..aa136e5 --- /dev/null +++ b/packages/vscode-extension/language-configuration.json @@ -0,0 +1,28 @@ +{ + "comments": { + // symbols used for start and end a block comment. Remove this entry if your language does not support block comments + "blockComment": [ "/*", "*/" ] + }, + // symbols used as brackets + "brackets": [ + ["{", "}"], + ["[", "]"], + ["(", ")"] + ], + // symbols that are auto closed when typing + "autoClosingPairs": [ + ["{", "}"], + ["[", "]"], + ["(", ")"], + ["\"", "\""], + ["'", "'"] + ], + // symbols that can be used to surround a selection + "surroundingPairs": [ + ["{", "}"], + ["[", "]"], + ["(", ")"], + ["\"", "\""], + ["'", "'"] + ] +} diff --git a/packages/vscode-extension/package.json b/packages/vscode-extension/package.json new file mode 100644 index 0000000..a2e00b0 --- /dev/null +++ b/packages/vscode-extension/package.json @@ -0,0 +1,59 @@ +{ + "name": "pl-one-extension", + "description": "The extension specific package", + "author": "Zowe", + "license": "EPL-2.0", + "preview": false, + "publisher": "Zowe", + "repository": { + "type": "git", + "url": "https://github.com/zowe/zowe-pli-language-support" + }, + "version": "0.0.1", + "displayName": "PL/I Language Support", + "engines": { + "vscode": "^1.67.0" + }, + "categories": [ + "Programming Languages" + ], + "contributes": { + "languages": [{ + "id": "pli", + "aliases": ["PL/I", "PLI", "PL1", "PL/1"], + "extensions": [".pli"], + "configuration": "./language-configuration.json" + }], + "grammars": [{ + "language": "pli", + "scopeName": "source.pli", + "path": "syntaxes/pli.merged.json" + }] + }, + "activationEvents": [], + "main": "./out/extension/main.cjs", + "browser": "./out/extension/main-browser.js", + "scripts": { + "clean": "shx rm -fr *.tsbuildinfo out", + "vscode:prepublish": "npm run build && node esbuild.mjs --minify", + "package": "vsce package", + "build": "tsc -b tsconfig.json && node esbuild.mjs", + "build:clean": "npm run clean && npm run build", + "watch": "concurrently -n tsc,esbuild -c blue,yellow \"tsc -b tsconfig.json --watch\" \"node esbuild.mjs --watch\"" + }, + "vsce": { + "dependencies": false + }, + "dependencies": { + "langium": "~3.2.0", + "pl-one-language": "workspace:*", + "vscode-languageclient": "~9.0.1", + "vscode-languageserver": "~9.0.1" + }, + "devDependencies": { + "@types/vscode": "~1.67.0", + "@vscode/vsce": "^3.0.0", + "concurrently": "~8.2.1", + "esbuild": "~0.21.5" + } +} diff --git a/packages/vscode-extension/src/extension/builtin-files.ts b/packages/vscode-extension/src/extension/builtin-files.ts new file mode 100644 index 0000000..e751b98 --- /dev/null +++ b/packages/vscode-extension/src/extension/builtin-files.ts @@ -0,0 +1,71 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import * as vscode from 'vscode'; +import { Builtins } from 'pl-one-language'; + +export class BuiltinFileSystemProvider implements vscode.FileSystemProvider { + + static register(context: vscode.ExtensionContext) { + context.subscriptions.push( + vscode.workspace.registerFileSystemProvider('pli-builtin', new BuiltinFileSystemProvider(), { + isReadonly: true, + isCaseSensitive: false + })); + } + + stat(uri: vscode.Uri): vscode.FileStat { + const date = Date.now(); + return { + ctime: date, + mtime: date, + size: Buffer.from(Builtins).length, + type: vscode.FileType.File + }; + } + + readFile(uri: vscode.Uri): Uint8Array { + // We could return different libraries based on the URI + // We have only one, so we always return the same + return new Uint8Array(Buffer.from(Builtins)); + } + + // The following class members only serve to satisfy the interface + + private readonly didChangeFile = new vscode.EventEmitter(); + onDidChangeFile = this.didChangeFile.event; + + watch() { + return { + dispose: () => {} + }; + } + + readDirectory(): [] { + throw vscode.FileSystemError.NoPermissions(); + } + + createDirectory() { + throw vscode.FileSystemError.NoPermissions(); + } + + writeFile() { + throw vscode.FileSystemError.NoPermissions(); + } + + delete() { + throw vscode.FileSystemError.NoPermissions(); + } + + rename() { + throw vscode.FileSystemError.NoPermissions(); + } +} diff --git a/packages/vscode-extension/src/extension/main-browser.ts b/packages/vscode-extension/src/extension/main-browser.ts new file mode 100644 index 0000000..e61849b --- /dev/null +++ b/packages/vscode-extension/src/extension/main-browser.ts @@ -0,0 +1,53 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import type { LanguageClientOptions } from 'vscode-languageclient/browser.js'; +import * as vscode from 'vscode'; +import { LanguageClient } from 'vscode-languageclient/browser.js'; +import { BuiltinFileSystemProvider } from './builtin-files'; + +let client: LanguageClient; + +// This function is called when the extension is activated. +export function activate(context: vscode.ExtensionContext): void { + BuiltinFileSystemProvider.register(context); + client = startLanguageClient(context); +} + +// This function is called when the extension is deactivated. +export function deactivate(): Thenable | undefined { + if (client) { + return client.stop(); + } + return undefined; +} + +function startLanguageClient(context: vscode.ExtensionContext): LanguageClient { + const serverModule = vscode.Uri.joinPath(context.extensionUri, 'out/language/main-browser.js'); + const worker = new Worker(serverModule.toString(true)); + + // Options to control the language client + const clientOptions: LanguageClientOptions = { + documentSelector: [{ scheme: '*', language: 'pli' }] + }; + + // Create the language client and start the client. + const client = new LanguageClient( + 'pli', + 'PL/I', + clientOptions, + worker + ); + + // Start the client. This will also launch the server + client.start(); + return client; +} diff --git a/packages/vscode-extension/src/extension/main.ts b/packages/vscode-extension/src/extension/main.ts new file mode 100644 index 0000000..85dec76 --- /dev/null +++ b/packages/vscode-extension/src/extension/main.ts @@ -0,0 +1,64 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import type { LanguageClientOptions, ServerOptions } from 'vscode-languageclient/node.js'; +import type * as vscode from 'vscode'; +import * as path from 'node:path'; +import { LanguageClient, TransportKind } from 'vscode-languageclient/node.js'; +import { BuiltinFileSystemProvider } from './builtin-files'; + +let client: LanguageClient; + +// This function is called when the extension is activated. +export function activate(context: vscode.ExtensionContext): void { + BuiltinFileSystemProvider.register(context); + client = startLanguageClient(context); +} + +// This function is called when the extension is deactivated. +export function deactivate(): Thenable | undefined { + if (client) { + return client.stop(); + } + return undefined; +} + +function startLanguageClient(context: vscode.ExtensionContext): LanguageClient { + const serverModule = context.asAbsolutePath(path.join('out', 'language', 'main.cjs')); + // The debug options for the server + // --inspect=6009: runs the server in Node's Inspector mode so VS Code can attach to the server for debugging. + // By setting `process.env.DEBUG_BREAK` to a truthy value, the language server will wait until a debugger is attached. + const debugOptions = { execArgv: ['--nolazy', `--inspect${process.env.DEBUG_BREAK ? '-brk' : ''}=${process.env.DEBUG_SOCKET || '6009'}`] }; + + // If the extension is launched in debug mode then the debug server options are used + // Otherwise the run options are used + const serverOptions: ServerOptions = { + run: { module: serverModule, transport: TransportKind.ipc }, + debug: { module: serverModule, transport: TransportKind.ipc, options: debugOptions } + }; + + // Options to control the language client + const clientOptions: LanguageClientOptions = { + documentSelector: [{ scheme: '*', language: 'pli' }] + }; + + // Create the language client and start the client. + const client = new LanguageClient( + 'pli', + 'PL/I', + serverOptions, + clientOptions + ); + + // Start the client. This will also launch the server + client.start(); + return client; +} diff --git a/packages/vscode-extension/src/language/main-browser.ts b/packages/vscode-extension/src/language/main-browser.ts new file mode 100644 index 0000000..a0a2c5f --- /dev/null +++ b/packages/vscode-extension/src/language/main-browser.ts @@ -0,0 +1,27 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { EmptyFileSystem } from 'langium'; +import { startLanguageServer } from 'langium/lsp'; +import { BrowserMessageReader, BrowserMessageWriter, createConnection } from 'vscode-languageserver/browser.js'; +import { createPliServices } from 'pl-one-language'; + +/* browser specific setup code */ +const messageReader = new BrowserMessageReader(self); +const messageWriter = new BrowserMessageWriter(self); + +const connection = createConnection(messageReader, messageWriter); + +// Inject the shared services and language-specific services +const { shared } = createPliServices({ connection, ...EmptyFileSystem }); + +// Start the language server with the shared services +startLanguageServer(shared); diff --git a/packages/vscode-extension/src/language/main.ts b/packages/vscode-extension/src/language/main.ts new file mode 100644 index 0000000..6dd464f --- /dev/null +++ b/packages/vscode-extension/src/language/main.ts @@ -0,0 +1,24 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import { startLanguageServer } from 'langium/lsp'; +import { NodeFileSystem } from 'langium/node'; +import { createConnection, ProposedFeatures } from 'vscode-languageserver/node.js'; +import { createPliServices } from 'pl-one-language'; + +// Create a connection to the client +const connection = createConnection(ProposedFeatures.all); + +// Inject the shared services and language-specific services +const { shared } = createPliServices({ connection, ...NodeFileSystem }); + +// Start the language server with the shared services +startLanguageServer(shared); diff --git a/packages/vscode-extension/syntaxes/pli.manual.json b/packages/vscode-extension/syntaxes/pli.manual.json new file mode 100644 index 0000000..54eaa9a --- /dev/null +++ b/packages/vscode-extension/syntaxes/pli.manual.json @@ -0,0 +1,79 @@ +{ + "name": "pli", + "scopeName": "source.pli", + "fileTypes": [ + ".pli" + ], + "patterns": [ + { + "include": "#comments" + }, + { + "name": "string.quoted.single.pli", + "begin": "'", + "end": "'", + "patterns": [ + { + "include": "#string-character-escape" + } + ] + }, + { + "name": "string.double.single.pli", + "begin": "\"", + "end": "\"", + "patterns": [ + { + "include": "#string-character-escape" + } + ] + }, + { + "name": "string.exec.pli", + "match": "(?<=[eE][xX][eE][cC]\\s*)[a-zA-Z]+\\s[^;]*" + }, + { + "name": "constant.numeric.decimal.pli", + "match": "([0-9][0-9_]*(\\.[0-9_]+)?)|(\\.[0-9_]+)([ESDQ][-+]?[0-9]+)?([bB]|[iI])*" + }, + { + "name": "entity.other.pli", + "match": "[a-zA-Z_][a-zA-Z0-9_]*" + } + ], + "repository": { + "string-character-escape": { + "name": "constant.character.escape.lox", + "match": "\\\\(x[0-9A-Fa-f]{2}|u[0-9A-Fa-f]{4}|u\\{[0-9A-Fa-f]+\\}|[0-2][0-7]{0,2}|3[0-6][0-7]?|37[0-7]?|[4-7][0-7]?|.|$)" + }, + "comments": { + "patterns": [ + { + "name": "comment.block.pli", + "begin": "/\\*", + "beginCaptures": { + "0": { + "name": "punctuation.definition.comment.pli" + } + }, + "end": "\\*/", + "endCaptures": { + "0": { + "name": "punctuation.definition.comment.pli" + } + } + }, + { + "begin": "//", + "beginCaptures": { + "1": { + "name": "punctuation.whitespace.comment.leading.pli" + } + }, + "end": "(?=$)", + "name": "comment.line.pli" + } + ] + } + } +} \ No newline at end of file diff --git a/packages/vscode-extension/tsconfig.json b/packages/vscode-extension/tsconfig.json new file mode 100644 index 0000000..315afa5 --- /dev/null +++ b/packages/vscode-extension/tsconfig.json @@ -0,0 +1,16 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "noEmit": true, + "rootDir": ".", + "lib": ["DOM", "ES2022"] + }, + "references": [ + { + "path": "../language/tsconfig.src.json" + } + ], + "include": [ + "src/**/*.ts" + ] +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml new file mode 100644 index 0000000..e4e990c --- /dev/null +++ b/pnpm-lock.yaml @@ -0,0 +1,3931 @@ +lockfileVersion: '9.0' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + +importers: + + .: + devDependencies: + '@types/node': + specifier: ^18.0.0 + version: 18.19.60 + '@typescript-eslint/eslint-plugin': + specifier: ~7.13.0 + version: 7.13.1(@typescript-eslint/parser@7.13.1(eslint@8.57.1)(typescript@5.4.5))(eslint@8.57.1)(typescript@5.4.5) + '@typescript-eslint/parser': + specifier: ~7.13.0 + version: 7.13.1(eslint@8.57.1)(typescript@5.4.5) + deepmerge: + specifier: ^1.5.0 + version: 1.5.2 + eslint: + specifier: ~8.57.0 + version: 8.57.1 + langium: + specifier: ~3.2.0 + version: 3.2.0 + shx: + specifier: ~0.3.4 + version: 0.3.4 + typescript: + specifier: ~5.4.5 + version: 5.4.5 + vitest: + specifier: ^1.6.0 + version: 1.6.0(@types/node@18.19.60) + + packages/language: + dependencies: + chevrotain: + specifier: ^11.0.3 + version: 11.0.3 + langium: + specifier: ~3.2.0 + version: 3.2.0 + vscode-languageserver: + specifier: ~9.0.1 + version: 9.0.1 + vscode-languageserver-types: + specifier: ^3.17.5 + version: 3.17.5 + devDependencies: + langium-cli: + specifier: ~3.2.0 + version: 3.2.0 + + packages/vscode-extension: + dependencies: + langium: + specifier: ~3.2.0 + version: 3.2.0 + pl-one-language: + specifier: workspace:* + version: link:../language + vscode-languageclient: + specifier: ~9.0.1 + version: 9.0.1 + vscode-languageserver: + specifier: ~9.0.1 + version: 9.0.1 + devDependencies: + '@types/vscode': + specifier: ~1.67.0 + version: 1.67.0 + '@vscode/vsce': + specifier: ^3.0.0 + version: 3.2.1 + concurrently: + specifier: ~8.2.1 + version: 8.2.2 + esbuild: + specifier: ~0.21.5 + version: 0.21.5 + +packages: + + '@azure/abort-controller@2.1.2': + resolution: {integrity: sha512-nBrLsEWm4J2u5LpAPjxADTlq3trDgVZZXHNKabeXZtpq3d3AbN/KGO82R87rdDz5/lYB024rtEf10/q0urNgsA==} + engines: {node: '>=18.0.0'} + + '@azure/core-auth@1.9.0': + resolution: {integrity: sha512-FPwHpZywuyasDSLMqJ6fhbOK3TqUdviZNF8OqRGA4W5Ewib2lEEZ+pBsYcBa88B2NGO/SEnYPGhyBqNlE8ilSw==} + engines: {node: '>=18.0.0'} + + '@azure/core-client@1.9.2': + resolution: {integrity: sha512-kRdry/rav3fUKHl/aDLd/pDLcB+4pOFwPPTVEExuMyaI5r+JBbMWqRbCY1pn5BniDaU3lRxO9eaQ1AmSMehl/w==} + engines: {node: '>=18.0.0'} + + '@azure/core-rest-pipeline@1.17.0': + resolution: {integrity: sha512-62Vv8nC+uPId3j86XJ0WI+sBf0jlqTqPUFCBNrGtlaUeQUIXWV/D8GE5A1d+Qx8H7OQojn2WguC8kChD6v0shA==} + engines: {node: '>=18.0.0'} + + '@azure/core-tracing@1.2.0': + resolution: {integrity: sha512-UKTiEJPkWcESPYJz3X5uKRYyOcJD+4nYph+KpfdPRnQJVrZfk0KJgdnaAWKfhsBBtAf/D58Az4AvCJEmWgIBAg==} + engines: {node: '>=18.0.0'} + + '@azure/core-util@1.11.0': + resolution: {integrity: sha512-DxOSLua+NdpWoSqULhjDyAZTXFdP/LKkqtYuxxz1SCN289zk3OG8UOpnCQAz/tygyACBtWp/BoO72ptK7msY8g==} + engines: {node: '>=18.0.0'} + + '@azure/identity@4.5.0': + resolution: {integrity: sha512-EknvVmtBuSIic47xkOqyNabAme0RYTw52BTMz8eBgU1ysTyMrD1uOoM+JdS0J/4Yfp98IBT3osqq3BfwSaNaGQ==} + engines: {node: '>=18.0.0'} + + '@azure/logger@1.1.4': + resolution: {integrity: sha512-4IXXzcCdLdlXuCG+8UKEwLA1T1NHqUfanhXYHiQTn+6sfWCZXduqbtXDGceg3Ce5QxTGo7EqmbV6Bi+aqKuClQ==} + engines: {node: '>=18.0.0'} + + '@azure/msal-browser@3.26.1': + resolution: {integrity: sha512-y78sr9g61aCAH9fcLO1um+oHFXc1/5Ap88RIsUSuzkm0BHzFnN+PXGaQeuM1h5Qf5dTnWNOd6JqkskkMPAhh7Q==} + engines: {node: '>=0.8.0'} + + '@azure/msal-common@14.15.0': + resolution: {integrity: sha512-ImAQHxmpMneJ/4S8BRFhjt1MZ3bppmpRPYYNyzeQPeFN288YKbb8TmmISQEbtfkQ1BPASvYZU5doIZOPBAqENQ==} + engines: {node: '>=0.8.0'} + + '@azure/msal-node@2.15.0': + resolution: {integrity: sha512-gVPW8YLz92ZeCibQH2QUw96odJoiM3k/ZPH3f2HxptozmH6+OnyyvKXo/Egg39HAM230akarQKHf0W74UHlh0Q==} + engines: {node: '>=16'} + + '@babel/runtime@7.26.0': + resolution: {integrity: sha512-FDSOghenHTiToteC/QRlv2q3DhPZ/oOXTBoirfWNx1Cx3TMVcGWQtMMmQcSvb/JjpNeGzx8Pq/b4fKEJuWm1sw==} + engines: {node: '>=6.9.0'} + + '@chevrotain/cst-dts-gen@11.0.3': + resolution: {integrity: sha512-BvIKpRLeS/8UbfxXxgC33xOumsacaeCKAjAeLyOn7Pcp95HiRbrpl14S+9vaZLolnbssPIUuiUd8IvgkRyt6NQ==} + + '@chevrotain/gast@11.0.3': + resolution: {integrity: sha512-+qNfcoNk70PyS/uxmj3li5NiECO+2YKZZQMbmjTqRI3Qchu8Hig/Q9vgkHpI3alNjr7M+a2St5pw5w5F6NL5/Q==} + + '@chevrotain/regexp-to-ast@11.0.3': + resolution: {integrity: sha512-1fMHaBZxLFvWI067AVbGJav1eRY7N8DDvYCTwGBiE/ytKBgP8azTdgyrKyWZ9Mfh09eHWb5PgTSO8wi7U824RA==} + + '@chevrotain/types@11.0.3': + resolution: {integrity: sha512-gsiM3G8b58kZC2HaWR50gu6Y1440cHiJ+i3JUvcp/35JchYejb2+5MVeJK0iKThYpAa/P2PYFV4hoi44HD+aHQ==} + + '@chevrotain/utils@11.0.3': + resolution: {integrity: sha512-YslZMgtJUyuMbZ+aKvfF3x1f5liK4mWNxghFRv7jqRR9C3R3fAOGTTKvxXDa2Y1s9zSbcpuO0cAxDYsc9SrXoQ==} + + '@esbuild/aix-ppc64@0.21.5': + resolution: {integrity: sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==} + engines: {node: '>=12'} + cpu: [ppc64] + os: [aix] + + '@esbuild/android-arm64@0.21.5': + resolution: {integrity: sha512-c0uX9VAUBQ7dTDCjq+wdyGLowMdtR/GoC2U5IYk/7D1H1JYC0qseD7+11iMP2mRLN9RcCMRcjC4YMclCzGwS/A==} + engines: {node: '>=12'} + cpu: [arm64] + os: [android] + + '@esbuild/android-arm@0.21.5': + resolution: {integrity: sha512-vCPvzSjpPHEi1siZdlvAlsPxXl7WbOVUBBAowWug4rJHb68Ox8KualB+1ocNvT5fjv6wpkX6o/iEpbDrf68zcg==} + engines: {node: '>=12'} + cpu: [arm] + os: [android] + + '@esbuild/android-x64@0.21.5': + resolution: {integrity: sha512-D7aPRUUNHRBwHxzxRvp856rjUHRFW1SdQATKXH2hqA0kAZb1hKmi02OpYRacl0TxIGz/ZmXWlbZgjwWYaCakTA==} + engines: {node: '>=12'} + cpu: [x64] + os: [android] + + '@esbuild/darwin-arm64@0.21.5': + resolution: {integrity: sha512-DwqXqZyuk5AiWWf3UfLiRDJ5EDd49zg6O9wclZ7kUMv2WRFr4HKjXp/5t8JZ11QbQfUS6/cRCKGwYhtNAY88kQ==} + engines: {node: '>=12'} + cpu: [arm64] + os: [darwin] + + '@esbuild/darwin-x64@0.21.5': + resolution: {integrity: sha512-se/JjF8NlmKVG4kNIuyWMV/22ZaerB+qaSi5MdrXtd6R08kvs2qCN4C09miupktDitvh8jRFflwGFBQcxZRjbw==} + engines: {node: '>=12'} + cpu: [x64] + os: [darwin] + + '@esbuild/freebsd-arm64@0.21.5': + resolution: {integrity: sha512-5JcRxxRDUJLX8JXp/wcBCy3pENnCgBR9bN6JsY4OmhfUtIHe3ZW0mawA7+RDAcMLrMIZaf03NlQiX9DGyB8h4g==} + engines: {node: '>=12'} + cpu: [arm64] + os: [freebsd] + + '@esbuild/freebsd-x64@0.21.5': + resolution: {integrity: sha512-J95kNBj1zkbMXtHVH29bBriQygMXqoVQOQYA+ISs0/2l3T9/kj42ow2mpqerRBxDJnmkUDCaQT/dfNXWX/ZZCQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [freebsd] + + '@esbuild/linux-arm64@0.21.5': + resolution: {integrity: sha512-ibKvmyYzKsBeX8d8I7MH/TMfWDXBF3db4qM6sy+7re0YXya+K1cem3on9XgdT2EQGMu4hQyZhan7TeQ8XkGp4Q==} + engines: {node: '>=12'} + cpu: [arm64] + os: [linux] + + '@esbuild/linux-arm@0.21.5': + resolution: {integrity: sha512-bPb5AHZtbeNGjCKVZ9UGqGwo8EUu4cLq68E95A53KlxAPRmUyYv2D6F0uUI65XisGOL1hBP5mTronbgo+0bFcA==} + engines: {node: '>=12'} + cpu: [arm] + os: [linux] + + '@esbuild/linux-ia32@0.21.5': + resolution: {integrity: sha512-YvjXDqLRqPDl2dvRODYmmhz4rPeVKYvppfGYKSNGdyZkA01046pLWyRKKI3ax8fbJoK5QbxblURkwK/MWY18Tg==} + engines: {node: '>=12'} + cpu: [ia32] + os: [linux] + + '@esbuild/linux-loong64@0.21.5': + resolution: {integrity: sha512-uHf1BmMG8qEvzdrzAqg2SIG/02+4/DHB6a9Kbya0XDvwDEKCoC8ZRWI5JJvNdUjtciBGFQ5PuBlpEOXQj+JQSg==} + engines: {node: '>=12'} + cpu: [loong64] + os: [linux] + + '@esbuild/linux-mips64el@0.21.5': + resolution: {integrity: sha512-IajOmO+KJK23bj52dFSNCMsz1QP1DqM6cwLUv3W1QwyxkyIWecfafnI555fvSGqEKwjMXVLokcV5ygHW5b3Jbg==} + engines: {node: '>=12'} + cpu: [mips64el] + os: [linux] + + '@esbuild/linux-ppc64@0.21.5': + resolution: {integrity: sha512-1hHV/Z4OEfMwpLO8rp7CvlhBDnjsC3CttJXIhBi+5Aj5r+MBvy4egg7wCbe//hSsT+RvDAG7s81tAvpL2XAE4w==} + engines: {node: '>=12'} + cpu: [ppc64] + os: [linux] + + '@esbuild/linux-riscv64@0.21.5': + resolution: {integrity: sha512-2HdXDMd9GMgTGrPWnJzP2ALSokE/0O5HhTUvWIbD3YdjME8JwvSCnNGBnTThKGEB91OZhzrJ4qIIxk/SBmyDDA==} + engines: {node: '>=12'} + cpu: [riscv64] + os: [linux] + + '@esbuild/linux-s390x@0.21.5': + resolution: {integrity: sha512-zus5sxzqBJD3eXxwvjN1yQkRepANgxE9lgOW2qLnmr8ikMTphkjgXu1HR01K4FJg8h1kEEDAqDcZQtbrRnB41A==} + engines: {node: '>=12'} + cpu: [s390x] + os: [linux] + + '@esbuild/linux-x64@0.21.5': + resolution: {integrity: sha512-1rYdTpyv03iycF1+BhzrzQJCdOuAOtaqHTWJZCWvijKD2N5Xu0TtVC8/+1faWqcP9iBCWOmjmhoH94dH82BxPQ==} + engines: {node: '>=12'} + cpu: [x64] + os: [linux] + + '@esbuild/netbsd-x64@0.21.5': + resolution: {integrity: sha512-Woi2MXzXjMULccIwMnLciyZH4nCIMpWQAs049KEeMvOcNADVxo0UBIQPfSmxB3CWKedngg7sWZdLvLczpe0tLg==} + engines: {node: '>=12'} + cpu: [x64] + os: [netbsd] + + '@esbuild/openbsd-x64@0.21.5': + resolution: {integrity: sha512-HLNNw99xsvx12lFBUwoT8EVCsSvRNDVxNpjZ7bPn947b8gJPzeHWyNVhFsaerc0n3TsbOINvRP2byTZ5LKezow==} + engines: {node: '>=12'} + cpu: [x64] + os: [openbsd] + + '@esbuild/sunos-x64@0.21.5': + resolution: {integrity: sha512-6+gjmFpfy0BHU5Tpptkuh8+uw3mnrvgs+dSPQXQOv3ekbordwnzTVEb4qnIvQcYXq6gzkyTnoZ9dZG+D4garKg==} + engines: {node: '>=12'} + cpu: [x64] + os: [sunos] + + '@esbuild/win32-arm64@0.21.5': + resolution: {integrity: sha512-Z0gOTd75VvXqyq7nsl93zwahcTROgqvuAcYDUr+vOv8uHhNSKROyU961kgtCD1e95IqPKSQKH7tBTslnS3tA8A==} + engines: {node: '>=12'} + cpu: [arm64] + os: [win32] + + '@esbuild/win32-ia32@0.21.5': + resolution: {integrity: sha512-SWXFF1CL2RVNMaVs+BBClwtfZSvDgtL//G/smwAc5oVK/UPu2Gu9tIaRgFmYFFKrmg3SyAjSrElf0TiJ1v8fYA==} + engines: {node: '>=12'} + cpu: [ia32] + os: [win32] + + '@esbuild/win32-x64@0.21.5': + resolution: {integrity: sha512-tQd/1efJuzPC6rCFwEvLtci/xNFcTZknmXs98FYDfGE4wP9ClFV98nyKrzJKVPMhdDnjzLhdUyMX4PsQAPjwIw==} + engines: {node: '>=12'} + cpu: [x64] + os: [win32] + + '@eslint-community/eslint-utils@4.4.1': + resolution: {integrity: sha512-s3O3waFUrMV8P/XaF/+ZTp1X9XBZW1a4B97ZnjQF2KYWaFD2A8KyFBsrsfSjEmjn3RGWAIuvlneuZm3CUK3jbA==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + + '@eslint-community/regexpp@4.12.1': + resolution: {integrity: sha512-CCZCDJuduB9OUkFkY2IgppNZMi2lBQgD2qzwXkEia16cge2pijY/aXi96CJMquDMn3nJdlPV1A5KrJEXwfLNzQ==} + engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} + + '@eslint/eslintrc@2.1.4': + resolution: {integrity: sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + '@eslint/js@8.57.1': + resolution: {integrity: sha512-d9zaMRSTIKDLhctzH12MtXvJKSSUhaHcjV+2Z+GK+EEY7XKpP5yR4x+N3TAcHTcu963nIr+TMcCb4DBCYX1z6Q==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + '@humanwhocodes/config-array@0.13.0': + resolution: {integrity: sha512-DZLEEqFWQFiyK6h5YIeynKx7JlvCYWL0cImfSRXZ9l4Sg2efkFGTuFf6vzXjK1cq6IYkU+Eg/JizXw+TD2vRNw==} + engines: {node: '>=10.10.0'} + deprecated: Use @eslint/config-array instead + + '@humanwhocodes/module-importer@1.0.1': + resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} + engines: {node: '>=12.22'} + + '@humanwhocodes/object-schema@2.0.3': + resolution: {integrity: sha512-93zYdMES/c1D69yZiKDBj0V24vqNzB/koF26KPaagAfd3P/4gUlh3Dys5ogAK+Exi9QyzlD8x/08Zt7wIKcDcA==} + deprecated: Use @eslint/object-schema instead + + '@isaacs/cliui@8.0.2': + resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} + engines: {node: '>=12'} + + '@jest/schemas@29.6.3': + resolution: {integrity: sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA==} + engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} + + '@jridgewell/sourcemap-codec@1.5.0': + resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} + + '@nodelib/fs.scandir@2.1.5': + resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} + engines: {node: '>= 8'} + + '@nodelib/fs.stat@2.0.5': + resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==} + engines: {node: '>= 8'} + + '@nodelib/fs.walk@1.2.8': + resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==} + engines: {node: '>= 8'} + + '@rollup/rollup-android-arm-eabi@4.24.2': + resolution: {integrity: sha512-ufoveNTKDg9t/b7nqI3lwbCG/9IJMhADBNjjz/Jn6LxIZxD7T5L8l2uO/wD99945F1Oo8FvgbbZJRguyk/BdzA==} + cpu: [arm] + os: [android] + + '@rollup/rollup-android-arm64@4.24.2': + resolution: {integrity: sha512-iZoYCiJz3Uek4NI0J06/ZxUgwAfNzqltK0MptPDO4OR0a88R4h0DSELMsflS6ibMCJ4PnLvq8f7O1d7WexUvIA==} + cpu: [arm64] + os: [android] + + '@rollup/rollup-darwin-arm64@4.24.2': + resolution: {integrity: sha512-/UhrIxobHYCBfhi5paTkUDQ0w+jckjRZDZ1kcBL132WeHZQ6+S5v9jQPVGLVrLbNUebdIRpIt00lQ+4Z7ys4Rg==} + cpu: [arm64] + os: [darwin] + + '@rollup/rollup-darwin-x64@4.24.2': + resolution: {integrity: sha512-1F/jrfhxJtWILusgx63WeTvGTwE4vmsT9+e/z7cZLKU8sBMddwqw3UV5ERfOV+H1FuRK3YREZ46J4Gy0aP3qDA==} + cpu: [x64] + os: [darwin] + + '@rollup/rollup-freebsd-arm64@4.24.2': + resolution: {integrity: sha512-1YWOpFcGuC6iGAS4EI+o3BV2/6S0H+m9kFOIlyFtp4xIX5rjSnL3AwbTBxROX0c8yWtiWM7ZI6mEPTI7VkSpZw==} + cpu: [arm64] + os: [freebsd] + + '@rollup/rollup-freebsd-x64@4.24.2': + resolution: {integrity: sha512-3qAqTewYrCdnOD9Gl9yvPoAoFAVmPJsBvleabvx4bnu1Kt6DrB2OALeRVag7BdWGWLhP1yooeMLEi6r2nYSOjg==} + cpu: [x64] + os: [freebsd] + + '@rollup/rollup-linux-arm-gnueabihf@4.24.2': + resolution: {integrity: sha512-ArdGtPHjLqWkqQuoVQ6a5UC5ebdX8INPuJuJNWRe0RGa/YNhVvxeWmCTFQ7LdmNCSUzVZzxAvUznKaYx645Rig==} + cpu: [arm] + os: [linux] + + '@rollup/rollup-linux-arm-musleabihf@4.24.2': + resolution: {integrity: sha512-B6UHHeNnnih8xH6wRKB0mOcJGvjZTww1FV59HqJoTJ5da9LCG6R4SEBt6uPqzlawv1LoEXSS0d4fBlHNWl6iYw==} + cpu: [arm] + os: [linux] + + '@rollup/rollup-linux-arm64-gnu@4.24.2': + resolution: {integrity: sha512-kr3gqzczJjSAncwOS6i7fpb4dlqcvLidqrX5hpGBIM1wtt0QEVtf4wFaAwVv8QygFU8iWUMYEoJZWuWxyua4GQ==} + cpu: [arm64] + os: [linux] + + '@rollup/rollup-linux-arm64-musl@4.24.2': + resolution: {integrity: sha512-TDdHLKCWgPuq9vQcmyLrhg/bgbOvIQ8rtWQK7MRxJ9nvaxKx38NvY7/Lo6cYuEnNHqf6rMqnivOIPIQt6H2AoA==} + cpu: [arm64] + os: [linux] + + '@rollup/rollup-linux-powerpc64le-gnu@4.24.2': + resolution: {integrity: sha512-xv9vS648T3X4AxFFZGWeB5Dou8ilsv4VVqJ0+loOIgDO20zIhYfDLkk5xoQiej2RiSQkld9ijF/fhLeonrz2mw==} + cpu: [ppc64] + os: [linux] + + '@rollup/rollup-linux-riscv64-gnu@4.24.2': + resolution: {integrity: sha512-tbtXwnofRoTt223WUZYiUnbxhGAOVul/3StZ947U4A5NNjnQJV5irKMm76G0LGItWs6y+SCjUn/Q0WaMLkEskg==} + cpu: [riscv64] + os: [linux] + + '@rollup/rollup-linux-s390x-gnu@4.24.2': + resolution: {integrity: sha512-gc97UebApwdsSNT3q79glOSPdfwgwj5ELuiyuiMY3pEWMxeVqLGKfpDFoum4ujivzxn6veUPzkGuSYoh5deQ2Q==} + cpu: [s390x] + os: [linux] + + '@rollup/rollup-linux-x64-gnu@4.24.2': + resolution: {integrity: sha512-jOG/0nXb3z+EM6SioY8RofqqmZ+9NKYvJ6QQaa9Mvd3RQxlH68/jcB/lpyVt4lCiqr04IyaC34NzhUqcXbB5FQ==} + cpu: [x64] + os: [linux] + + '@rollup/rollup-linux-x64-musl@4.24.2': + resolution: {integrity: sha512-XAo7cJec80NWx9LlZFEJQxqKOMz/lX3geWs2iNT5CHIERLFfd90f3RYLLjiCBm1IMaQ4VOX/lTC9lWfzzQm14Q==} + cpu: [x64] + os: [linux] + + '@rollup/rollup-win32-arm64-msvc@4.24.2': + resolution: {integrity: sha512-A+JAs4+EhsTjnPQvo9XY/DC0ztaws3vfqzrMNMKlwQXuniBKOIIvAAI8M0fBYiTCxQnElYu7mLk7JrhlQ+HeOw==} + cpu: [arm64] + os: [win32] + + '@rollup/rollup-win32-ia32-msvc@4.24.2': + resolution: {integrity: sha512-ZhcrakbqA1SCiJRMKSU64AZcYzlZ/9M5LaYil9QWxx9vLnkQ9Vnkve17Qn4SjlipqIIBFKjBES6Zxhnvh0EAEw==} + cpu: [ia32] + os: [win32] + + '@rollup/rollup-win32-x64-msvc@4.24.2': + resolution: {integrity: sha512-2mLH46K1u3r6uwc95hU+OR9q/ggYMpnS7pSp83Ece1HUQgF9Nh/QwTK5rcgbFnV9j+08yBrU5sA/P0RK2MSBNA==} + cpu: [x64] + os: [win32] + + '@sinclair/typebox@0.27.8': + resolution: {integrity: sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA==} + + '@types/estree@1.0.6': + resolution: {integrity: sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==} + + '@types/node@18.19.60': + resolution: {integrity: sha512-cYRj7igVqgxhlHFdBHHpU2SNw3+dN2x0VTZJtLYk6y/ieuGN4XiBgtDjYVktM/yk2y/8pKMileNc6IoEzEJnUw==} + + '@types/vscode@1.67.0': + resolution: {integrity: sha512-GH8BDf8cw9AC9080uneJfulhSa7KHSMI2s/CyKePXoGNos9J486w2V4YKoeNUqIEkW4hKoEAWp6/cXTwyGj47g==} + + '@typescript-eslint/eslint-plugin@7.13.1': + resolution: {integrity: sha512-kZqi+WZQaZfPKnsflLJQCz6Ze9FFSMfXrrIOcyargekQxG37ES7DJNpJUE9Q/X5n3yTIP/WPutVNzgknQ7biLg==} + engines: {node: ^18.18.0 || >=20.0.0} + peerDependencies: + '@typescript-eslint/parser': ^7.0.0 + eslint: ^8.56.0 + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + '@typescript-eslint/parser@7.13.1': + resolution: {integrity: sha512-1ELDPlnLvDQ5ybTSrMhRTFDfOQEOXNM+eP+3HT/Yq7ruWpciQw+Avi73pdEbA4SooCawEWo3dtYbF68gN7Ed1A==} + engines: {node: ^18.18.0 || >=20.0.0} + peerDependencies: + eslint: ^8.56.0 + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + '@typescript-eslint/scope-manager@7.13.1': + resolution: {integrity: sha512-adbXNVEs6GmbzaCpymHQ0MB6E4TqoiVbC0iqG3uijR8ZYfpAXMGttouQzF4Oat3P2GxDVIrg7bMI/P65LiQZdg==} + engines: {node: ^18.18.0 || >=20.0.0} + + '@typescript-eslint/type-utils@7.13.1': + resolution: {integrity: sha512-aWDbLu1s9bmgPGXSzNCxELu+0+HQOapV/y+60gPXafR8e2g1Bifxzevaa+4L2ytCWm+CHqpELq4CSoN9ELiwCg==} + engines: {node: ^18.18.0 || >=20.0.0} + peerDependencies: + eslint: ^8.56.0 + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + '@typescript-eslint/types@7.13.1': + resolution: {integrity: sha512-7K7HMcSQIAND6RBL4kDl24sG/xKM13cA85dc7JnmQXw2cBDngg7c19B++JzvJHRG3zG36n9j1i451GBzRuHchw==} + engines: {node: ^18.18.0 || >=20.0.0} + + '@typescript-eslint/typescript-estree@7.13.1': + resolution: {integrity: sha512-uxNr51CMV7npU1BxZzYjoVz9iyjckBduFBP0S5sLlh1tXYzHzgZ3BR9SVsNed+LmwKrmnqN3Kdl5t7eZ5TS1Yw==} + engines: {node: ^18.18.0 || >=20.0.0} + peerDependencies: + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + + '@typescript-eslint/utils@7.13.1': + resolution: {integrity: sha512-h5MzFBD5a/Gh/fvNdp9pTfqJAbuQC4sCN2WzuXme71lqFJsZtLbjxfSk4r3p02WIArOF9N94pdsLiGutpDbrXQ==} + engines: {node: ^18.18.0 || >=20.0.0} + peerDependencies: + eslint: ^8.56.0 + + '@typescript-eslint/visitor-keys@7.13.1': + resolution: {integrity: sha512-k/Bfne7lrP7hcb7m9zSsgcBmo+8eicqqfNAJ7uUY+jkTFpKeH2FSkWpFRtimBxgkyvqfu9jTPRbYOvud6isdXA==} + engines: {node: ^18.18.0 || >=20.0.0} + + '@ungap/structured-clone@1.2.0': + resolution: {integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==} + + '@vitest/expect@1.6.0': + resolution: {integrity: sha512-ixEvFVQjycy/oNgHjqsL6AZCDduC+tflRluaHIzKIsdbzkLn2U/iBnVeJwB6HsIjQBdfMR8Z0tRxKUsvFJEeWQ==} + + '@vitest/runner@1.6.0': + resolution: {integrity: sha512-P4xgwPjwesuBiHisAVz/LSSZtDjOTPYZVmNAnpHHSR6ONrf8eCJOFRvUwdHn30F5M1fxhqtl7QZQUk2dprIXAg==} + + '@vitest/snapshot@1.6.0': + resolution: {integrity: sha512-+Hx43f8Chus+DCmygqqfetcAZrDJwvTj0ymqjQq4CvmpKFSTVteEOBzCusu1x2tt4OJcvBflyHUE0DZSLgEMtQ==} + + '@vitest/spy@1.6.0': + resolution: {integrity: sha512-leUTap6B/cqi/bQkXUu6bQV5TZPx7pmMBKBQiI0rJA8c3pB56ZsaTbREnF7CJfmvAS4V2cXIBAh/3rVwrrCYgw==} + + '@vitest/utils@1.6.0': + resolution: {integrity: sha512-21cPiuGMoMZwiOHa2i4LXkMkMkCGzA+MVFV70jRwHo95dL4x/ts5GZhML1QWuy7yfp3WzK3lRvZi3JnXTYqrBw==} + + '@vscode/vsce-sign-alpine-arm64@2.0.2': + resolution: {integrity: sha512-E80YvqhtZCLUv3YAf9+tIbbqoinWLCO/B3j03yQPbjT3ZIHCliKZlsy1peNc4XNZ5uIb87Jn0HWx/ZbPXviuAQ==} + cpu: [arm64] + os: [alpine] + + '@vscode/vsce-sign-alpine-x64@2.0.2': + resolution: {integrity: sha512-n1WC15MSMvTaeJ5KjWCzo0nzjydwxLyoHiMJHu1Ov0VWTZiddasmOQHekA47tFRycnt4FsQrlkSCTdgHppn6bw==} + cpu: [x64] + os: [alpine] + + '@vscode/vsce-sign-darwin-arm64@2.0.2': + resolution: {integrity: sha512-rz8F4pMcxPj8fjKAJIfkUT8ycG9CjIp888VY/6pq6cuI2qEzQ0+b5p3xb74CJnBbSC0p2eRVoe+WgNCAxCLtzQ==} + cpu: [arm64] + os: [darwin] + + '@vscode/vsce-sign-darwin-x64@2.0.2': + resolution: {integrity: sha512-MCjPrQ5MY/QVoZ6n0D92jcRb7eYvxAujG/AH2yM6lI0BspvJQxp0o9s5oiAM9r32r9tkLpiy5s2icsbwefAQIw==} + cpu: [x64] + os: [darwin] + + '@vscode/vsce-sign-linux-arm64@2.0.2': + resolution: {integrity: sha512-Ybeu7cA6+/koxszsORXX0OJk9N0GgfHq70Wqi4vv2iJCZvBrOWwcIrxKjvFtwyDgdeQzgPheH5nhLVl5eQy7WA==} + cpu: [arm64] + os: [linux] + + '@vscode/vsce-sign-linux-arm@2.0.2': + resolution: {integrity: sha512-Fkb5jpbfhZKVw3xwR6t7WYfwKZktVGNXdg1m08uEx1anO0oUPUkoQRsNm4QniL3hmfw0ijg00YA6TrxCRkPVOQ==} + cpu: [arm] + os: [linux] + + '@vscode/vsce-sign-linux-x64@2.0.2': + resolution: {integrity: sha512-NsPPFVtLaTlVJKOiTnO8Cl78LZNWy0Q8iAg+LlBiCDEgC12Gt4WXOSs2pmcIjDYzj2kY4NwdeN1mBTaujYZaPg==} + cpu: [x64] + os: [linux] + + '@vscode/vsce-sign-win32-arm64@2.0.2': + resolution: {integrity: sha512-wPs848ymZ3Ny+Y1Qlyi7mcT6VSigG89FWQnp2qRYCyMhdJxOpA4lDwxzlpL8fG6xC8GjQjGDkwbkWUcCobvksQ==} + cpu: [arm64] + os: [win32] + + '@vscode/vsce-sign-win32-x64@2.0.2': + resolution: {integrity: sha512-pAiRN6qSAhDM5SVOIxgx+2xnoVUePHbRNC7OD2aOR3WltTKxxF25OfpK8h8UQ7A0BuRkSgREbB59DBlFk4iAeg==} + cpu: [x64] + os: [win32] + + '@vscode/vsce-sign@2.0.5': + resolution: {integrity: sha512-GfYWrsT/vypTMDMgWDm75iDmAOMe7F71sZECJ+Ws6/xyIfmB3ELVnVN+LwMFAvmXY+e6eWhR2EzNGF/zAhWY3Q==} + + '@vscode/vsce@3.2.1': + resolution: {integrity: sha512-AY9vBjwExakK1c0cI/3NN2Ey0EgiKLBye/fxl/ue+o4q6RZ7N+xzd1jAD6eI6eBeMVANi617+V2rxIAkDPco2Q==} + engines: {node: '>= 20'} + hasBin: true + + acorn-jsx@5.3.2: + resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} + peerDependencies: + acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 + + acorn-walk@8.3.4: + resolution: {integrity: sha512-ueEepnujpqee2o5aIYnvHU6C0A42MNdsIDeqy5BydrkuC5R1ZuUFnm27EeFJGoEHJQgn3uleRvmTXaJgfXbt4g==} + engines: {node: '>=0.4.0'} + + acorn@8.14.0: + resolution: {integrity: sha512-cl669nCJTZBsL97OF4kUQm5g5hC2uihk0NxY3WENAC0TYdILVkAyHymAntgxGkl7K+t0cXIrH5siy5S4XkFycA==} + engines: {node: '>=0.4.0'} + hasBin: true + + agent-base@7.1.1: + resolution: {integrity: sha512-H0TSyFNDMomMNJQBn8wFV5YC/2eJ+VXECwOadZJT554xP6cODZHPX3H9QMQECxvrgiSOP1pHjy1sMWQVYJOUOA==} + engines: {node: '>= 14'} + + ajv@6.12.6: + resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==} + + ansi-regex@5.0.1: + resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} + engines: {node: '>=8'} + + ansi-regex@6.1.0: + resolution: {integrity: sha512-7HSX4QQb4CspciLpVFwyRe79O3xsIZDDLER21kERQ71oaPodF8jL725AgJMFAYbooIqolJoRLuM81SpeUkpkvA==} + engines: {node: '>=12'} + + ansi-styles@3.2.1: + resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==} + engines: {node: '>=4'} + + ansi-styles@4.3.0: + resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} + engines: {node: '>=8'} + + ansi-styles@5.2.0: + resolution: {integrity: sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA==} + engines: {node: '>=10'} + + ansi-styles@6.2.1: + resolution: {integrity: sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==} + engines: {node: '>=12'} + + argparse@2.0.1: + resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} + + array-union@2.1.0: + resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} + engines: {node: '>=8'} + + assertion-error@1.1.0: + resolution: {integrity: sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==} + + asynckit@0.4.0: + resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} + + azure-devops-node-api@12.5.0: + resolution: {integrity: sha512-R5eFskGvOm3U/GzeAuxRkUsAl0hrAwGgWn6zAd2KrZmrEhWZVqLew4OOupbQlXUuojUzpGtq62SmdhJ06N88og==} + + balanced-match@1.0.2: + resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} + + base64-js@1.5.1: + resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} + + bl@4.1.0: + resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==} + + boolbase@1.0.0: + resolution: {integrity: sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==} + + brace-expansion@1.1.11: + resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} + + brace-expansion@2.0.1: + resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==} + + braces@3.0.3: + resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} + engines: {node: '>=8'} + + buffer-crc32@0.2.13: + resolution: {integrity: sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==} + + buffer-equal-constant-time@1.0.1: + resolution: {integrity: sha512-zRpUiDwd/xk6ADqPMATG8vc9VPrkck7T07OIx0gnjmJAnHnTVXNQG3vfvWNuiZIkwu9KrKdA1iJKfsfTVxE6NA==} + + buffer@5.7.1: + resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} + + cac@6.7.14: + resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} + engines: {node: '>=8'} + + call-bind@1.0.7: + resolution: {integrity: sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==} + engines: {node: '>= 0.4'} + + callsites@3.1.0: + resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} + engines: {node: '>=6'} + + chai@4.5.0: + resolution: {integrity: sha512-RITGBfijLkBddZvnn8jdqoTypxvqbOLYQkGGxXzeFjVHvudaPw0HNFD9x928/eUwYWd2dPCugVqspGALTZZQKw==} + engines: {node: '>=4'} + + chalk@2.4.2: + resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} + engines: {node: '>=4'} + + chalk@4.1.2: + resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} + engines: {node: '>=10'} + + chalk@5.3.0: + resolution: {integrity: sha512-dLitG79d+GV1Nb/VYcCDFivJeK1hiukt9QjRNVOsUtTy1rR1YJsmpGGTZ3qJos+uw7WmWF4wUwBd9jxjocFC2w==} + engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} + + check-error@1.0.3: + resolution: {integrity: sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg==} + + cheerio-select@2.1.0: + resolution: {integrity: sha512-9v9kG0LvzrlcungtnJtpGNxY+fzECQKhK4EGJX2vByejiMX84MFNQw4UxPJl3bFbTMw+Dfs37XaIkCwTZfLh4g==} + + cheerio@1.0.0: + resolution: {integrity: sha512-quS9HgjQpdaXOvsZz82Oz7uxtXiy6UIsIQcpBj7HRw2M63Skasm9qlDocAM7jNuaxdhpPU7c4kJN+gA5MCu4ww==} + engines: {node: '>=18.17'} + + chevrotain-allstar@0.3.1: + resolution: {integrity: sha512-b7g+y9A0v4mxCW1qUhf3BSVPg+/NvGErk/dOkrDaHA0nQIQGAtrOjlX//9OQtRlSCy+x9rfB5N8yC71lH1nvMw==} + peerDependencies: + chevrotain: ^11.0.0 + + chevrotain@11.0.3: + resolution: {integrity: sha512-ci2iJH6LeIkvP9eJW6gpueU8cnZhv85ELY8w8WiFtNjMHA5ad6pQLaJo9mEly/9qUyCpvqX8/POVUTf18/HFdw==} + + chownr@1.1.4: + resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} + + cliui@8.0.1: + resolution: {integrity: sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==} + engines: {node: '>=12'} + + cockatiel@3.2.1: + resolution: {integrity: sha512-gfrHV6ZPkquExvMh9IOkKsBzNDk6sDuZ6DdBGUBkvFnTCqCxzpuq48RySgP0AnaqQkw2zynOFj9yly6T1Q2G5Q==} + engines: {node: '>=16'} + + color-convert@1.9.3: + resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} + + color-convert@2.0.1: + resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} + engines: {node: '>=7.0.0'} + + color-name@1.1.3: + resolution: {integrity: sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==} + + color-name@1.1.4: + resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} + + combined-stream@1.0.8: + resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} + engines: {node: '>= 0.8'} + + commander@11.0.0: + resolution: {integrity: sha512-9HMlXtt/BNoYr8ooyjjNRdIilOTkVJXB+GhxMTtOKwk0R4j4lS4NpjuqmRxroBfnfTSHQIHQB7wryHhXarNjmQ==} + engines: {node: '>=16'} + + commander@6.2.1: + resolution: {integrity: sha512-U7VdrJFnJgo4xjrHpTzu0yrHPGImdsmD95ZlgYSEajAn2JKzDhDTPG9kBTefmObL2w/ngeZnilk+OV9CG3d7UA==} + engines: {node: '>= 6'} + + concat-map@0.0.1: + resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} + + concurrently@8.2.2: + resolution: {integrity: sha512-1dP4gpXFhei8IOtlXRE/T/4H88ElHgTiUzh71YUmtjTEHMSRS2Z/fgOxHSxxusGHogsRfxNq1vyAwxSC+EVyDg==} + engines: {node: ^14.13.0 || >=16.0.0} + hasBin: true + + confbox@0.1.8: + resolution: {integrity: sha512-RMtmw0iFkeR4YV+fUOSucriAQNb9g8zFR52MWCtl+cCZOFRNL6zeB395vPzFhEjjn4fMxXudmELnl/KF/WrK6w==} + + cross-spawn@7.0.3: + resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} + engines: {node: '>= 8'} + + css-select@5.1.0: + resolution: {integrity: sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg==} + + css-what@6.1.0: + resolution: {integrity: sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==} + engines: {node: '>= 6'} + + date-fns@2.30.0: + resolution: {integrity: sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==} + engines: {node: '>=0.11'} + + debug@4.3.7: + resolution: {integrity: sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true + + decompress-response@6.0.0: + resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==} + engines: {node: '>=10'} + + deep-eql@4.1.4: + resolution: {integrity: sha512-SUwdGfqdKOwxCPeVYjwSyRpJ7Z+fhpwIAtmCUdZIWZ/YP5R9WAsyuSgpLVDi9bjWoN2LXHNss/dk3urXtdQxGg==} + engines: {node: '>=6'} + + deep-extend@0.6.0: + resolution: {integrity: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==} + engines: {node: '>=4.0.0'} + + deep-is@0.1.4: + resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} + + deepmerge@1.5.2: + resolution: {integrity: sha512-95k0GDqvBjZavkuvzx/YqVLv/6YYa17fz6ILMSf7neqQITCPbnfEnQvEgMPNjH4kgobe7+WIL0yJEHku+H3qtQ==} + engines: {node: '>=0.10.0'} + + define-data-property@1.1.4: + resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==} + engines: {node: '>= 0.4'} + + define-lazy-prop@2.0.0: + resolution: {integrity: sha512-Ds09qNh8yw3khSjiJjiUInaGX9xlqZDY7JVryGxdxV7NPeuqQfplOpQ66yJFZut3jLa5zOwkXw1g9EI2uKh4Og==} + engines: {node: '>=8'} + + delayed-stream@1.0.0: + resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} + engines: {node: '>=0.4.0'} + + detect-libc@2.0.3: + resolution: {integrity: sha512-bwy0MGW55bG41VqxxypOsdSdGqLwXPI/focwgTYCFMbdUiBAxLg9CFzG08sz2aqzknwiX7Hkl0bQENjg8iLByw==} + engines: {node: '>=8'} + + diff-sequences@29.6.3: + resolution: {integrity: sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q==} + engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} + + dir-glob@3.0.1: + resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} + engines: {node: '>=8'} + + doctrine@3.0.0: + resolution: {integrity: sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==} + engines: {node: '>=6.0.0'} + + dom-serializer@2.0.0: + resolution: {integrity: sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==} + + domelementtype@2.3.0: + resolution: {integrity: sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==} + + domhandler@5.0.3: + resolution: {integrity: sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==} + engines: {node: '>= 4'} + + domutils@3.1.0: + resolution: {integrity: sha512-H78uMmQtI2AhgDJjWeQmHwJJ2bLPD3GMmO7Zja/ZZh84wkm+4ut+IUnUdRa8uCGX88DiVx1j6FRe1XfxEgjEZA==} + + eastasianwidth@0.2.0: + resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} + + ecdsa-sig-formatter@1.0.11: + resolution: {integrity: sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ==} + + emoji-regex@8.0.0: + resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} + + emoji-regex@9.2.2: + resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==} + + encoding-sniffer@0.2.0: + resolution: {integrity: sha512-ju7Wq1kg04I3HtiYIOrUrdfdDvkyO9s5XM8QAj/bN61Yo/Vb4vgJxy5vi4Yxk01gWHbrofpPtpxM8bKger9jhg==} + + end-of-stream@1.4.4: + resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} + + entities@4.5.0: + resolution: {integrity: sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==} + engines: {node: '>=0.12'} + + es-define-property@1.0.0: + resolution: {integrity: sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==} + engines: {node: '>= 0.4'} + + es-errors@1.3.0: + resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} + engines: {node: '>= 0.4'} + + esbuild@0.21.5: + resolution: {integrity: sha512-mg3OPMV4hXywwpoDxu3Qda5xCKQi+vCTZq8S9J/EpkhB2HzKXq4SNFZE3+NK93JYxc8VMSep+lOUSC/RVKaBqw==} + engines: {node: '>=12'} + hasBin: true + + escalade@3.2.0: + resolution: {integrity: sha512-WUj2qlxaQtO4g6Pq5c29GTcWGDyd8itL8zTlipgECz3JesAiiOKotd8JU6otB3PACgG6xkJUyVhboMS+bje/jA==} + engines: {node: '>=6'} + + escape-string-regexp@1.0.5: + resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} + engines: {node: '>=0.8.0'} + + escape-string-regexp@4.0.0: + resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} + engines: {node: '>=10'} + + eslint-scope@7.2.2: + resolution: {integrity: sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + eslint-visitor-keys@3.4.3: + resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + eslint@8.57.1: + resolution: {integrity: sha512-ypowyDxpVSYpkXr9WPv2PAZCtNip1Mv5KTW0SCurXv/9iOpcrH9PaqUElksqEB6pChqHGDRCFTyrZlGhnLNGiA==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + deprecated: This version is no longer supported. Please see https://eslint.org/version-support for other options. + hasBin: true + + espree@9.6.1: + resolution: {integrity: sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + + esquery@1.6.0: + resolution: {integrity: sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==} + engines: {node: '>=0.10'} + + esrecurse@4.3.0: + resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} + engines: {node: '>=4.0'} + + estraverse@5.3.0: + resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} + engines: {node: '>=4.0'} + + estree-walker@3.0.3: + resolution: {integrity: sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==} + + esutils@2.0.3: + resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} + engines: {node: '>=0.10.0'} + + events@3.3.0: + resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} + engines: {node: '>=0.8.x'} + + execa@8.0.1: + resolution: {integrity: sha512-VyhnebXciFV2DESc+p6B+y0LjSm0krU4OgJN44qFAhBY0TJ+1V61tYD2+wHusZ6F9n5K+vl8k0sTy7PEfV4qpg==} + engines: {node: '>=16.17'} + + expand-template@2.0.3: + resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==} + engines: {node: '>=6'} + + fast-deep-equal@3.1.3: + resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} + + fast-glob@3.3.2: + resolution: {integrity: sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==} + engines: {node: '>=8.6.0'} + + fast-json-stable-stringify@2.1.0: + resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} + + fast-levenshtein@2.0.6: + resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} + + fastq@1.17.1: + resolution: {integrity: sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==} + + fd-slicer@1.1.0: + resolution: {integrity: sha512-cE1qsB/VwyQozZ+q1dGxR8LBYNZeofhEdUNGSMbQD3Gw2lAzX9Zb3uIU6Ebc/Fmyjo9AWWfnn0AUCHqtevs/8g==} + + file-entry-cache@6.0.1: + resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} + engines: {node: ^10.12.0 || >=12.0.0} + + fill-range@7.1.1: + resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} + engines: {node: '>=8'} + + find-up@5.0.0: + resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} + engines: {node: '>=10'} + + flat-cache@3.2.0: + resolution: {integrity: sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==} + engines: {node: ^10.12.0 || >=12.0.0} + + flatted@3.3.1: + resolution: {integrity: sha512-X8cqMLLie7KsNUDSdzeN8FYK9rEt4Dt67OsG/DNGnYTSDBG4uFAJFBnUeiV+zCVAvwFy56IjM9sH51jVaEhNxw==} + + foreground-child@3.3.0: + resolution: {integrity: sha512-Ld2g8rrAyMYFXBhEqMz8ZAHBi4J4uS1i/CxGMDnjyFWddMXLVcDp051DZfu+t7+ab7Wv6SMqpWmyFIj5UbfFvg==} + engines: {node: '>=14'} + + form-data@4.0.1: + resolution: {integrity: sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw==} + engines: {node: '>= 6'} + + fs-constants@1.0.0: + resolution: {integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==} + + fs-extra@11.1.1: + resolution: {integrity: sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ==} + engines: {node: '>=14.14'} + + fs.realpath@1.0.0: + resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} + + fsevents@2.3.3: + resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] + + function-bind@1.1.2: + resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} + + get-caller-file@2.0.5: + resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} + engines: {node: 6.* || 8.* || >= 10.*} + + get-func-name@2.0.2: + resolution: {integrity: sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ==} + + get-intrinsic@1.2.4: + resolution: {integrity: sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==} + engines: {node: '>= 0.4'} + + get-stream@8.0.1: + resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==} + engines: {node: '>=16'} + + github-from-package@0.0.0: + resolution: {integrity: sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==} + + glob-parent@5.1.2: + resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} + engines: {node: '>= 6'} + + glob-parent@6.0.2: + resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} + engines: {node: '>=10.13.0'} + + glob@11.0.0: + resolution: {integrity: sha512-9UiX/Bl6J2yaBbxKoEBRm4Cipxgok8kQYcOPEhScPwebu2I0HoQOuYdIO6S3hLuWoZgpDpwQZMzTFxgpkyT76g==} + engines: {node: 20 || >=22} + hasBin: true + + glob@7.2.3: + resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + deprecated: Glob versions prior to v9 are no longer supported + + globals@13.24.0: + resolution: {integrity: sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==} + engines: {node: '>=8'} + + globby@11.1.0: + resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} + engines: {node: '>=10'} + + gopd@1.0.1: + resolution: {integrity: sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==} + + graceful-fs@4.2.11: + resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} + + graphemer@1.4.0: + resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} + + has-flag@3.0.0: + resolution: {integrity: sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==} + engines: {node: '>=4'} + + has-flag@4.0.0: + resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} + engines: {node: '>=8'} + + has-property-descriptors@1.0.2: + resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==} + + has-proto@1.0.3: + resolution: {integrity: sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==} + engines: {node: '>= 0.4'} + + has-symbols@1.0.3: + resolution: {integrity: sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==} + engines: {node: '>= 0.4'} + + hasown@2.0.2: + resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==} + engines: {node: '>= 0.4'} + + hosted-git-info@4.1.0: + resolution: {integrity: sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==} + engines: {node: '>=10'} + + htmlparser2@9.1.0: + resolution: {integrity: sha512-5zfg6mHUoaer/97TxnGpxmbR7zJtPwIYFMZ/H5ucTlPZhKvtum05yiPK3Mgai3a0DyVxv7qYqoweaEd2nrYQzQ==} + + http-proxy-agent@7.0.2: + resolution: {integrity: sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==} + engines: {node: '>= 14'} + + https-proxy-agent@7.0.5: + resolution: {integrity: sha512-1e4Wqeblerz+tMKPIq2EMGiiWW1dIjZOksyHWSUm1rmuvw/how9hBHZ38lAGj5ID4Ik6EdkOw7NmWPy6LAwalw==} + engines: {node: '>= 14'} + + human-signals@5.0.0: + resolution: {integrity: sha512-AXcZb6vzzrFAUE61HnN4mpLqd/cSIwNQjtNWR0euPm6y0iqx3G4gOXaIDdtdDwZmhwe82LA6+zinmW4UBWVePQ==} + engines: {node: '>=16.17.0'} + + iconv-lite@0.6.3: + resolution: {integrity: sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==} + engines: {node: '>=0.10.0'} + + ieee754@1.2.1: + resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} + + ignore@5.3.2: + resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==} + engines: {node: '>= 4'} + + import-fresh@3.3.0: + resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==} + engines: {node: '>=6'} + + imurmurhash@0.1.4: + resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} + engines: {node: '>=0.8.19'} + + inflight@1.0.6: + resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful. + + inherits@2.0.4: + resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + + ini@1.3.8: + resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} + + interpret@1.4.0: + resolution: {integrity: sha512-agE4QfB2Lkp9uICn7BAqoscw4SZP9kTE2hxiFI3jBPmXJfdqiahTbUuKGsMoN2GtqL9AxhYioAcVvgsb1HvRbA==} + engines: {node: '>= 0.10'} + + is-core-module@2.15.1: + resolution: {integrity: sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==} + engines: {node: '>= 0.4'} + + is-docker@2.2.1: + resolution: {integrity: sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==} + engines: {node: '>=8'} + hasBin: true + + is-extglob@2.1.1: + resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} + engines: {node: '>=0.10.0'} + + is-fullwidth-code-point@3.0.0: + resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} + engines: {node: '>=8'} + + is-glob@4.0.3: + resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} + engines: {node: '>=0.10.0'} + + is-number@7.0.0: + resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} + engines: {node: '>=0.12.0'} + + is-path-inside@3.0.3: + resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} + engines: {node: '>=8'} + + is-stream@3.0.0: + resolution: {integrity: sha512-LnQR4bZ9IADDRSkvpqMGvt/tEJWclzklNgSw48V5EAaAeDd6qGvN8ei6k5p0tvxSR171VmGyHuTiAOfxAbr8kA==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + + is-wsl@2.2.0: + resolution: {integrity: sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==} + engines: {node: '>=8'} + + isexe@2.0.0: + resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} + + jackspeak@4.0.2: + resolution: {integrity: sha512-bZsjR/iRjl1Nk1UkjGpAzLNfQtzuijhn2g+pbZb98HQ1Gk8vM9hfbxeMBP+M2/UUdwj0RqGG3mlvk2MsAqwvEw==} + engines: {node: 20 || >=22} + + js-tokens@9.0.0: + resolution: {integrity: sha512-WriZw1luRMlmV3LGJaR6QOJjWwgLUTf89OwT2lUOyjX2dJGBwgmIkbcz+7WFZjrZM635JOIR517++e/67CP9dQ==} + + js-yaml@4.1.0: + resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==} + hasBin: true + + json-buffer@3.0.1: + resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==} + + json-schema-traverse@0.4.1: + resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} + + json-stable-stringify-without-jsonify@1.0.1: + resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} + + jsonc-parser@3.3.1: + resolution: {integrity: sha512-HUgH65KyejrUFPvHFPbqOY0rsFip3Bo5wb4ngvdi1EpCYWUQDC5V+Y7mZws+DLkr4M//zQJoanu1SP+87Dv1oQ==} + + jsonfile@6.1.0: + resolution: {integrity: sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==} + + jsonschema@1.4.1: + resolution: {integrity: sha512-S6cATIPVv1z0IlxdN+zUk5EPjkGCdnhN4wVSBlvoUO1tOLJootbo9CquNJmbIh4yikWHiUedhRYrNPn1arpEmQ==} + + jsonwebtoken@9.0.2: + resolution: {integrity: sha512-PRp66vJ865SSqOlgqS8hujT5U4AOgMfhrwYIuIhfKaoSCZcirrmASQr8CX7cUg+RMih+hgznrjp99o+W4pJLHQ==} + engines: {node: '>=12', npm: '>=6'} + + jwa@1.4.1: + resolution: {integrity: sha512-qiLX/xhEEFKUAJ6FiBMbes3w9ATzyk5W7Hvzpa/SLYdxNtng+gcurvrI7TbACjIXlsJyr05/S1oUhZrc63evQA==} + + jwa@2.0.0: + resolution: {integrity: sha512-jrZ2Qx916EA+fq9cEAeCROWPTfCwi1IVHqT2tapuqLEVVDKFDENFw1oL+MwrTvH6msKxsd1YTDVw6uKEcsrLEA==} + + jws@3.2.2: + resolution: {integrity: sha512-YHlZCB6lMTllWDtSPHz/ZXTsi8S00usEV6v1tjq8tOUZzw7DpSDWVXjXDre6ed1w/pd495ODpHZYSdkRTsa0HA==} + + jws@4.0.0: + resolution: {integrity: sha512-KDncfTmOZoOMTFG4mBlG0qUIOlc03fmzH+ru6RgYVZhPkyiy/92Owlt/8UEN+a4TXR1FQetfIpJE8ApdvdVxTg==} + + keytar@7.9.0: + resolution: {integrity: sha512-VPD8mtVtm5JNtA2AErl6Chp06JBfy7diFQ7TQQhdpWOl6MrCRB+eRbvAZUsbGQS9kiMq0coJsy0W0vHpDCkWsQ==} + + keyv@4.5.4: + resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} + + langium-cli@3.2.0: + resolution: {integrity: sha512-4JWeCMuTHyFO+GCnOVT8+jygdob4KnU0uh/26cMxgZ1FlenAk8zrOnrXbuUzIm0FAIetCqrR6GUXqeko+Vg5og==} + engines: {node: '>=16.0.0'} + hasBin: true + + langium-railroad@3.2.0: + resolution: {integrity: sha512-8wJqRid1udSH9PKo8AkRrJCUNHQ6Xu9tGi+//bLdHGDdlK9gpps1AwO71ufE864/so77K4ZmqBuLnBnxPcGs/Q==} + + langium@3.2.0: + resolution: {integrity: sha512-HxAPgCVC7X+dCN99QKlZMEoaLW4s/mt0IImYrP6ooEBOMh8lJYdFNNSpJ5NIOE+WFwQd3xa2phTJDmJhOWVR7A==} + engines: {node: '>=16.0.0'} + + leven@3.1.0: + resolution: {integrity: sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==} + engines: {node: '>=6'} + + levn@0.4.1: + resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} + engines: {node: '>= 0.8.0'} + + linkify-it@5.0.0: + resolution: {integrity: sha512-5aHCbzQRADcdP+ATqnDuhhJ/MRIqDkZX5pyjFHRRysS8vZ5AbqGEoFIb6pYHPZ+L/OC2Lc+xT8uHVVR5CAK/wQ==} + + local-pkg@0.5.0: + resolution: {integrity: sha512-ok6z3qlYyCDS4ZEU27HaU6x/xZa9Whf8jD4ptH5UZTQYZVYeb9bnZ3ojVhiJNLiXK1Hfc0GNbLXcmZ5plLDDBg==} + engines: {node: '>=14'} + + locate-path@6.0.0: + resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} + engines: {node: '>=10'} + + lodash-es@4.17.21: + resolution: {integrity: sha512-mKnC+QJ9pWVzv+C4/U3rRsHapFfHvQFoFB92e52xeyGMcX6/OlIl78je1u8vePzYZSkkogMPJ2yjxxsb89cxyw==} + + lodash.includes@4.3.0: + resolution: {integrity: sha512-W3Bx6mdkRTGtlJISOvVD/lbqjTlPPUDTMnlXZFnVwi9NKJ6tiAk6LVdlhZMm17VZisqhKcgzpO5Wz91PCt5b0w==} + + lodash.isboolean@3.0.3: + resolution: {integrity: sha512-Bz5mupy2SVbPHURB98VAcw+aHh4vRV5IPNhILUCsOzRmsTmSQ17jIuqopAentWoehktxGd9e/hbIXq980/1QJg==} + + lodash.isinteger@4.0.4: + resolution: {integrity: sha512-DBwtEWN2caHQ9/imiNeEA5ys1JoRtRfY3d7V9wkqtbycnAmTvRRmbHKDV4a0EYc678/dia0jrte4tjYwVBaZUA==} + + lodash.isnumber@3.0.3: + resolution: {integrity: sha512-QYqzpfwO3/CWf3XP+Z+tkQsfaLL/EnUlXWVkIk5FUPc4sBdTehEqZONuyRt2P67PXAk+NXmTBcc97zw9t1FQrw==} + + lodash.isplainobject@4.0.6: + resolution: {integrity: sha512-oSXzaWypCMHkPC3NvBEaPHf0KsA5mvPrOPgQWDsbg8n7orZ290M0BmC/jgRZ4vcJ6DTAhjrsSYgdsW/F+MFOBA==} + + lodash.isstring@4.0.1: + resolution: {integrity: sha512-0wJxfxH1wgO3GrbuP+dTTk7op+6L41QCXbGINEmD+ny/G/eCqGzxyCsh7159S+mgDDcoarnBw6PC1PS5+wUGgw==} + + lodash.merge@4.6.2: + resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} + + lodash.once@4.1.1: + resolution: {integrity: sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==} + + lodash@4.17.21: + resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} + + loupe@2.3.7: + resolution: {integrity: sha512-zSMINGVYkdpYSOBmLi0D1Uo7JU9nVdQKrHxC8eYlV+9YKK9WePqAlL7lSlorG/U2Fw1w0hTBmaa/jrQ3UbPHtA==} + + lru-cache@11.0.1: + resolution: {integrity: sha512-CgeuL5uom6j/ZVrg7G/+1IXqRY8JXX4Hghfy5YE0EhoYQWvndP1kufu58cmZLNIDKnRhZrXfdS9urVWx98AipQ==} + engines: {node: 20 || >=22} + + lru-cache@6.0.0: + resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} + engines: {node: '>=10'} + + magic-string@0.30.12: + resolution: {integrity: sha512-Ea8I3sQMVXr8JhN4z+H/d8zwo+tYDgHE9+5G4Wnrwhs0gaK9fXTKx0Tw5Xwsd/bCPTTZNRAdpyzvoeORe9LYpw==} + + markdown-it@14.1.0: + resolution: {integrity: sha512-a54IwgWPaeBCAAsv13YgmALOF1elABB08FxO9i+r4VFk5Vl4pKokRPeX8u5TCgSsPi6ec1otfLjdOpVcgbpshg==} + hasBin: true + + mdurl@2.0.0: + resolution: {integrity: sha512-Lf+9+2r+Tdp5wXDXC4PcIBjTDtq4UKjCPMQhKIuzpJNW0b96kVqSwW0bT7FhRSfmAiFYgP+SCRvdrDozfh0U5w==} + + merge-stream@2.0.0: + resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} + + merge2@1.4.1: + resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} + engines: {node: '>= 8'} + + micromatch@4.0.8: + resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} + engines: {node: '>=8.6'} + + mime-db@1.52.0: + resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} + engines: {node: '>= 0.6'} + + mime-types@2.1.35: + resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} + engines: {node: '>= 0.6'} + + mime@1.6.0: + resolution: {integrity: sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==} + engines: {node: '>=4'} + hasBin: true + + mimic-fn@4.0.0: + resolution: {integrity: sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==} + engines: {node: '>=12'} + + mimic-response@3.1.0: + resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} + engines: {node: '>=10'} + + minimatch@10.0.1: + resolution: {integrity: sha512-ethXTt3SGGR+95gudmqJ1eNhRO7eGEGIgYA9vnPatK4/etz2MEVDno5GMCibdMTuBMyElzIlgxMna3K94XDIDQ==} + engines: {node: 20 || >=22} + + minimatch@3.1.2: + resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} + + minimatch@5.1.6: + resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} + engines: {node: '>=10'} + + minimatch@9.0.5: + resolution: {integrity: sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==} + engines: {node: '>=16 || 14 >=14.17'} + + minimist@1.2.8: + resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} + + minipass@7.1.2: + resolution: {integrity: sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==} + engines: {node: '>=16 || 14 >=14.17'} + + mkdirp-classic@0.5.3: + resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==} + + mlly@1.7.2: + resolution: {integrity: sha512-tN3dvVHYVz4DhSXinXIk7u9syPYaJvio118uomkovAtWBT+RdbP6Lfh/5Lvo519YMmwBafwlh20IPTXIStscpA==} + + ms@2.1.3: + resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} + + mute-stream@0.0.8: + resolution: {integrity: sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==} + + nanoid@3.3.7: + resolution: {integrity: sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true + + napi-build-utils@1.0.2: + resolution: {integrity: sha512-ONmRUqK7zj7DWX0D9ADe03wbwOBZxNAfF20PlGfCWQcD3+/MakShIHrMqx9YwPTfxDdF1zLeL+RGZiR9kGMLdg==} + + natural-compare@1.4.0: + resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} + + node-abi@3.71.0: + resolution: {integrity: sha512-SZ40vRiy/+wRTf21hxkkEjPJZpARzUMVcJoQse2EF8qkUWbbO2z7vd5oA/H6bVH6SZQ5STGcu0KRDS7biNRfxw==} + engines: {node: '>=10'} + + node-addon-api@4.3.0: + resolution: {integrity: sha512-73sE9+3UaLYYFmDsFZnqCInzPyh3MqIwZO9cw58yIqAZhONrrabrYyYe3TuIqtIiOuTXVhsGau8hcrhhwSsDIQ==} + + npm-run-path@5.3.0: + resolution: {integrity: sha512-ppwTtiJZq0O/ai0z7yfudtBpWIoxM8yE6nHi1X47eFR2EWORqfbu6CnPlNsjeN683eT0qG6H/Pyf9fCcvjnnnQ==} + engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} + + nth-check@2.1.1: + resolution: {integrity: sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==} + + object-inspect@1.13.2: + resolution: {integrity: sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==} + engines: {node: '>= 0.4'} + + once@1.4.0: + resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} + + onetime@6.0.0: + resolution: {integrity: sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==} + engines: {node: '>=12'} + + open@8.4.2: + resolution: {integrity: sha512-7x81NCL719oNbsq/3mh+hVrAWmFuEYUqrq/Iw3kUzH8ReypT9QQ0BLoJS7/G9k6N81XjW4qHWtjWwe/9eLy1EQ==} + engines: {node: '>=12'} + + optionator@0.9.4: + resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==} + engines: {node: '>= 0.8.0'} + + p-limit@3.1.0: + resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} + engines: {node: '>=10'} + + p-limit@5.0.0: + resolution: {integrity: sha512-/Eaoq+QyLSiXQ4lyYV23f14mZRQcXnxfHrN0vCai+ak9G0pp9iEQukIIZq5NccEvwRB8PUnZT0KsOoDCINS1qQ==} + engines: {node: '>=18'} + + p-locate@5.0.0: + resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} + engines: {node: '>=10'} + + package-json-from-dist@1.0.1: + resolution: {integrity: sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==} + + parent-module@1.0.1: + resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} + engines: {node: '>=6'} + + parse-semver@1.1.1: + resolution: {integrity: sha512-Eg1OuNntBMH0ojvEKSrvDSnwLmvVuUOSdylH/pSCPNMIspLlweJyIWXCE+k/5hm3cj/EBUYwmWkjhBALNP4LXQ==} + + parse5-htmlparser2-tree-adapter@7.1.0: + resolution: {integrity: sha512-ruw5xyKs6lrpo9x9rCZqZZnIUntICjQAd0Wsmp396Ul9lN/h+ifgVV1x1gZHi8euej6wTfpqX8j+BFQxF0NS/g==} + + parse5-parser-stream@7.1.2: + resolution: {integrity: sha512-JyeQc9iwFLn5TbvvqACIF/VXG6abODeB3Fwmv/TGdLk2LfbWkaySGY72at4+Ty7EkPZj854u4CrICqNk2qIbow==} + + parse5@7.2.1: + resolution: {integrity: sha512-BuBYQYlv1ckiPdQi/ohiivi9Sagc9JG+Ozs0r7b/0iK3sKmrb0b9FdWdBbOdx6hBCM/F9Ir82ofnBhtZOjCRPQ==} + + path-exists@4.0.0: + resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} + engines: {node: '>=8'} + + path-is-absolute@1.0.1: + resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} + engines: {node: '>=0.10.0'} + + path-key@3.1.1: + resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} + engines: {node: '>=8'} + + path-key@4.0.0: + resolution: {integrity: sha512-haREypq7xkM7ErfgIyA0z+Bj4AGKlMSdlQE2jvJo6huWD1EdkKYV+G/T4nq0YEF2vgTT8kqMFKo1uHn950r4SQ==} + engines: {node: '>=12'} + + path-parse@1.0.7: + resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} + + path-scurry@2.0.0: + resolution: {integrity: sha512-ypGJsmGtdXUOeM5u93TyeIEfEhM6s+ljAhrk5vAvSx8uyY/02OvrZnA0YNGUrPXfpJMgI1ODd3nwz8Npx4O4cg==} + engines: {node: 20 || >=22} + + path-type@4.0.0: + resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} + engines: {node: '>=8'} + + pathe@1.1.2: + resolution: {integrity: sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==} + + pathval@1.1.1: + resolution: {integrity: sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==} + + pend@1.2.0: + resolution: {integrity: sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==} + + picocolors@1.1.1: + resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} + + picomatch@2.3.1: + resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} + engines: {node: '>=8.6'} + + pkg-types@1.2.1: + resolution: {integrity: sha512-sQoqa8alT3nHjGuTjuKgOnvjo4cljkufdtLMnO2LBP/wRwuDlo1tkaEdMxCRhyGRPacv/ztlZgDPm2b7FAmEvw==} + + postcss@8.4.47: + resolution: {integrity: sha512-56rxCq7G/XfB4EkXq9Egn5GCqugWvDFjafDOThIdMBsI15iqPqR5r15TfSr1YPYeEI19YeaXMCbY6u88Y76GLQ==} + engines: {node: ^10 || ^12 || >=14} + + prebuild-install@7.1.2: + resolution: {integrity: sha512-UnNke3IQb6sgarcZIDU3gbMeTp/9SSU1DAIkil7PrqG1vZlBtY5msYccSKSHDqa3hNg436IXK+SNImReuA1wEQ==} + engines: {node: '>=10'} + hasBin: true + + prelude-ls@1.2.1: + resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} + engines: {node: '>= 0.8.0'} + + pretty-format@29.7.0: + resolution: {integrity: sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ==} + engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} + + pump@3.0.2: + resolution: {integrity: sha512-tUPXtzlGM8FE3P0ZL6DVs/3P58k9nk8/jZeQCurTJylQA8qFYzHFfhBJkuqyE0FifOsQ0uKWekiZ5g8wtr28cw==} + + punycode.js@2.3.1: + resolution: {integrity: sha512-uxFIHU0YlHYhDQtV4R9J6a52SLx28BCjT+4ieh7IGbgwVJWO+km431c4yRlREUAsAmt/uMjQUyQHNEPf0M39CA==} + engines: {node: '>=6'} + + punycode@2.3.1: + resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} + engines: {node: '>=6'} + + qs@6.13.0: + resolution: {integrity: sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==} + engines: {node: '>=0.6'} + + queue-microtask@1.2.3: + resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} + + railroad-diagrams@1.0.0: + resolution: {integrity: sha512-cz93DjNeLY0idrCNOH6PviZGRN9GJhsdm9hpn1YCS879fj4W+x5IFJhhkRZcwVgMmFF7R82UA/7Oh+R8lLZg6A==} + + rc@1.2.8: + resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==} + hasBin: true + + react-is@18.3.1: + resolution: {integrity: sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==} + + read@1.0.7: + resolution: {integrity: sha512-rSOKNYUmaxy0om1BNjMN4ezNT6VKK+2xF4GBhc81mkH7L60i6dp8qPYrkndNLT3QPphoII3maL9PVC9XmhHwVQ==} + engines: {node: '>=0.8'} + + readable-stream@3.6.2: + resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==} + engines: {node: '>= 6'} + + rechoir@0.6.2: + resolution: {integrity: sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw==} + engines: {node: '>= 0.10'} + + regenerator-runtime@0.14.1: + resolution: {integrity: sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==} + + require-directory@2.1.1: + resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} + engines: {node: '>=0.10.0'} + + resolve-from@4.0.0: + resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} + engines: {node: '>=4'} + + resolve@1.22.8: + resolution: {integrity: sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==} + hasBin: true + + reusify@1.0.4: + resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} + engines: {iojs: '>=1.0.0', node: '>=0.10.0'} + + rimraf@3.0.2: + resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} + deprecated: Rimraf versions prior to v4 are no longer supported + hasBin: true + + rollup@4.24.2: + resolution: {integrity: sha512-do/DFGq5g6rdDhdpPq5qb2ecoczeK6y+2UAjdJ5trjQJj5f1AiVdLRWRc9A9/fFukfvJRgM0UXzxBIYMovm5ww==} + engines: {node: '>=18.0.0', npm: '>=8.0.0'} + hasBin: true + + run-parallel@1.2.0: + resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==} + + rxjs@7.8.1: + resolution: {integrity: sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg==} + + safe-buffer@5.2.1: + resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} + + safer-buffer@2.1.2: + resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + + sax@1.4.1: + resolution: {integrity: sha512-+aWOz7yVScEGoKNd4PA10LZ8sk0A/z5+nXQG5giUO5rprX9jgYsTdov9qCchZiPIZezbZH+jRut8nPodFAX4Jg==} + + semver@5.7.2: + resolution: {integrity: sha512-cBznnQ9KjJqU67B52RMC65CMarK2600WFnbkcaiwWq3xy/5haFJlshgnpjovMVJ+Hff49d8GEn0b87C5pDQ10g==} + hasBin: true + + semver@7.6.3: + resolution: {integrity: sha512-oVekP1cKtI+CTDvHWYFUcMtsK/00wmAEfyqKfNdARm8u1wNVhSgaX7A8d4UuIlUI5e84iEwOhs7ZPYRmzU9U6A==} + engines: {node: '>=10'} + hasBin: true + + set-function-length@1.2.2: + resolution: {integrity: sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==} + engines: {node: '>= 0.4'} + + shebang-command@2.0.0: + resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} + engines: {node: '>=8'} + + shebang-regex@3.0.0: + resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} + engines: {node: '>=8'} + + shell-quote@1.8.1: + resolution: {integrity: sha512-6j1W9l1iAs/4xYBI1SYOVZyFcCis9b4KCLQ8fgAGG07QvzaRLVVRQvAy85yNmmZSjYjg4MWh4gNvlPujU/5LpA==} + + shelljs@0.8.5: + resolution: {integrity: sha512-TiwcRcrkhHvbrZbnRcFYMLl30Dfov3HKqzp5tO5b4pt6G/SezKcYhmDg15zXVBswHmctSAQKznqNW2LO5tTDow==} + engines: {node: '>=4'} + hasBin: true + + shx@0.3.4: + resolution: {integrity: sha512-N6A9MLVqjxZYcVn8hLmtneQWIJtp8IKzMP4eMnx+nqkvXoqinUPCbUFLp2UcWTEIUONhlk0ewxr/jaVGlc+J+g==} + engines: {node: '>=6'} + hasBin: true + + side-channel@1.0.6: + resolution: {integrity: sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==} + engines: {node: '>= 0.4'} + + siginfo@2.0.0: + resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==} + + signal-exit@4.1.0: + resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} + engines: {node: '>=14'} + + simple-concat@1.0.1: + resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==} + + simple-get@4.0.1: + resolution: {integrity: sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==} + + slash@3.0.0: + resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} + engines: {node: '>=8'} + + source-map-js@1.2.1: + resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} + engines: {node: '>=0.10.0'} + + spawn-command@0.0.2: + resolution: {integrity: sha512-zC8zGoGkmc8J9ndvml8Xksr1Amk9qBujgbF0JAIWO7kXr43w0h/0GJNM/Vustixu+YE8N/MTrQ7N31FvHUACxQ==} + + stackback@0.0.2: + resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==} + + std-env@3.7.0: + resolution: {integrity: sha512-JPbdCEQLj1w5GilpiHAx3qJvFndqybBysA3qUOnznweH4QbNYUsW/ea8QzSrnh0vNsezMMw5bcVool8lM0gwzg==} + + stoppable@1.1.0: + resolution: {integrity: sha512-KXDYZ9dszj6bzvnEMRYvxgeTHU74QBFL54XKtP3nyMuJ81CFYtABZ3bAzL2EdFUaEwJOBOgENyFj3R7oTzDyyw==} + engines: {node: '>=4', npm: '>=6'} + + string-width@4.2.3: + resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} + engines: {node: '>=8'} + + string-width@5.1.2: + resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==} + engines: {node: '>=12'} + + string_decoder@1.3.0: + resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} + + strip-ansi@6.0.1: + resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} + engines: {node: '>=8'} + + strip-ansi@7.1.0: + resolution: {integrity: sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==} + engines: {node: '>=12'} + + strip-final-newline@3.0.0: + resolution: {integrity: sha512-dOESqjYr96iWYylGObzd39EuNTa5VJxyvVAEm5Jnh7KGo75V43Hk1odPQkNDyXNmUR6k+gEiDVXnjB8HJ3crXw==} + engines: {node: '>=12'} + + strip-json-comments@2.0.1: + resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} + engines: {node: '>=0.10.0'} + + strip-json-comments@3.1.1: + resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} + engines: {node: '>=8'} + + strip-literal@2.1.0: + resolution: {integrity: sha512-Op+UycaUt/8FbN/Z2TWPBLge3jWrP3xj10f3fnYxf052bKuS3EKs1ZQcVGjnEMdsNVAM+plXRdmjrZ/KgG3Skw==} + + supports-color@5.5.0: + resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} + engines: {node: '>=4'} + + supports-color@7.2.0: + resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} + engines: {node: '>=8'} + + supports-color@8.1.1: + resolution: {integrity: sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==} + engines: {node: '>=10'} + + supports-preserve-symlinks-flag@1.0.0: + resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} + engines: {node: '>= 0.4'} + + tar-fs@2.1.1: + resolution: {integrity: sha512-V0r2Y9scmbDRLCNex/+hYzvp/zyYjvFbHPNgVTKfQvVrb6guiE/fxP+XblDNR011utopbkex2nM4dHNV6GDsng==} + + tar-stream@2.2.0: + resolution: {integrity: sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==} + engines: {node: '>=6'} + + text-table@0.2.0: + resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} + + tinybench@2.9.0: + resolution: {integrity: sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==} + + tinypool@0.8.4: + resolution: {integrity: sha512-i11VH5gS6IFeLY3gMBQ00/MmLncVP7JLXOw1vlgkytLmJK7QnEr7NXf0LBdxfmNPAeyetukOk0bOYrJrFGjYJQ==} + engines: {node: '>=14.0.0'} + + tinyspy@2.2.1: + resolution: {integrity: sha512-KYad6Vy5VDWV4GH3fjpseMQ/XU2BhIYP7Vzd0LG44qRWm/Yt2WCOTicFdvmgo6gWaqooMQCawTtILVQJupKu7A==} + engines: {node: '>=14.0.0'} + + tmp@0.2.3: + resolution: {integrity: sha512-nZD7m9iCPC5g0pYmcaxogYKggSfLsdxl8of3Q/oIbqCqLLIO9IAF0GWjX1z9NZRHPiXv8Wex4yDCaZsgEw0Y8w==} + engines: {node: '>=14.14'} + + to-regex-range@5.0.1: + resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} + engines: {node: '>=8.0'} + + tree-kill@1.2.2: + resolution: {integrity: sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==} + hasBin: true + + ts-api-utils@1.3.0: + resolution: {integrity: sha512-UQMIo7pb8WRomKR1/+MFVLTroIvDVtMX3K6OUir8ynLyzB8Jeriont2bTAtmNPa1ekAgN7YPDyf6V+ygrdU+eQ==} + engines: {node: '>=16'} + peerDependencies: + typescript: '>=4.2.0' + + tslib@2.8.0: + resolution: {integrity: sha512-jWVzBLplnCmoaTr13V9dYbiQ99wvZRd0vNWaDRg+aVYRcjDF3nDksxFDE/+fkXnKhpnUUkmx5pK/v8mCtLVqZA==} + + tunnel-agent@0.6.0: + resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} + + tunnel@0.0.6: + resolution: {integrity: sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==} + engines: {node: '>=0.6.11 <=0.7.0 || >=0.7.3'} + + type-check@0.4.0: + resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} + engines: {node: '>= 0.8.0'} + + type-detect@4.1.0: + resolution: {integrity: sha512-Acylog8/luQ8L7il+geoSxhEkazvkslg7PSNKOX59mbB9cOveP5aq9h74Y7YU8yDpJwetzQQrfIwtf4Wp4LKcw==} + engines: {node: '>=4'} + + type-fest@0.20.2: + resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} + engines: {node: '>=10'} + + typed-rest-client@1.8.11: + resolution: {integrity: sha512-5UvfMpd1oelmUPRbbaVnq+rHP7ng2cE4qoQkQeAqxRL6PklkxsM0g32/HL0yfvruK6ojQ5x8EE+HF4YV6DtuCA==} + + typescript@5.4.5: + resolution: {integrity: sha512-vcI4UpRgg81oIRUFwR0WSIHKt11nJ7SAVlYNIu+QpqeyXP+gpQJy/Z4+F0aGxSE4MqwjyXvW/TzgkLAx2AGHwQ==} + engines: {node: '>=14.17'} + hasBin: true + + uc.micro@2.1.0: + resolution: {integrity: sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==} + + ufo@1.5.4: + resolution: {integrity: sha512-UsUk3byDzKd04EyoZ7U4DOlxQaD14JUKQl6/P7wiX4FNvUfm3XL246n9W5AmqwW5RSFJ27NAuM0iLscAOYUiGQ==} + + underscore@1.13.7: + resolution: {integrity: sha512-GMXzWtsc57XAtguZgaQViUOzs0KTkk8ojr3/xAxXLITqf/3EMwxC0inyETfDFjH/Krbhuep0HNbbjI9i/q3F3g==} + + undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + + undici@6.20.1: + resolution: {integrity: sha512-AjQF1QsmqfJys+LXfGTNum+qw4S88CojRInG/6t31W/1fk6G59s92bnAvGz5Cmur+kQv2SURXEvvudLmbrE8QA==} + engines: {node: '>=18.17'} + + universalify@2.0.1: + resolution: {integrity: sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==} + engines: {node: '>= 10.0.0'} + + uri-js@4.4.1: + resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + + url-join@4.0.1: + resolution: {integrity: sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA==} + + util-deprecate@1.0.2: + resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} + + uuid@8.3.2: + resolution: {integrity: sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==} + hasBin: true + + vite-node@1.6.0: + resolution: {integrity: sha512-de6HJgzC+TFzOu0NTC4RAIsyf/DY/ibWDYQUcuEA84EMHhcefTUGkjFHKKEJhQN4A+6I0u++kr3l36ZF2d7XRw==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + + vite@5.4.10: + resolution: {integrity: sha512-1hvaPshuPUtxeQ0hsVH3Mud0ZanOLwVTneA1EgbAM5LhaZEqyPWGRQ7BtaMvUrTDeEaC8pxtj6a6jku3x4z6SQ==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + peerDependencies: + '@types/node': ^18.0.0 || >=20.0.0 + less: '*' + lightningcss: ^1.21.0 + sass: '*' + sass-embedded: '*' + stylus: '*' + sugarss: '*' + terser: ^5.4.0 + peerDependenciesMeta: + '@types/node': + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + + vitest@1.6.0: + resolution: {integrity: sha512-H5r/dN06swuFnzNFhq/dnz37bPXnq8xB2xB5JOVk8K09rUtoeNN+LHWkoQ0A/i3hvbUKKcCei9KpbxqHMLhLLA==} + engines: {node: ^18.0.0 || >=20.0.0} + hasBin: true + peerDependencies: + '@edge-runtime/vm': '*' + '@types/node': ^18.0.0 || >=20.0.0 + '@vitest/browser': 1.6.0 + '@vitest/ui': 1.6.0 + happy-dom: '*' + jsdom: '*' + peerDependenciesMeta: + '@edge-runtime/vm': + optional: true + '@types/node': + optional: true + '@vitest/browser': + optional: true + '@vitest/ui': + optional: true + happy-dom: + optional: true + jsdom: + optional: true + + vscode-jsonrpc@8.2.0: + resolution: {integrity: sha512-C+r0eKJUIfiDIfwJhria30+TYWPtuHJXHtI7J0YlOmKAo7ogxP20T0zxB7HZQIFhIyvoBPwWskjxrvAtfjyZfA==} + engines: {node: '>=14.0.0'} + + vscode-languageclient@9.0.1: + resolution: {integrity: sha512-JZiimVdvimEuHh5olxhxkht09m3JzUGwggb5eRUkzzJhZ2KjCN0nh55VfiED9oez9DyF8/fz1g1iBV3h+0Z2EA==} + engines: {vscode: ^1.82.0} + + vscode-languageserver-protocol@3.17.5: + resolution: {integrity: sha512-mb1bvRJN8SVznADSGWM9u/b07H7Ecg0I3OgXDuLdn307rl/J3A9YD6/eYOssqhecL27hK1IPZAsaqh00i/Jljg==} + + vscode-languageserver-textdocument@1.0.12: + resolution: {integrity: sha512-cxWNPesCnQCcMPeenjKKsOCKQZ/L6Tv19DTRIGuLWe32lyzWhihGVJ/rcckZXJxfdKCFvRLS3fpBIsV/ZGX4zA==} + + vscode-languageserver-types@3.17.5: + resolution: {integrity: sha512-Ld1VelNuX9pdF39h2Hgaeb5hEZM2Z3jUrrMgWQAu82jMtZp7p3vJT3BzToKtZI7NgQssZje5o0zryOrhQvzQAg==} + + vscode-languageserver@9.0.1: + resolution: {integrity: sha512-woByF3PDpkHFUreUa7Hos7+pUWdeWMXRd26+ZX2A8cFx6v/JPTtd4/uN0/jB6XQHYaOlHbio03NTHCqrgG5n7g==} + hasBin: true + + vscode-uri@3.0.8: + resolution: {integrity: sha512-AyFQ0EVmsOZOlAnxoFOGOq1SQDWAB7C6aqMGS23svWAllfOaxbuFvcT8D1i8z3Gyn8fraVeZNNmN6e9bxxXkKw==} + + whatwg-encoding@3.1.1: + resolution: {integrity: sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==} + engines: {node: '>=18'} + + whatwg-mimetype@4.0.0: + resolution: {integrity: sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==} + engines: {node: '>=18'} + + which@2.0.2: + resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} + engines: {node: '>= 8'} + hasBin: true + + why-is-node-running@2.3.0: + resolution: {integrity: sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==} + engines: {node: '>=8'} + hasBin: true + + word-wrap@1.2.5: + resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==} + engines: {node: '>=0.10.0'} + + wrap-ansi@7.0.0: + resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} + engines: {node: '>=10'} + + wrap-ansi@8.1.0: + resolution: {integrity: sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==} + engines: {node: '>=12'} + + wrappy@1.0.2: + resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + + xml2js@0.5.0: + resolution: {integrity: sha512-drPFnkQJik/O+uPKpqSgr22mpuFHqKdbS835iAQrUC73L2F5WkboIRd63ai/2Yg6I1jzifPFKH2NTK+cfglkIA==} + engines: {node: '>=4.0.0'} + + xmlbuilder@11.0.1: + resolution: {integrity: sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==} + engines: {node: '>=4.0'} + + y18n@5.0.8: + resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} + engines: {node: '>=10'} + + yallist@4.0.0: + resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} + + yargs-parser@21.1.1: + resolution: {integrity: sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==} + engines: {node: '>=12'} + + yargs@17.7.2: + resolution: {integrity: sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==} + engines: {node: '>=12'} + + yauzl@2.10.0: + resolution: {integrity: sha512-p4a9I6X6nu6IhoGmBqAcbJy1mlC4j27vEPZX9F4L4/vZT3Lyq1VkFHw/V/PUcB9Buo+DG3iHkT0x3Qya58zc3g==} + + yazl@2.5.1: + resolution: {integrity: sha512-phENi2PLiHnHb6QBVot+dJnaAZ0xosj7p3fWl+znIjBDlnMI2PsZCJZ306BPTFOaHf5qdDEI8x5qFrSOBN5vrw==} + + yocto-queue@0.1.0: + resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} + engines: {node: '>=10'} + + yocto-queue@1.1.1: + resolution: {integrity: sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g==} + engines: {node: '>=12.20'} + +snapshots: + + '@azure/abort-controller@2.1.2': + dependencies: + tslib: 2.8.0 + + '@azure/core-auth@1.9.0': + dependencies: + '@azure/abort-controller': 2.1.2 + '@azure/core-util': 1.11.0 + tslib: 2.8.0 + + '@azure/core-client@1.9.2': + dependencies: + '@azure/abort-controller': 2.1.2 + '@azure/core-auth': 1.9.0 + '@azure/core-rest-pipeline': 1.17.0 + '@azure/core-tracing': 1.2.0 + '@azure/core-util': 1.11.0 + '@azure/logger': 1.1.4 + tslib: 2.8.0 + transitivePeerDependencies: + - supports-color + + '@azure/core-rest-pipeline@1.17.0': + dependencies: + '@azure/abort-controller': 2.1.2 + '@azure/core-auth': 1.9.0 + '@azure/core-tracing': 1.2.0 + '@azure/core-util': 1.11.0 + '@azure/logger': 1.1.4 + http-proxy-agent: 7.0.2 + https-proxy-agent: 7.0.5 + tslib: 2.8.0 + transitivePeerDependencies: + - supports-color + + '@azure/core-tracing@1.2.0': + dependencies: + tslib: 2.8.0 + + '@azure/core-util@1.11.0': + dependencies: + '@azure/abort-controller': 2.1.2 + tslib: 2.8.0 + + '@azure/identity@4.5.0': + dependencies: + '@azure/abort-controller': 2.1.2 + '@azure/core-auth': 1.9.0 + '@azure/core-client': 1.9.2 + '@azure/core-rest-pipeline': 1.17.0 + '@azure/core-tracing': 1.2.0 + '@azure/core-util': 1.11.0 + '@azure/logger': 1.1.4 + '@azure/msal-browser': 3.26.1 + '@azure/msal-node': 2.15.0 + events: 3.3.0 + jws: 4.0.0 + open: 8.4.2 + stoppable: 1.1.0 + tslib: 2.8.0 + transitivePeerDependencies: + - supports-color + + '@azure/logger@1.1.4': + dependencies: + tslib: 2.8.0 + + '@azure/msal-browser@3.26.1': + dependencies: + '@azure/msal-common': 14.15.0 + + '@azure/msal-common@14.15.0': {} + + '@azure/msal-node@2.15.0': + dependencies: + '@azure/msal-common': 14.15.0 + jsonwebtoken: 9.0.2 + uuid: 8.3.2 + + '@babel/runtime@7.26.0': + dependencies: + regenerator-runtime: 0.14.1 + + '@chevrotain/cst-dts-gen@11.0.3': + dependencies: + '@chevrotain/gast': 11.0.3 + '@chevrotain/types': 11.0.3 + lodash-es: 4.17.21 + + '@chevrotain/gast@11.0.3': + dependencies: + '@chevrotain/types': 11.0.3 + lodash-es: 4.17.21 + + '@chevrotain/regexp-to-ast@11.0.3': {} + + '@chevrotain/types@11.0.3': {} + + '@chevrotain/utils@11.0.3': {} + + '@esbuild/aix-ppc64@0.21.5': + optional: true + + '@esbuild/android-arm64@0.21.5': + optional: true + + '@esbuild/android-arm@0.21.5': + optional: true + + '@esbuild/android-x64@0.21.5': + optional: true + + '@esbuild/darwin-arm64@0.21.5': + optional: true + + '@esbuild/darwin-x64@0.21.5': + optional: true + + '@esbuild/freebsd-arm64@0.21.5': + optional: true + + '@esbuild/freebsd-x64@0.21.5': + optional: true + + '@esbuild/linux-arm64@0.21.5': + optional: true + + '@esbuild/linux-arm@0.21.5': + optional: true + + '@esbuild/linux-ia32@0.21.5': + optional: true + + '@esbuild/linux-loong64@0.21.5': + optional: true + + '@esbuild/linux-mips64el@0.21.5': + optional: true + + '@esbuild/linux-ppc64@0.21.5': + optional: true + + '@esbuild/linux-riscv64@0.21.5': + optional: true + + '@esbuild/linux-s390x@0.21.5': + optional: true + + '@esbuild/linux-x64@0.21.5': + optional: true + + '@esbuild/netbsd-x64@0.21.5': + optional: true + + '@esbuild/openbsd-x64@0.21.5': + optional: true + + '@esbuild/sunos-x64@0.21.5': + optional: true + + '@esbuild/win32-arm64@0.21.5': + optional: true + + '@esbuild/win32-ia32@0.21.5': + optional: true + + '@esbuild/win32-x64@0.21.5': + optional: true + + '@eslint-community/eslint-utils@4.4.1(eslint@8.57.1)': + dependencies: + eslint: 8.57.1 + eslint-visitor-keys: 3.4.3 + + '@eslint-community/regexpp@4.12.1': {} + + '@eslint/eslintrc@2.1.4': + dependencies: + ajv: 6.12.6 + debug: 4.3.7 + espree: 9.6.1 + globals: 13.24.0 + ignore: 5.3.2 + import-fresh: 3.3.0 + js-yaml: 4.1.0 + minimatch: 3.1.2 + strip-json-comments: 3.1.1 + transitivePeerDependencies: + - supports-color + + '@eslint/js@8.57.1': {} + + '@humanwhocodes/config-array@0.13.0': + dependencies: + '@humanwhocodes/object-schema': 2.0.3 + debug: 4.3.7 + minimatch: 3.1.2 + transitivePeerDependencies: + - supports-color + + '@humanwhocodes/module-importer@1.0.1': {} + + '@humanwhocodes/object-schema@2.0.3': {} + + '@isaacs/cliui@8.0.2': + dependencies: + string-width: 5.1.2 + string-width-cjs: string-width@4.2.3 + strip-ansi: 7.1.0 + strip-ansi-cjs: strip-ansi@6.0.1 + wrap-ansi: 8.1.0 + wrap-ansi-cjs: wrap-ansi@7.0.0 + + '@jest/schemas@29.6.3': + dependencies: + '@sinclair/typebox': 0.27.8 + + '@jridgewell/sourcemap-codec@1.5.0': {} + + '@nodelib/fs.scandir@2.1.5': + dependencies: + '@nodelib/fs.stat': 2.0.5 + run-parallel: 1.2.0 + + '@nodelib/fs.stat@2.0.5': {} + + '@nodelib/fs.walk@1.2.8': + dependencies: + '@nodelib/fs.scandir': 2.1.5 + fastq: 1.17.1 + + '@rollup/rollup-android-arm-eabi@4.24.2': + optional: true + + '@rollup/rollup-android-arm64@4.24.2': + optional: true + + '@rollup/rollup-darwin-arm64@4.24.2': + optional: true + + '@rollup/rollup-darwin-x64@4.24.2': + optional: true + + '@rollup/rollup-freebsd-arm64@4.24.2': + optional: true + + '@rollup/rollup-freebsd-x64@4.24.2': + optional: true + + '@rollup/rollup-linux-arm-gnueabihf@4.24.2': + optional: true + + '@rollup/rollup-linux-arm-musleabihf@4.24.2': + optional: true + + '@rollup/rollup-linux-arm64-gnu@4.24.2': + optional: true + + '@rollup/rollup-linux-arm64-musl@4.24.2': + optional: true + + '@rollup/rollup-linux-powerpc64le-gnu@4.24.2': + optional: true + + '@rollup/rollup-linux-riscv64-gnu@4.24.2': + optional: true + + '@rollup/rollup-linux-s390x-gnu@4.24.2': + optional: true + + '@rollup/rollup-linux-x64-gnu@4.24.2': + optional: true + + '@rollup/rollup-linux-x64-musl@4.24.2': + optional: true + + '@rollup/rollup-win32-arm64-msvc@4.24.2': + optional: true + + '@rollup/rollup-win32-ia32-msvc@4.24.2': + optional: true + + '@rollup/rollup-win32-x64-msvc@4.24.2': + optional: true + + '@sinclair/typebox@0.27.8': {} + + '@types/estree@1.0.6': {} + + '@types/node@18.19.60': + dependencies: + undici-types: 5.26.5 + + '@types/vscode@1.67.0': {} + + '@typescript-eslint/eslint-plugin@7.13.1(@typescript-eslint/parser@7.13.1(eslint@8.57.1)(typescript@5.4.5))(eslint@8.57.1)(typescript@5.4.5)': + dependencies: + '@eslint-community/regexpp': 4.12.1 + '@typescript-eslint/parser': 7.13.1(eslint@8.57.1)(typescript@5.4.5) + '@typescript-eslint/scope-manager': 7.13.1 + '@typescript-eslint/type-utils': 7.13.1(eslint@8.57.1)(typescript@5.4.5) + '@typescript-eslint/utils': 7.13.1(eslint@8.57.1)(typescript@5.4.5) + '@typescript-eslint/visitor-keys': 7.13.1 + eslint: 8.57.1 + graphemer: 1.4.0 + ignore: 5.3.2 + natural-compare: 1.4.0 + ts-api-utils: 1.3.0(typescript@5.4.5) + optionalDependencies: + typescript: 5.4.5 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/parser@7.13.1(eslint@8.57.1)(typescript@5.4.5)': + dependencies: + '@typescript-eslint/scope-manager': 7.13.1 + '@typescript-eslint/types': 7.13.1 + '@typescript-eslint/typescript-estree': 7.13.1(typescript@5.4.5) + '@typescript-eslint/visitor-keys': 7.13.1 + debug: 4.3.7 + eslint: 8.57.1 + optionalDependencies: + typescript: 5.4.5 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/scope-manager@7.13.1': + dependencies: + '@typescript-eslint/types': 7.13.1 + '@typescript-eslint/visitor-keys': 7.13.1 + + '@typescript-eslint/type-utils@7.13.1(eslint@8.57.1)(typescript@5.4.5)': + dependencies: + '@typescript-eslint/typescript-estree': 7.13.1(typescript@5.4.5) + '@typescript-eslint/utils': 7.13.1(eslint@8.57.1)(typescript@5.4.5) + debug: 4.3.7 + eslint: 8.57.1 + ts-api-utils: 1.3.0(typescript@5.4.5) + optionalDependencies: + typescript: 5.4.5 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/types@7.13.1': {} + + '@typescript-eslint/typescript-estree@7.13.1(typescript@5.4.5)': + dependencies: + '@typescript-eslint/types': 7.13.1 + '@typescript-eslint/visitor-keys': 7.13.1 + debug: 4.3.7 + globby: 11.1.0 + is-glob: 4.0.3 + minimatch: 9.0.5 + semver: 7.6.3 + ts-api-utils: 1.3.0(typescript@5.4.5) + optionalDependencies: + typescript: 5.4.5 + transitivePeerDependencies: + - supports-color + + '@typescript-eslint/utils@7.13.1(eslint@8.57.1)(typescript@5.4.5)': + dependencies: + '@eslint-community/eslint-utils': 4.4.1(eslint@8.57.1) + '@typescript-eslint/scope-manager': 7.13.1 + '@typescript-eslint/types': 7.13.1 + '@typescript-eslint/typescript-estree': 7.13.1(typescript@5.4.5) + eslint: 8.57.1 + transitivePeerDependencies: + - supports-color + - typescript + + '@typescript-eslint/visitor-keys@7.13.1': + dependencies: + '@typescript-eslint/types': 7.13.1 + eslint-visitor-keys: 3.4.3 + + '@ungap/structured-clone@1.2.0': {} + + '@vitest/expect@1.6.0': + dependencies: + '@vitest/spy': 1.6.0 + '@vitest/utils': 1.6.0 + chai: 4.5.0 + + '@vitest/runner@1.6.0': + dependencies: + '@vitest/utils': 1.6.0 + p-limit: 5.0.0 + pathe: 1.1.2 + + '@vitest/snapshot@1.6.0': + dependencies: + magic-string: 0.30.12 + pathe: 1.1.2 + pretty-format: 29.7.0 + + '@vitest/spy@1.6.0': + dependencies: + tinyspy: 2.2.1 + + '@vitest/utils@1.6.0': + dependencies: + diff-sequences: 29.6.3 + estree-walker: 3.0.3 + loupe: 2.3.7 + pretty-format: 29.7.0 + + '@vscode/vsce-sign-alpine-arm64@2.0.2': + optional: true + + '@vscode/vsce-sign-alpine-x64@2.0.2': + optional: true + + '@vscode/vsce-sign-darwin-arm64@2.0.2': + optional: true + + '@vscode/vsce-sign-darwin-x64@2.0.2': + optional: true + + '@vscode/vsce-sign-linux-arm64@2.0.2': + optional: true + + '@vscode/vsce-sign-linux-arm@2.0.2': + optional: true + + '@vscode/vsce-sign-linux-x64@2.0.2': + optional: true + + '@vscode/vsce-sign-win32-arm64@2.0.2': + optional: true + + '@vscode/vsce-sign-win32-x64@2.0.2': + optional: true + + '@vscode/vsce-sign@2.0.5': + optionalDependencies: + '@vscode/vsce-sign-alpine-arm64': 2.0.2 + '@vscode/vsce-sign-alpine-x64': 2.0.2 + '@vscode/vsce-sign-darwin-arm64': 2.0.2 + '@vscode/vsce-sign-darwin-x64': 2.0.2 + '@vscode/vsce-sign-linux-arm': 2.0.2 + '@vscode/vsce-sign-linux-arm64': 2.0.2 + '@vscode/vsce-sign-linux-x64': 2.0.2 + '@vscode/vsce-sign-win32-arm64': 2.0.2 + '@vscode/vsce-sign-win32-x64': 2.0.2 + + '@vscode/vsce@3.2.1': + dependencies: + '@azure/identity': 4.5.0 + '@vscode/vsce-sign': 2.0.5 + azure-devops-node-api: 12.5.0 + chalk: 2.4.2 + cheerio: 1.0.0 + cockatiel: 3.2.1 + commander: 6.2.1 + form-data: 4.0.1 + glob: 11.0.0 + hosted-git-info: 4.1.0 + jsonc-parser: 3.3.1 + leven: 3.1.0 + markdown-it: 14.1.0 + mime: 1.6.0 + minimatch: 3.1.2 + parse-semver: 1.1.1 + read: 1.0.7 + semver: 7.6.3 + tmp: 0.2.3 + typed-rest-client: 1.8.11 + url-join: 4.0.1 + xml2js: 0.5.0 + yauzl: 2.10.0 + yazl: 2.5.1 + optionalDependencies: + keytar: 7.9.0 + transitivePeerDependencies: + - supports-color + + acorn-jsx@5.3.2(acorn@8.14.0): + dependencies: + acorn: 8.14.0 + + acorn-walk@8.3.4: + dependencies: + acorn: 8.14.0 + + acorn@8.14.0: {} + + agent-base@7.1.1: + dependencies: + debug: 4.3.7 + transitivePeerDependencies: + - supports-color + + ajv@6.12.6: + dependencies: + fast-deep-equal: 3.1.3 + fast-json-stable-stringify: 2.1.0 + json-schema-traverse: 0.4.1 + uri-js: 4.4.1 + + ansi-regex@5.0.1: {} + + ansi-regex@6.1.0: {} + + ansi-styles@3.2.1: + dependencies: + color-convert: 1.9.3 + + ansi-styles@4.3.0: + dependencies: + color-convert: 2.0.1 + + ansi-styles@5.2.0: {} + + ansi-styles@6.2.1: {} + + argparse@2.0.1: {} + + array-union@2.1.0: {} + + assertion-error@1.1.0: {} + + asynckit@0.4.0: {} + + azure-devops-node-api@12.5.0: + dependencies: + tunnel: 0.0.6 + typed-rest-client: 1.8.11 + + balanced-match@1.0.2: {} + + base64-js@1.5.1: + optional: true + + bl@4.1.0: + dependencies: + buffer: 5.7.1 + inherits: 2.0.4 + readable-stream: 3.6.2 + optional: true + + boolbase@1.0.0: {} + + brace-expansion@1.1.11: + dependencies: + balanced-match: 1.0.2 + concat-map: 0.0.1 + + brace-expansion@2.0.1: + dependencies: + balanced-match: 1.0.2 + + braces@3.0.3: + dependencies: + fill-range: 7.1.1 + + buffer-crc32@0.2.13: {} + + buffer-equal-constant-time@1.0.1: {} + + buffer@5.7.1: + dependencies: + base64-js: 1.5.1 + ieee754: 1.2.1 + optional: true + + cac@6.7.14: {} + + call-bind@1.0.7: + dependencies: + es-define-property: 1.0.0 + es-errors: 1.3.0 + function-bind: 1.1.2 + get-intrinsic: 1.2.4 + set-function-length: 1.2.2 + + callsites@3.1.0: {} + + chai@4.5.0: + dependencies: + assertion-error: 1.1.0 + check-error: 1.0.3 + deep-eql: 4.1.4 + get-func-name: 2.0.2 + loupe: 2.3.7 + pathval: 1.1.1 + type-detect: 4.1.0 + + chalk@2.4.2: + dependencies: + ansi-styles: 3.2.1 + escape-string-regexp: 1.0.5 + supports-color: 5.5.0 + + chalk@4.1.2: + dependencies: + ansi-styles: 4.3.0 + supports-color: 7.2.0 + + chalk@5.3.0: {} + + check-error@1.0.3: + dependencies: + get-func-name: 2.0.2 + + cheerio-select@2.1.0: + dependencies: + boolbase: 1.0.0 + css-select: 5.1.0 + css-what: 6.1.0 + domelementtype: 2.3.0 + domhandler: 5.0.3 + domutils: 3.1.0 + + cheerio@1.0.0: + dependencies: + cheerio-select: 2.1.0 + dom-serializer: 2.0.0 + domhandler: 5.0.3 + domutils: 3.1.0 + encoding-sniffer: 0.2.0 + htmlparser2: 9.1.0 + parse5: 7.2.1 + parse5-htmlparser2-tree-adapter: 7.1.0 + parse5-parser-stream: 7.1.2 + undici: 6.20.1 + whatwg-mimetype: 4.0.0 + + chevrotain-allstar@0.3.1(chevrotain@11.0.3): + dependencies: + chevrotain: 11.0.3 + lodash-es: 4.17.21 + + chevrotain@11.0.3: + dependencies: + '@chevrotain/cst-dts-gen': 11.0.3 + '@chevrotain/gast': 11.0.3 + '@chevrotain/regexp-to-ast': 11.0.3 + '@chevrotain/types': 11.0.3 + '@chevrotain/utils': 11.0.3 + lodash-es: 4.17.21 + + chownr@1.1.4: + optional: true + + cliui@8.0.1: + dependencies: + string-width: 4.2.3 + strip-ansi: 6.0.1 + wrap-ansi: 7.0.0 + + cockatiel@3.2.1: {} + + color-convert@1.9.3: + dependencies: + color-name: 1.1.3 + + color-convert@2.0.1: + dependencies: + color-name: 1.1.4 + + color-name@1.1.3: {} + + color-name@1.1.4: {} + + combined-stream@1.0.8: + dependencies: + delayed-stream: 1.0.0 + + commander@11.0.0: {} + + commander@6.2.1: {} + + concat-map@0.0.1: {} + + concurrently@8.2.2: + dependencies: + chalk: 4.1.2 + date-fns: 2.30.0 + lodash: 4.17.21 + rxjs: 7.8.1 + shell-quote: 1.8.1 + spawn-command: 0.0.2 + supports-color: 8.1.1 + tree-kill: 1.2.2 + yargs: 17.7.2 + + confbox@0.1.8: {} + + cross-spawn@7.0.3: + dependencies: + path-key: 3.1.1 + shebang-command: 2.0.0 + which: 2.0.2 + + css-select@5.1.0: + dependencies: + boolbase: 1.0.0 + css-what: 6.1.0 + domhandler: 5.0.3 + domutils: 3.1.0 + nth-check: 2.1.1 + + css-what@6.1.0: {} + + date-fns@2.30.0: + dependencies: + '@babel/runtime': 7.26.0 + + debug@4.3.7: + dependencies: + ms: 2.1.3 + + decompress-response@6.0.0: + dependencies: + mimic-response: 3.1.0 + optional: true + + deep-eql@4.1.4: + dependencies: + type-detect: 4.1.0 + + deep-extend@0.6.0: + optional: true + + deep-is@0.1.4: {} + + deepmerge@1.5.2: {} + + define-data-property@1.1.4: + dependencies: + es-define-property: 1.0.0 + es-errors: 1.3.0 + gopd: 1.0.1 + + define-lazy-prop@2.0.0: {} + + delayed-stream@1.0.0: {} + + detect-libc@2.0.3: + optional: true + + diff-sequences@29.6.3: {} + + dir-glob@3.0.1: + dependencies: + path-type: 4.0.0 + + doctrine@3.0.0: + dependencies: + esutils: 2.0.3 + + dom-serializer@2.0.0: + dependencies: + domelementtype: 2.3.0 + domhandler: 5.0.3 + entities: 4.5.0 + + domelementtype@2.3.0: {} + + domhandler@5.0.3: + dependencies: + domelementtype: 2.3.0 + + domutils@3.1.0: + dependencies: + dom-serializer: 2.0.0 + domelementtype: 2.3.0 + domhandler: 5.0.3 + + eastasianwidth@0.2.0: {} + + ecdsa-sig-formatter@1.0.11: + dependencies: + safe-buffer: 5.2.1 + + emoji-regex@8.0.0: {} + + emoji-regex@9.2.2: {} + + encoding-sniffer@0.2.0: + dependencies: + iconv-lite: 0.6.3 + whatwg-encoding: 3.1.1 + + end-of-stream@1.4.4: + dependencies: + once: 1.4.0 + optional: true + + entities@4.5.0: {} + + es-define-property@1.0.0: + dependencies: + get-intrinsic: 1.2.4 + + es-errors@1.3.0: {} + + esbuild@0.21.5: + optionalDependencies: + '@esbuild/aix-ppc64': 0.21.5 + '@esbuild/android-arm': 0.21.5 + '@esbuild/android-arm64': 0.21.5 + '@esbuild/android-x64': 0.21.5 + '@esbuild/darwin-arm64': 0.21.5 + '@esbuild/darwin-x64': 0.21.5 + '@esbuild/freebsd-arm64': 0.21.5 + '@esbuild/freebsd-x64': 0.21.5 + '@esbuild/linux-arm': 0.21.5 + '@esbuild/linux-arm64': 0.21.5 + '@esbuild/linux-ia32': 0.21.5 + '@esbuild/linux-loong64': 0.21.5 + '@esbuild/linux-mips64el': 0.21.5 + '@esbuild/linux-ppc64': 0.21.5 + '@esbuild/linux-riscv64': 0.21.5 + '@esbuild/linux-s390x': 0.21.5 + '@esbuild/linux-x64': 0.21.5 + '@esbuild/netbsd-x64': 0.21.5 + '@esbuild/openbsd-x64': 0.21.5 + '@esbuild/sunos-x64': 0.21.5 + '@esbuild/win32-arm64': 0.21.5 + '@esbuild/win32-ia32': 0.21.5 + '@esbuild/win32-x64': 0.21.5 + + escalade@3.2.0: {} + + escape-string-regexp@1.0.5: {} + + escape-string-regexp@4.0.0: {} + + eslint-scope@7.2.2: + dependencies: + esrecurse: 4.3.0 + estraverse: 5.3.0 + + eslint-visitor-keys@3.4.3: {} + + eslint@8.57.1: + dependencies: + '@eslint-community/eslint-utils': 4.4.1(eslint@8.57.1) + '@eslint-community/regexpp': 4.12.1 + '@eslint/eslintrc': 2.1.4 + '@eslint/js': 8.57.1 + '@humanwhocodes/config-array': 0.13.0 + '@humanwhocodes/module-importer': 1.0.1 + '@nodelib/fs.walk': 1.2.8 + '@ungap/structured-clone': 1.2.0 + ajv: 6.12.6 + chalk: 4.1.2 + cross-spawn: 7.0.3 + debug: 4.3.7 + doctrine: 3.0.0 + escape-string-regexp: 4.0.0 + eslint-scope: 7.2.2 + eslint-visitor-keys: 3.4.3 + espree: 9.6.1 + esquery: 1.6.0 + esutils: 2.0.3 + fast-deep-equal: 3.1.3 + file-entry-cache: 6.0.1 + find-up: 5.0.0 + glob-parent: 6.0.2 + globals: 13.24.0 + graphemer: 1.4.0 + ignore: 5.3.2 + imurmurhash: 0.1.4 + is-glob: 4.0.3 + is-path-inside: 3.0.3 + js-yaml: 4.1.0 + json-stable-stringify-without-jsonify: 1.0.1 + levn: 0.4.1 + lodash.merge: 4.6.2 + minimatch: 3.1.2 + natural-compare: 1.4.0 + optionator: 0.9.4 + strip-ansi: 6.0.1 + text-table: 0.2.0 + transitivePeerDependencies: + - supports-color + + espree@9.6.1: + dependencies: + acorn: 8.14.0 + acorn-jsx: 5.3.2(acorn@8.14.0) + eslint-visitor-keys: 3.4.3 + + esquery@1.6.0: + dependencies: + estraverse: 5.3.0 + + esrecurse@4.3.0: + dependencies: + estraverse: 5.3.0 + + estraverse@5.3.0: {} + + estree-walker@3.0.3: + dependencies: + '@types/estree': 1.0.6 + + esutils@2.0.3: {} + + events@3.3.0: {} + + execa@8.0.1: + dependencies: + cross-spawn: 7.0.3 + get-stream: 8.0.1 + human-signals: 5.0.0 + is-stream: 3.0.0 + merge-stream: 2.0.0 + npm-run-path: 5.3.0 + onetime: 6.0.0 + signal-exit: 4.1.0 + strip-final-newline: 3.0.0 + + expand-template@2.0.3: + optional: true + + fast-deep-equal@3.1.3: {} + + fast-glob@3.3.2: + dependencies: + '@nodelib/fs.stat': 2.0.5 + '@nodelib/fs.walk': 1.2.8 + glob-parent: 5.1.2 + merge2: 1.4.1 + micromatch: 4.0.8 + + fast-json-stable-stringify@2.1.0: {} + + fast-levenshtein@2.0.6: {} + + fastq@1.17.1: + dependencies: + reusify: 1.0.4 + + fd-slicer@1.1.0: + dependencies: + pend: 1.2.0 + + file-entry-cache@6.0.1: + dependencies: + flat-cache: 3.2.0 + + fill-range@7.1.1: + dependencies: + to-regex-range: 5.0.1 + + find-up@5.0.0: + dependencies: + locate-path: 6.0.0 + path-exists: 4.0.0 + + flat-cache@3.2.0: + dependencies: + flatted: 3.3.1 + keyv: 4.5.4 + rimraf: 3.0.2 + + flatted@3.3.1: {} + + foreground-child@3.3.0: + dependencies: + cross-spawn: 7.0.3 + signal-exit: 4.1.0 + + form-data@4.0.1: + dependencies: + asynckit: 0.4.0 + combined-stream: 1.0.8 + mime-types: 2.1.35 + + fs-constants@1.0.0: + optional: true + + fs-extra@11.1.1: + dependencies: + graceful-fs: 4.2.11 + jsonfile: 6.1.0 + universalify: 2.0.1 + + fs.realpath@1.0.0: {} + + fsevents@2.3.3: + optional: true + + function-bind@1.1.2: {} + + get-caller-file@2.0.5: {} + + get-func-name@2.0.2: {} + + get-intrinsic@1.2.4: + dependencies: + es-errors: 1.3.0 + function-bind: 1.1.2 + has-proto: 1.0.3 + has-symbols: 1.0.3 + hasown: 2.0.2 + + get-stream@8.0.1: {} + + github-from-package@0.0.0: + optional: true + + glob-parent@5.1.2: + dependencies: + is-glob: 4.0.3 + + glob-parent@6.0.2: + dependencies: + is-glob: 4.0.3 + + glob@11.0.0: + dependencies: + foreground-child: 3.3.0 + jackspeak: 4.0.2 + minimatch: 10.0.1 + minipass: 7.1.2 + package-json-from-dist: 1.0.1 + path-scurry: 2.0.0 + + glob@7.2.3: + dependencies: + fs.realpath: 1.0.0 + inflight: 1.0.6 + inherits: 2.0.4 + minimatch: 3.1.2 + once: 1.4.0 + path-is-absolute: 1.0.1 + + globals@13.24.0: + dependencies: + type-fest: 0.20.2 + + globby@11.1.0: + dependencies: + array-union: 2.1.0 + dir-glob: 3.0.1 + fast-glob: 3.3.2 + ignore: 5.3.2 + merge2: 1.4.1 + slash: 3.0.0 + + gopd@1.0.1: + dependencies: + get-intrinsic: 1.2.4 + + graceful-fs@4.2.11: {} + + graphemer@1.4.0: {} + + has-flag@3.0.0: {} + + has-flag@4.0.0: {} + + has-property-descriptors@1.0.2: + dependencies: + es-define-property: 1.0.0 + + has-proto@1.0.3: {} + + has-symbols@1.0.3: {} + + hasown@2.0.2: + dependencies: + function-bind: 1.1.2 + + hosted-git-info@4.1.0: + dependencies: + lru-cache: 6.0.0 + + htmlparser2@9.1.0: + dependencies: + domelementtype: 2.3.0 + domhandler: 5.0.3 + domutils: 3.1.0 + entities: 4.5.0 + + http-proxy-agent@7.0.2: + dependencies: + agent-base: 7.1.1 + debug: 4.3.7 + transitivePeerDependencies: + - supports-color + + https-proxy-agent@7.0.5: + dependencies: + agent-base: 7.1.1 + debug: 4.3.7 + transitivePeerDependencies: + - supports-color + + human-signals@5.0.0: {} + + iconv-lite@0.6.3: + dependencies: + safer-buffer: 2.1.2 + + ieee754@1.2.1: + optional: true + + ignore@5.3.2: {} + + import-fresh@3.3.0: + dependencies: + parent-module: 1.0.1 + resolve-from: 4.0.0 + + imurmurhash@0.1.4: {} + + inflight@1.0.6: + dependencies: + once: 1.4.0 + wrappy: 1.0.2 + + inherits@2.0.4: {} + + ini@1.3.8: + optional: true + + interpret@1.4.0: {} + + is-core-module@2.15.1: + dependencies: + hasown: 2.0.2 + + is-docker@2.2.1: {} + + is-extglob@2.1.1: {} + + is-fullwidth-code-point@3.0.0: {} + + is-glob@4.0.3: + dependencies: + is-extglob: 2.1.1 + + is-number@7.0.0: {} + + is-path-inside@3.0.3: {} + + is-stream@3.0.0: {} + + is-wsl@2.2.0: + dependencies: + is-docker: 2.2.1 + + isexe@2.0.0: {} + + jackspeak@4.0.2: + dependencies: + '@isaacs/cliui': 8.0.2 + + js-tokens@9.0.0: {} + + js-yaml@4.1.0: + dependencies: + argparse: 2.0.1 + + json-buffer@3.0.1: {} + + json-schema-traverse@0.4.1: {} + + json-stable-stringify-without-jsonify@1.0.1: {} + + jsonc-parser@3.3.1: {} + + jsonfile@6.1.0: + dependencies: + universalify: 2.0.1 + optionalDependencies: + graceful-fs: 4.2.11 + + jsonschema@1.4.1: {} + + jsonwebtoken@9.0.2: + dependencies: + jws: 3.2.2 + lodash.includes: 4.3.0 + lodash.isboolean: 3.0.3 + lodash.isinteger: 4.0.4 + lodash.isnumber: 3.0.3 + lodash.isplainobject: 4.0.6 + lodash.isstring: 4.0.1 + lodash.once: 4.1.1 + ms: 2.1.3 + semver: 7.6.3 + + jwa@1.4.1: + dependencies: + buffer-equal-constant-time: 1.0.1 + ecdsa-sig-formatter: 1.0.11 + safe-buffer: 5.2.1 + + jwa@2.0.0: + dependencies: + buffer-equal-constant-time: 1.0.1 + ecdsa-sig-formatter: 1.0.11 + safe-buffer: 5.2.1 + + jws@3.2.2: + dependencies: + jwa: 1.4.1 + safe-buffer: 5.2.1 + + jws@4.0.0: + dependencies: + jwa: 2.0.0 + safe-buffer: 5.2.1 + + keytar@7.9.0: + dependencies: + node-addon-api: 4.3.0 + prebuild-install: 7.1.2 + optional: true + + keyv@4.5.4: + dependencies: + json-buffer: 3.0.1 + + langium-cli@3.2.0: + dependencies: + chalk: 5.3.0 + commander: 11.0.0 + fs-extra: 11.1.1 + jsonschema: 1.4.1 + langium: 3.2.0 + langium-railroad: 3.2.0 + lodash: 4.17.21 + + langium-railroad@3.2.0: + dependencies: + langium: 3.2.0 + railroad-diagrams: 1.0.0 + + langium@3.2.0: + dependencies: + chevrotain: 11.0.3 + chevrotain-allstar: 0.3.1(chevrotain@11.0.3) + vscode-languageserver: 9.0.1 + vscode-languageserver-textdocument: 1.0.12 + vscode-uri: 3.0.8 + + leven@3.1.0: {} + + levn@0.4.1: + dependencies: + prelude-ls: 1.2.1 + type-check: 0.4.0 + + linkify-it@5.0.0: + dependencies: + uc.micro: 2.1.0 + + local-pkg@0.5.0: + dependencies: + mlly: 1.7.2 + pkg-types: 1.2.1 + + locate-path@6.0.0: + dependencies: + p-locate: 5.0.0 + + lodash-es@4.17.21: {} + + lodash.includes@4.3.0: {} + + lodash.isboolean@3.0.3: {} + + lodash.isinteger@4.0.4: {} + + lodash.isnumber@3.0.3: {} + + lodash.isplainobject@4.0.6: {} + + lodash.isstring@4.0.1: {} + + lodash.merge@4.6.2: {} + + lodash.once@4.1.1: {} + + lodash@4.17.21: {} + + loupe@2.3.7: + dependencies: + get-func-name: 2.0.2 + + lru-cache@11.0.1: {} + + lru-cache@6.0.0: + dependencies: + yallist: 4.0.0 + + magic-string@0.30.12: + dependencies: + '@jridgewell/sourcemap-codec': 1.5.0 + + markdown-it@14.1.0: + dependencies: + argparse: 2.0.1 + entities: 4.5.0 + linkify-it: 5.0.0 + mdurl: 2.0.0 + punycode.js: 2.3.1 + uc.micro: 2.1.0 + + mdurl@2.0.0: {} + + merge-stream@2.0.0: {} + + merge2@1.4.1: {} + + micromatch@4.0.8: + dependencies: + braces: 3.0.3 + picomatch: 2.3.1 + + mime-db@1.52.0: {} + + mime-types@2.1.35: + dependencies: + mime-db: 1.52.0 + + mime@1.6.0: {} + + mimic-fn@4.0.0: {} + + mimic-response@3.1.0: + optional: true + + minimatch@10.0.1: + dependencies: + brace-expansion: 2.0.1 + + minimatch@3.1.2: + dependencies: + brace-expansion: 1.1.11 + + minimatch@5.1.6: + dependencies: + brace-expansion: 2.0.1 + + minimatch@9.0.5: + dependencies: + brace-expansion: 2.0.1 + + minimist@1.2.8: {} + + minipass@7.1.2: {} + + mkdirp-classic@0.5.3: + optional: true + + mlly@1.7.2: + dependencies: + acorn: 8.14.0 + pathe: 1.1.2 + pkg-types: 1.2.1 + ufo: 1.5.4 + + ms@2.1.3: {} + + mute-stream@0.0.8: {} + + nanoid@3.3.7: {} + + napi-build-utils@1.0.2: + optional: true + + natural-compare@1.4.0: {} + + node-abi@3.71.0: + dependencies: + semver: 7.6.3 + optional: true + + node-addon-api@4.3.0: + optional: true + + npm-run-path@5.3.0: + dependencies: + path-key: 4.0.0 + + nth-check@2.1.1: + dependencies: + boolbase: 1.0.0 + + object-inspect@1.13.2: {} + + once@1.4.0: + dependencies: + wrappy: 1.0.2 + + onetime@6.0.0: + dependencies: + mimic-fn: 4.0.0 + + open@8.4.2: + dependencies: + define-lazy-prop: 2.0.0 + is-docker: 2.2.1 + is-wsl: 2.2.0 + + optionator@0.9.4: + dependencies: + deep-is: 0.1.4 + fast-levenshtein: 2.0.6 + levn: 0.4.1 + prelude-ls: 1.2.1 + type-check: 0.4.0 + word-wrap: 1.2.5 + + p-limit@3.1.0: + dependencies: + yocto-queue: 0.1.0 + + p-limit@5.0.0: + dependencies: + yocto-queue: 1.1.1 + + p-locate@5.0.0: + dependencies: + p-limit: 3.1.0 + + package-json-from-dist@1.0.1: {} + + parent-module@1.0.1: + dependencies: + callsites: 3.1.0 + + parse-semver@1.1.1: + dependencies: + semver: 5.7.2 + + parse5-htmlparser2-tree-adapter@7.1.0: + dependencies: + domhandler: 5.0.3 + parse5: 7.2.1 + + parse5-parser-stream@7.1.2: + dependencies: + parse5: 7.2.1 + + parse5@7.2.1: + dependencies: + entities: 4.5.0 + + path-exists@4.0.0: {} + + path-is-absolute@1.0.1: {} + + path-key@3.1.1: {} + + path-key@4.0.0: {} + + path-parse@1.0.7: {} + + path-scurry@2.0.0: + dependencies: + lru-cache: 11.0.1 + minipass: 7.1.2 + + path-type@4.0.0: {} + + pathe@1.1.2: {} + + pathval@1.1.1: {} + + pend@1.2.0: {} + + picocolors@1.1.1: {} + + picomatch@2.3.1: {} + + pkg-types@1.2.1: + dependencies: + confbox: 0.1.8 + mlly: 1.7.2 + pathe: 1.1.2 + + postcss@8.4.47: + dependencies: + nanoid: 3.3.7 + picocolors: 1.1.1 + source-map-js: 1.2.1 + + prebuild-install@7.1.2: + dependencies: + detect-libc: 2.0.3 + expand-template: 2.0.3 + github-from-package: 0.0.0 + minimist: 1.2.8 + mkdirp-classic: 0.5.3 + napi-build-utils: 1.0.2 + node-abi: 3.71.0 + pump: 3.0.2 + rc: 1.2.8 + simple-get: 4.0.1 + tar-fs: 2.1.1 + tunnel-agent: 0.6.0 + optional: true + + prelude-ls@1.2.1: {} + + pretty-format@29.7.0: + dependencies: + '@jest/schemas': 29.6.3 + ansi-styles: 5.2.0 + react-is: 18.3.1 + + pump@3.0.2: + dependencies: + end-of-stream: 1.4.4 + once: 1.4.0 + optional: true + + punycode.js@2.3.1: {} + + punycode@2.3.1: {} + + qs@6.13.0: + dependencies: + side-channel: 1.0.6 + + queue-microtask@1.2.3: {} + + railroad-diagrams@1.0.0: {} + + rc@1.2.8: + dependencies: + deep-extend: 0.6.0 + ini: 1.3.8 + minimist: 1.2.8 + strip-json-comments: 2.0.1 + optional: true + + react-is@18.3.1: {} + + read@1.0.7: + dependencies: + mute-stream: 0.0.8 + + readable-stream@3.6.2: + dependencies: + inherits: 2.0.4 + string_decoder: 1.3.0 + util-deprecate: 1.0.2 + optional: true + + rechoir@0.6.2: + dependencies: + resolve: 1.22.8 + + regenerator-runtime@0.14.1: {} + + require-directory@2.1.1: {} + + resolve-from@4.0.0: {} + + resolve@1.22.8: + dependencies: + is-core-module: 2.15.1 + path-parse: 1.0.7 + supports-preserve-symlinks-flag: 1.0.0 + + reusify@1.0.4: {} + + rimraf@3.0.2: + dependencies: + glob: 7.2.3 + + rollup@4.24.2: + dependencies: + '@types/estree': 1.0.6 + optionalDependencies: + '@rollup/rollup-android-arm-eabi': 4.24.2 + '@rollup/rollup-android-arm64': 4.24.2 + '@rollup/rollup-darwin-arm64': 4.24.2 + '@rollup/rollup-darwin-x64': 4.24.2 + '@rollup/rollup-freebsd-arm64': 4.24.2 + '@rollup/rollup-freebsd-x64': 4.24.2 + '@rollup/rollup-linux-arm-gnueabihf': 4.24.2 + '@rollup/rollup-linux-arm-musleabihf': 4.24.2 + '@rollup/rollup-linux-arm64-gnu': 4.24.2 + '@rollup/rollup-linux-arm64-musl': 4.24.2 + '@rollup/rollup-linux-powerpc64le-gnu': 4.24.2 + '@rollup/rollup-linux-riscv64-gnu': 4.24.2 + '@rollup/rollup-linux-s390x-gnu': 4.24.2 + '@rollup/rollup-linux-x64-gnu': 4.24.2 + '@rollup/rollup-linux-x64-musl': 4.24.2 + '@rollup/rollup-win32-arm64-msvc': 4.24.2 + '@rollup/rollup-win32-ia32-msvc': 4.24.2 + '@rollup/rollup-win32-x64-msvc': 4.24.2 + fsevents: 2.3.3 + + run-parallel@1.2.0: + dependencies: + queue-microtask: 1.2.3 + + rxjs@7.8.1: + dependencies: + tslib: 2.8.0 + + safe-buffer@5.2.1: {} + + safer-buffer@2.1.2: {} + + sax@1.4.1: {} + + semver@5.7.2: {} + + semver@7.6.3: {} + + set-function-length@1.2.2: + dependencies: + define-data-property: 1.1.4 + es-errors: 1.3.0 + function-bind: 1.1.2 + get-intrinsic: 1.2.4 + gopd: 1.0.1 + has-property-descriptors: 1.0.2 + + shebang-command@2.0.0: + dependencies: + shebang-regex: 3.0.0 + + shebang-regex@3.0.0: {} + + shell-quote@1.8.1: {} + + shelljs@0.8.5: + dependencies: + glob: 7.2.3 + interpret: 1.4.0 + rechoir: 0.6.2 + + shx@0.3.4: + dependencies: + minimist: 1.2.8 + shelljs: 0.8.5 + + side-channel@1.0.6: + dependencies: + call-bind: 1.0.7 + es-errors: 1.3.0 + get-intrinsic: 1.2.4 + object-inspect: 1.13.2 + + siginfo@2.0.0: {} + + signal-exit@4.1.0: {} + + simple-concat@1.0.1: + optional: true + + simple-get@4.0.1: + dependencies: + decompress-response: 6.0.0 + once: 1.4.0 + simple-concat: 1.0.1 + optional: true + + slash@3.0.0: {} + + source-map-js@1.2.1: {} + + spawn-command@0.0.2: {} + + stackback@0.0.2: {} + + std-env@3.7.0: {} + + stoppable@1.1.0: {} + + string-width@4.2.3: + dependencies: + emoji-regex: 8.0.0 + is-fullwidth-code-point: 3.0.0 + strip-ansi: 6.0.1 + + string-width@5.1.2: + dependencies: + eastasianwidth: 0.2.0 + emoji-regex: 9.2.2 + strip-ansi: 7.1.0 + + string_decoder@1.3.0: + dependencies: + safe-buffer: 5.2.1 + optional: true + + strip-ansi@6.0.1: + dependencies: + ansi-regex: 5.0.1 + + strip-ansi@7.1.0: + dependencies: + ansi-regex: 6.1.0 + + strip-final-newline@3.0.0: {} + + strip-json-comments@2.0.1: + optional: true + + strip-json-comments@3.1.1: {} + + strip-literal@2.1.0: + dependencies: + js-tokens: 9.0.0 + + supports-color@5.5.0: + dependencies: + has-flag: 3.0.0 + + supports-color@7.2.0: + dependencies: + has-flag: 4.0.0 + + supports-color@8.1.1: + dependencies: + has-flag: 4.0.0 + + supports-preserve-symlinks-flag@1.0.0: {} + + tar-fs@2.1.1: + dependencies: + chownr: 1.1.4 + mkdirp-classic: 0.5.3 + pump: 3.0.2 + tar-stream: 2.2.0 + optional: true + + tar-stream@2.2.0: + dependencies: + bl: 4.1.0 + end-of-stream: 1.4.4 + fs-constants: 1.0.0 + inherits: 2.0.4 + readable-stream: 3.6.2 + optional: true + + text-table@0.2.0: {} + + tinybench@2.9.0: {} + + tinypool@0.8.4: {} + + tinyspy@2.2.1: {} + + tmp@0.2.3: {} + + to-regex-range@5.0.1: + dependencies: + is-number: 7.0.0 + + tree-kill@1.2.2: {} + + ts-api-utils@1.3.0(typescript@5.4.5): + dependencies: + typescript: 5.4.5 + + tslib@2.8.0: {} + + tunnel-agent@0.6.0: + dependencies: + safe-buffer: 5.2.1 + optional: true + + tunnel@0.0.6: {} + + type-check@0.4.0: + dependencies: + prelude-ls: 1.2.1 + + type-detect@4.1.0: {} + + type-fest@0.20.2: {} + + typed-rest-client@1.8.11: + dependencies: + qs: 6.13.0 + tunnel: 0.0.6 + underscore: 1.13.7 + + typescript@5.4.5: {} + + uc.micro@2.1.0: {} + + ufo@1.5.4: {} + + underscore@1.13.7: {} + + undici-types@5.26.5: {} + + undici@6.20.1: {} + + universalify@2.0.1: {} + + uri-js@4.4.1: + dependencies: + punycode: 2.3.1 + + url-join@4.0.1: {} + + util-deprecate@1.0.2: + optional: true + + uuid@8.3.2: {} + + vite-node@1.6.0(@types/node@18.19.60): + dependencies: + cac: 6.7.14 + debug: 4.3.7 + pathe: 1.1.2 + picocolors: 1.1.1 + vite: 5.4.10(@types/node@18.19.60) + transitivePeerDependencies: + - '@types/node' + - less + - lightningcss + - sass + - sass-embedded + - stylus + - sugarss + - supports-color + - terser + + vite@5.4.10(@types/node@18.19.60): + dependencies: + esbuild: 0.21.5 + postcss: 8.4.47 + rollup: 4.24.2 + optionalDependencies: + '@types/node': 18.19.60 + fsevents: 2.3.3 + + vitest@1.6.0(@types/node@18.19.60): + dependencies: + '@vitest/expect': 1.6.0 + '@vitest/runner': 1.6.0 + '@vitest/snapshot': 1.6.0 + '@vitest/spy': 1.6.0 + '@vitest/utils': 1.6.0 + acorn-walk: 8.3.4 + chai: 4.5.0 + debug: 4.3.7 + execa: 8.0.1 + local-pkg: 0.5.0 + magic-string: 0.30.12 + pathe: 1.1.2 + picocolors: 1.1.1 + std-env: 3.7.0 + strip-literal: 2.1.0 + tinybench: 2.9.0 + tinypool: 0.8.4 + vite: 5.4.10(@types/node@18.19.60) + vite-node: 1.6.0(@types/node@18.19.60) + why-is-node-running: 2.3.0 + optionalDependencies: + '@types/node': 18.19.60 + transitivePeerDependencies: + - less + - lightningcss + - sass + - sass-embedded + - stylus + - sugarss + - supports-color + - terser + + vscode-jsonrpc@8.2.0: {} + + vscode-languageclient@9.0.1: + dependencies: + minimatch: 5.1.6 + semver: 7.6.3 + vscode-languageserver-protocol: 3.17.5 + + vscode-languageserver-protocol@3.17.5: + dependencies: + vscode-jsonrpc: 8.2.0 + vscode-languageserver-types: 3.17.5 + + vscode-languageserver-textdocument@1.0.12: {} + + vscode-languageserver-types@3.17.5: {} + + vscode-languageserver@9.0.1: + dependencies: + vscode-languageserver-protocol: 3.17.5 + + vscode-uri@3.0.8: {} + + whatwg-encoding@3.1.1: + dependencies: + iconv-lite: 0.6.3 + + whatwg-mimetype@4.0.0: {} + + which@2.0.2: + dependencies: + isexe: 2.0.0 + + why-is-node-running@2.3.0: + dependencies: + siginfo: 2.0.0 + stackback: 0.0.2 + + word-wrap@1.2.5: {} + + wrap-ansi@7.0.0: + dependencies: + ansi-styles: 4.3.0 + string-width: 4.2.3 + strip-ansi: 6.0.1 + + wrap-ansi@8.1.0: + dependencies: + ansi-styles: 6.2.1 + string-width: 5.1.2 + strip-ansi: 7.1.0 + + wrappy@1.0.2: {} + + xml2js@0.5.0: + dependencies: + sax: 1.4.1 + xmlbuilder: 11.0.1 + + xmlbuilder@11.0.1: {} + + y18n@5.0.8: {} + + yallist@4.0.0: {} + + yargs-parser@21.1.1: {} + + yargs@17.7.2: + dependencies: + cliui: 8.0.1 + escalade: 3.2.0 + get-caller-file: 2.0.5 + require-directory: 2.1.1 + string-width: 4.2.3 + y18n: 5.0.8 + yargs-parser: 21.1.1 + + yauzl@2.10.0: + dependencies: + buffer-crc32: 0.2.13 + fd-slicer: 1.1.0 + + yazl@2.5.1: + dependencies: + buffer-crc32: 0.2.13 + + yocto-queue@0.1.0: {} + + yocto-queue@1.1.1: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml new file mode 100644 index 0000000..18ec407 --- /dev/null +++ b/pnpm-workspace.yaml @@ -0,0 +1,2 @@ +packages: + - 'packages/*' diff --git a/scripts/merge-tmlanguage.mjs b/scripts/merge-tmlanguage.mjs new file mode 100644 index 0000000..f61c6a4 --- /dev/null +++ b/scripts/merge-tmlanguage.mjs @@ -0,0 +1,83 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +import * as fs from 'fs/promises'; + +import { createLangiumGrammarServices } from 'langium/grammar'; +import { NodeFileSystem } from 'langium/node'; +import { parseHelper } from 'langium/test'; +import { AstUtils, GrammarAST, RegExpUtils } from 'langium'; +import { readFileSync } from 'fs'; + +const services = createLangiumGrammarServices({ + fileSystemProvider: NodeFileSystem.fileSystemProvider +}); +const parse = parseHelper(services.grammar); + +const file = readFileSync('./packages/language/src/pli.langium', 'utf8'); +const grammar = await parse(file); +const keywords = AstUtils.streamAst(grammar.parseResult.value) + .filter(GrammarAST.isKeyword) + .map(e => e.value) + .filter(e => /\w/.test(e)); + +const manual = JSON.parse(await fs.readFile('./packages/vscode-extension/syntaxes/pli.manual.json', 'utf8')); + +const controlKeywords = [ + 'if', + 'else', + 'then', + 'do', + 'end', + 'on', + 'while', + 'next', + 'go', + 'to', + 'goto', + 'return', + 'when', + 'begin' +]; + +const storageKeywords = keywords.exclude(controlKeywords).toArray(); + +function toPattern(keywords) { + const patterns = []; + for (const keyword of keywords) { + let keywordPattern = ''; + for (const char of keyword) { + if (char.toUpperCase() !== char.toLowerCase()) { + keywordPattern += `[${char.toUpperCase()}${char.toLowerCase()}]`; + } else { + keywordPattern += RegExpUtils.escapeRegExp(char); + } + } + patterns.push(keywordPattern); + } + return `\\b(${patterns.join('|')})\\b`; +} + +const controlPattern = toPattern(controlKeywords); +const storagePattern = toPattern(storageKeywords); + +manual.patterns.unshift({ + name: 'keyword.control.pli', + match: controlPattern +}); + +manual.patterns.unshift({ + name: 'keyword.storage.pli', + match: storagePattern +}); + +const json = JSON.stringify(manual, null, 2); +await fs.writeFile('./packages/vscode-extension/syntaxes/pli.merged.json', json); diff --git a/tsconfig.build.json b/tsconfig.build.json new file mode 100644 index 0000000..6fd5dd7 --- /dev/null +++ b/tsconfig.build.json @@ -0,0 +1,14 @@ +{ + "files": [], + "references": [ + { + "path": "./packages/language/tsconfig.src.json" + }, + { + "path": "./packages/language/tsconfig.test.json" + }, + { + "path": "./packages/vscode-extension/tsconfig.json" + } + ] +} diff --git a/tsconfig.json b/tsconfig.json new file mode 100644 index 0000000..a423856 --- /dev/null +++ b/tsconfig.json @@ -0,0 +1,27 @@ +{ + "compilerOptions": { + "target": "ES2020", + "module": "ES2022", + "moduleResolution": "Bundler", + "lib": ["ES2022"], + "sourceMap": true, + "strict": true, + "noUnusedLocals": true, + "noImplicitReturns": true, + "noImplicitOverride": true, + "esModuleInterop": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true, + "declaration": true, + "composite": true + }, + "include": [ + "**/src/**/*", + "**/test/**/*" + ], + "exclude": [ + "**/lib/**/*", + "**/out/**/*", + "**/node_modules/**/*" + ] +} diff --git a/vitest.config.ts b/vitest.config.ts new file mode 100644 index 0000000..c972344 --- /dev/null +++ b/vitest.config.ts @@ -0,0 +1,25 @@ +/** + * This program and the accompanying materials are made available under the terms of the + * Eclipse Public License v2.0 which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-v20.html + * + * SPDX-License-Identifier: EPL-2.0 + * + * Copyright Contributors to the Zowe Project. + * + */ + +/* + * For a detailed explanation regarding each configuration property and type check, visit: + * https://vitest.dev/config/ + */ +import { defineConfig } from 'vitest/config'; + +export default defineConfig({ + test: { + deps: { + interopDefault: true + }, + include: ['packages/**/test/**/*.test.ts'] + } +}); From 3ba6786f4d38855244e02a4de12522de19180a6d Mon Sep 17 00:00:00 2001 From: Benjamin Friedman Wilson Date: Thu, 5 Dec 2024 17:02:29 +0100 Subject: [PATCH 2/2] adds in extracted pli compiler messages/codes --- .../IBM1295IE-sole-bound-specified.ts | 6 +- .../src/validation/messages/pli-codes.ts | 18347 ++++++++++++++++ 2 files changed, 18351 insertions(+), 2 deletions(-) create mode 100644 packages/language/src/validation/messages/pli-codes.ts diff --git a/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts b/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts index 6cf68f7..25c27dd 100644 --- a/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts +++ b/packages/language/src/validation/messages/IBM1295IE-sole-bound-specified.ts @@ -1,5 +1,6 @@ import { ValidationAcceptor } from "langium"; import { Bound, DimensionBound, isLiteral, isNumberLiteral, isUnaryExpression } from "../../generated/ast"; +import { Error } from "./pli-codes"; export function IBM1295IE_sole_bound_specified(bound: DimensionBound, accept: ValidationAcceptor): void { if(bound.bound2 !== undefined) { @@ -7,10 +8,11 @@ export function IBM1295IE_sole_bound_specified(bound: DimensionBound, accept: Va } const upper = bound.bound1; if(isBoundNegative(upper) || isBoundZero(upper)) { - accept("error", "Sole bound specified is less than 1. An upper bound of 1 is assumed.", { + const code = Error.IBM1295I; + accept("error", code.message, { node: bound, property: "bound1", - code: "IBM1295IE" + code: code.fullCode }); } } diff --git a/packages/language/src/validation/messages/pli-codes.ts b/packages/language/src/validation/messages/pli-codes.ts new file mode 100644 index 0000000..d309e5a --- /dev/null +++ b/packages/language/src/validation/messages/pli-codes.ts @@ -0,0 +1,18347 @@ +/** + * Generated by process-codes-into-ts.ts + * on 2024-12-05T16:01:00.911Z + * from PL/I Messages & Codes 6.1 Documentation + * Version 6 Release 1 (GC31-5717-00) + **/ + + +export type Severity = 'I' | 'W' | 'E' | 'S' | 'U'; + + +export type PLICode = SimplePLICode | ParametricPLICode; + +/** + * Used for non-parametric PLI compiler codes/messages + */ +export interface SimplePLICode { + /** + * The IBM code itself, without severity, ex. 'IBM1018I' + */ + code: string; + + /** + * Code severity, one of 'I', 'W', 'E', 'S', 'U', comes after the code itself + */ + severity: Severity; + + /** + * Full code w/ severity, ex. 'IBM1018I I' + */ + fullCode: string; + + /** + * Human readable message for the code + */ + message: string; +} + +/** + * Used for parametric PLI compiler codes/messages + */ +export interface ParametricPLICode { + /** + * The IBM code itself, without severity, ex. 'IBM1018I' + */ + code: string; + + /** + * Code severity, one of 'I', 'W', 'E', 'S', 'U', comes after the code itself + */ + severity: Severity; + + /** + * Full code w/ severity, ex. 'IBM1018I I' + */ + fullCode: string; + + /** + * Message for the code, with placeholders for parameters + */ + message: (...args: string[]) => string; +} + +export const Info = { + + /** + * This message is used in building the options listing. + * (see page 1) + */ + IBM1018I: { + "code": "IBM1018I", + "severity": "I", + "message": (optionname: string) => `${optionname} should be specified within OPTIONS, but is accepted as is.`, + "fullCode": "IBM1018II" + } as ParametricPLICode, + + /** + * The statement following the statement for which this message was issued were merged + * with that statement. + * (see page 1) + */ + IBM1035I: { + "code": "IBM1035I", + "severity": "I", + "message": "The next statement was merged with this statement.", + "fullCode": "IBM1035II" + } as SimplePLICode, + + /** + * The specified number of statements following the statement for which this message + * was issued were merged with that statement. + * (see page 1) + */ + IBM1036I: { + "code": "IBM1036I", + "severity": "I", + "message": (statementcount: string) => `The next ${statementcount} statements were merged with this statement.`, + "fullCode": "IBM1036II" + } as ParametricPLICode, + + /** + * This message is used to report back end informational messages. + * (see page 1) + */ + IBM1038I: { + "code": "IBM1038I", + "severity": "I", + "message": (note: string) => `${note}`, + "fullCode": "IBM1038II" + } as ParametricPLICode, + + /** + * All variables should be declared except for contextual declarations of built-in functions, + * SYSPRINT and SYSIN. + * (see page 1) + */ + IBM1039I: { + "code": "IBM1039I", + "severity": "I", + "message": (variablename: string) => `Variable ${variablename} is implicitly declared.`, + "fullCode": "IBM1039II" + } as ParametricPLICode, + + /** + * This message is used by %NOTE statements with a return code of 0. + * (see page 1) + */ + IBM1040I: { + "code": "IBM1040I", + "severity": "I", + "message": (note: string) => `${note}`, + "fullCode": "IBM1040II" + } as ParametricPLICode, + + /** + * A comment ends on a different line than it begins. This may indicate that an end-of-comment + * delimiter is missing. + * (see page 1) + */ + IBM1041I: { + "code": "IBM1041I", + "severity": "I", + "message": (linecount: string) => `Comment spans ${linecount} lines.`, + "fullCode": "IBM1041II" + } as ParametricPLICode, + + /** + * A string ends on a different line than it begins. This may indicate that a closing + * quote is missing. + * (see page 1) + */ + IBM1042I: { + "code": "IBM1042I", + "severity": "I", + "message": (linecount: string) => `String spans ${linecount} lines.`, + "fullCode": "IBM1042II" + } as ParametricPLICode, + + /** + * There is no declare statement for the named variable, but it has been given the indicated + * attribute because of its usage. For instance, if the variable is used as a locator, + * it will be given the POINTER attribute. + * (see page 1) + */ + IBM1043I: { + "code": "IBM1043I", + "severity": "I", + "message": (variablename: string, attribute: string) => `${variablename} is contextually declared as ${attribute} .`, + "fullCode": "IBM1043II" + } as ParametricPLICode, + + /** + * The OS\/370 PL\/I and PL\/I for MVS compilers would have mapped this to 2 bytes. + * (see page 1) + */ + IBM1044I: { + "code": "IBM1044I", + "severity": "I", + "message": "FIXED BINARY with precision 7 or less is mapped to 1 byte.", + "fullCode": "IBM1044II" + } as SimplePLICode, + + /** + * The OS\/370 PL\/I and PL\/I for MVS compilers would have handled UNSPEC applied to + * an array as an array of scalars. + * (see page 1) + */ + IBM1046I: { + "code": "IBM1046I", + "severity": "I", + "message": "UNSPEC applied to an array is handled as a scalar reference.", + "fullCode": "IBM1046II" + } as SimplePLICode, + + /** + * If the ORDER option applies to a block, optimization is likely to be inhibited, especially + * if the block contains ON-units that refer to variables declared outside the ON-unit + * . + * (see page 1) + */ + IBM1047I: { + "code": "IBM1047I", + "severity": "I", + "message": "ORDER option may inhibit optimization.", + "fullCode": "IBM1047II" + } as SimplePLICode, + + /** + * A GET DATA statement can alter almost any variable, and a PUT DATA statement requires + * almost all variables to be stored home anytime a PUT DATA statement might be executed. + * Both of these requirements inhibit optimization. + * (see page 1) + */ + IBM1048I: { + "code": "IBM1048I", + "severity": "I", + "message": "GET/PUT DATA without a data-list inhibits optimization.", + "fullCode": "IBM1048II" + } as SimplePLICode, + + /** + * The INITIAL attribute has been specified for a variable with the attributes RESERVED + * STATIC. Unless such a variable is listed in the EXPORTS clause of a PACKAGE statement, + * the variable will not be initialized. + * (see page 2) + */ + IBM1050I: { + "code": "IBM1050I", + "severity": "I", + "message": "INITIAL attribute for RESERVED STATIC is ignored.", + "fullCode": "IBM1050II" + } as SimplePLICode, + + /** + * This message applies to the ADDR, CURRENTSTORAGE\/SIZE and STORAGE\/SIZE built-in + * functions. Applying any one of these built-in functions to an unaligned bit variable + * may not produce the results you expected. + * (see page 2) + */ + IBM1051I: { + "code": "IBM1051I", + "severity": "I", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built-in function may not be byte aligned.`, + "fullCode": "IBM1051II" + } as ParametricPLICode, + + /** + * When a string with * extent or an array with * extents is passed, PL\/I normally + * passes a descriptor so that the called routine knows how big the passed argument + * really is. The NODESCRIPTOR attribute indicates that no descriptor should be passed; + * this is invalid if the called routine is a PL\/I procedure. + * ```pli + * dcl x entry( char(*), fixed bin(31) ) + * options( nodescriptor ); + * ``` + * (see page 2) + */ + IBM1052I: { + "code": "IBM1052I", + "severity": "I", + "message": "The NODESCRIPTOR attribute is accepted even though some arguments have * extents.", + "fullCode": "IBM1052II" + } as SimplePLICode, + + /** + * If one of the built-in functions ADD, DIVIDE, MULTIPLY or SUBTRACT is invoked with + * argument that have type FIXED, if either operand has a non-zero scale factor, the + * result will have type FIXED DEC. + * (see page 2) + */ + IBM1053I: { + "code": "IBM1053I", + "severity": "I", + "message": "Scaled FIXED operation evaluated as FIXED DECIMAL.", + "fullCode": "IBM1053II" + } as SimplePLICode, + + /** + * This message can be used to help find code that may be very expensive if executed + * as part of a loop or to find code involving conversions of unlike types. + * (see page 2) + */ + IBM1058I: { + "code": "IBM1058I", + "severity": "I", + "message": (sourcetype: string, targettype: string) => `Conversion from ${sourcetype} to ${targettype} will be done by library call.`, + "fullCode": "IBM1058II" + } as ParametricPLICode, + + /** + * The ERROR condition will be raised if no WHEN clause is satisfied. + * (see page 2) + */ + IBM1059I: { + "code": "IBM1059I", + "severity": "I", + "message": "SELECT statement contains no OTHERWISE clause.", + "fullCode": "IBM1059II" + } as SimplePLICode, + + /** + * The PL\/I language rules require this, but it might be a little surprising. In the + * following code fragment, for instance, the display statement would display the value + * of x.y. + * ```pli + * a: proc; + * dcl y fixed bin init(3); + * call b; + * b: proc; + * dcl + * 1 x, + * 2 y fixed bin init(5), + * 2 z fixed bin init(7); + * display( y ); + * end; + * end a; + * ``` + * (see page 2) + */ + IBM1060I: { + "code": "IBM1060I", + "severity": "I", + "message": (identifier: string) => `Name resolution for ${identifier} selected its declaration in a structure, rather than its non- member declaration in a parent block.`, + "fullCode": "IBM1060II" + } as ParametricPLICode, + + /** + * Use of any of the constants 365, 1900 or '19' may indicate a date calculation. If + * this is true, you should examine the calculation to determine if it will be valid + * after the year 1999. + * (see page 2) + */ + IBM1061I: { + "code": "IBM1061I", + "severity": "I", + "message": "Probable DATE calculation should be examined for validity after the year 1999.", + "fullCode": "IBM1061II" + } as SimplePLICode, + + /** + * The indicated was inferred to contain a two-digit year because, for example, it was + * assigned the DATE built- in function. + * (see page 2) + */ + IBM1062I: { + "code": "IBM1062I", + "severity": "I", + "message": (variable: string) => `${variable} inferred to contain a two- digit year.`, + "fullCode": "IBM1062II" + } as ParametricPLICode, + + /** + * Under OPT(2), any specification of TEST hooks stronger than TEST(BLOCK) is not supported + * . + * (see page 3) + */ + IBM1064I: { + "code": "IBM1064I", + "severity": "I", + "message": "Use of OPT(2) forces TEST(BLOCK).", + "fullCode": "IBM1064II" + } as SimplePLICode, + + /** + * The named short floating-point constant cannot be exactly represented. It could be + * more accurately represented if it were specified as a long floating- point constant. + * For example, the 1.3E0 cannot be exactly represented, but could be better represented + * as 1.3D0. + * (see page 3) + */ + IBM1065I: { + "code": "IBM1065I", + "severity": "I", + "message": (constant: string) => `FLOAT constant ${constant} would be more precise if specified as a long FLOAT.`, + "fullCode": "IBM1065II" + } as ParametricPLICode, + + /** + * If a DO specification has no clause such as TO, BY or REPEAT that could cause the + * loop to be repeated, then the UNTIL clause will have no effect on the loop and will + * be ignored. + * ```pli + * do x = y until ( z > 0 ); + * ... + * end; + * ``` + * (see page 3) + */ + IBM1067I: { + "code": "IBM1067I", + "severity": "I", + "message": "UNTIL clause ignored.", + "fullCode": "IBM1067II" + } as SimplePLICode, + + /** + * If a procedure contains a RETURN statement, it should have the RETURNS attribute + * specified on its PROCEDURE statement. + * ```pli + * a: proc; + * return( 0 ); + * end; + * ``` + * (see page 3) + */ + IBM1068I: { + "code": "IBM1068I", + "severity": "I", + "message": "PROCEDURE has no RETURNS attribute, but contains a RETURN statement. A RETURNS attribute will be assumed.", + "fullCode": "IBM1068II" + } as SimplePLICode, + + /** + * The AUTOMATIC variables in a block may be used in the declare statements and the + * executable statements of any contained block, but in the block in which they are + * declared, they should be used only in the executable statements. + * ```pli + * dcl x fixed bin(15) init(5); + * dcl y(x) fixed bin(15); + * ``` + * (see page 3) + */ + IBM1069I: { + "code": "IBM1069I", + "severity": "I", + "message": "The AUTOMATIC variables in a block should not be used in the prologue of that block.", + "fullCode": "IBM1069II" + } as SimplePLICode, + + /** + * The named procedure is not external and is never referenced in the compilation unit. + * This may represent an error (if it was supposed to be called) or an opportunity + * to eliminate some dead code. + * (see page 3) + */ + IBM2800I: { + "code": "IBM2800I", + "severity": "I", + "message": (procname: string) => `The PROCEDURE ${procname} is not referenced.`, + "fullCode": "IBM2800II" + } as ParametricPLICode, + + /** + * Under RULES(IBM), when an arithmetic operation has an operand that is FIXED BIN and + * an operand that is FIXED DEC with a non-zero scale factor, then the FIXED DEC operand + * will be converted to FIXED BIN. + * (see page 3) + */ + IBM2801I: { + "code": "IBM2801I", + "severity": "I", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string, resultprecision: string, resultscale: string) => `FIXED DEC( ${sourceprecision} , ${sourcescale} ) operand will be converted to FIXED BIN( ${targetprecision} , ${targetscale} ). This introduces a non-zero scale factor into an integer operation and will produce a result with the attributes FIXED BIN( ${resultprecision} , ${resultscale} ).`, + "fullCode": "IBM2801II" + } as ParametricPLICode, + + /** + * This message can be used to help find code that may be very expensive if executed + * as part of a loop. It may be produced, for example, if your code refers to an element + * of a structure that uses REFER. If the structure uses multiple REFERs and the element + * occurs after the last REFER, the single reference to that element may produce multiple + * copies of this message (because multiple library calls will be made). + * (see page 3) + */ + IBM2802I: { + "code": "IBM2802I", + "severity": "I", + "message": "Aggregate mapping will be done by library call.", + "fullCode": "IBM2802II" + } as SimplePLICode, + + /** + * This message is issued when a PUT or GET STRING EDIT statement has been optimized + * by the compiler so that most of it is done inline. + * (see page 3) + */ + IBM2803I: { + "code": "IBM2803I", + "severity": "I", + "message": (keyword: string) => `${keyword} STRING EDIT statement optimized.`, + "fullCode": "IBM2803II" + } as ParametricPLICode, + + /** + * This message can be used to help find code that may be very expensive if executed + * as part of a loop or to find code involving conversions of unlike types. + * (see page 4) + */ + IBM2805I: { + "code": "IBM2805I", + "severity": "I", + "message": (variablename: string, sourcetype: string, targettype: string) => `For assignment to ${variablename} , conversion from ${sourcetype} to ${targettype} will be done by library call.`, + "fullCode": "IBM2805II" + } as ParametricPLICode, + + /** + * It is generally very unwise to pass a label to another routine. It would be good + * to think about redesigning any code doing this. + * (see page 4) + */ + IBM2806I: { + "code": "IBM2806I", + "severity": "I", + "message": "Passing a LABEL to another routine is poor coding practice and will cause the compiler to generate less than optimal code.", + "fullCode": "IBM2806II" + } as SimplePLICode, + + /** + * If the LIMITS option specifies a maximum FIXED precision greater than 31, then an + * operation involving a FIXED DEC and a FIXED BIN operand might produce an 8-byte + * integer result even if both operands are \"small\". For example, if you add a FIXED + * DEC(13) and a FIXED BIN(31), the result would be an 8-byte integer (because a FIXED + * DEC(13) value might be too large to fit in a 4-byte integer). To avoid this, you + * could apply the DECIMAL built-in function to the FIXED BIN operand. + * (see page 4) + */ + IBM2809I: { + "code": "IBM2809I", + "severity": "I", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string) => `FIXED DEC( ${sourceprecision} , ${sourcescale} ) operand will be converted to FIXED BIN( ${targetprecision} , ${targetscale} ). This introduces 8-byte integer arithmetic into an operation that might be faster if computed in decimal.`, + "fullCode": "IBM2809II" + } as ParametricPLICode, + + /** + * In certain conversions of FIXED BIN(p,q) to FIXED DEC, the old compiler slightly + * rounded the result if q was positive. + * (see page 4) + */ + IBM2810I: { + "code": "IBM2810I", + "severity": "I", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string) => `Conversion of FIXED BIN( ${sourceprecision} , ${sourcescale} ) to FIXED DEC( ${targetprecision} , ${targetscale} ) may produce a more accurate result than under the old compiler.`, + "fullCode": "IBM2810II" + } as ParametricPLICode, + + /** + * For functions such as VERIFY(x,y), if y is a constant, it is much better for performance + * to declare y with the VALUE attribute rather than with the INITIAL attribute. + * (see page 4) + */ + IBM2812I: { + "code": "IBM2812I", + "severity": "I", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built- in function would lead to much better code if declared with the VALUE attribute.`, + "fullCode": "IBM2812II" + } as ParametricPLICode, + + /** + * This message can be used to help find code that may be expensive if invoked many + * times. This message may be produced for ALLOCATE statements for BASED and CONTROLLED + * variables with non-constant extents, and it may also be produced for the prologue + * of PROCEDUREs that use AUTOMATIC variables with non-constant extents. + * (see page 4) + */ + IBM2814I: { + "code": "IBM2814I", + "severity": "I", + "message": "Aggregate mapping for storage allocation will be done by library call.", + "fullCode": "IBM2814II" + } as SimplePLICode, + + /** + * A BYVALUE argument should be one that could reasonably be passed in a register. Hence + * its type should be either one of REAL FIXED BIN, REAL FLOAT, POINTER, OFFSET, HANDLE, + * LIMITED ENTRY, FILE, ORDINAL, CHAR(1), WCHAR(1), or ALIGNED BIT(n) with n less than + * or equal to 8. + * (see page 4) + */ + IBM2815I: { + "code": "IBM2815I", + "severity": "I", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is not recommended to be passed BYVALUE.", + "fullCode": "IBM2815II" + } as SimplePLICode, + + /** + * A BYVALUE parameter should be one that could reasonably be passed in a register. + * Hence its type should be either one of REAL FIXED BIN, REAL FLOAT, POINTER, OFFSET, + * HANDLE, LIMITED ENTRY, FILE, ORDINAL, CHAR(1), WCHAR(1), or ALIGNED BIT(n) with + * n less than or equal to 8. + * (see page 4) + */ + IBM2816I: { + "code": "IBM2816I", + "severity": "I", + "message": "BYVALUE parameters should ideally be ones that can reasonably be passed in registers.", + "fullCode": "IBM2816II" + } as SimplePLICode, + + /** + * Using BYVALUE in RETURNS is recommended only if the value to be returned has a type + * that could reasonably be returned in a register. Hence its type should be either + * one of REAL FIXED BIN, REAL FLOAT, POINTER, OFFSET, HANDLE, LIMITED ENTRY, FILE, + * ORDINAL, CHAR(1), WCHAR(1), or ALIGNED BIT(n) with n less than or equal to 8. + * (see page 5) + */ + IBM2817I: { + "code": "IBM2817I", + "severity": "I", + "message": "BYVALUE in RETURNS is recommended only for types that can reasonably be returned in registers.", + "fullCode": "IBM2817II" + } as SimplePLICode, + + /** + * The precision required to hold the result as defined by PL\/I of this add (or subtract) + * is greater than the LIMITS(FIXEDDEC) maximum for the operands and hence depending + * on the data values, FIXEDOVERFLOW may be raised by the operation. + * (see page 5) + */ + IBM2818I: { + "code": "IBM2818I", + "severity": "I", + "message": (precision: string, scalefactor: string, precision2: string, scalefactor2: string) => `Addition or subtraction of FIXED DEC( ${precision} , ${scalefactor} ) and FIXED DEC( ${precision2} , ${scalefactor2} ) may raise FIXEDOVERFLOW.`, + "fullCode": "IBM2818II" + } as ParametricPLICode, + + /** + * The precision required to hold the result as defined by PL\/I of this multiply is + * greater than the LIMITS(FIXEDDEC) maximum for the operands and hence depending on + * the data values, FIXEDOVERFLOW may be raised by the operation. + * (see page 5) + */ + IBM2819I: { + "code": "IBM2819I", + "severity": "I", + "message": (precision: string, scalefactor: string, precision2: string, scalefactor2: string) => `Multiplication of FIXED DEC( ${precision} , ${scalefactor} ) and FIXED DEC( ${precision2} , ${scalefactor2} ) may raise FIXEDOVERFLOW.`, + "fullCode": "IBM2819II" + } as ParametricPLICode, + + /** + * The named compiler option is not supported on this platform. For example, the BLKOFF + * option is an option on the z\/OS platform, but not on AIX or Windows. If specified + * on those platforms, it is ignored. + * (see page 5) + */ + IBM2820I: { + "code": "IBM2820I", + "severity": "I", + "message": (optionname: string) => `The ${optionname} option is not supported on this platform.`, + "fullCode": "IBM2820II" + } as ParametricPLICode, + + /** + * This message can be used to help find code that may be very expensive if executed + * as part of a loop or to find code involving conversions of unlike types. + * (see page 5) + */ + IBM2825I: { + "code": "IBM2825I", + "severity": "I", + "message": (sourcetype: string, targettype: string) => `Conversion from ${sourcetype} to ${targettype} will be done by library call.`, + "fullCode": "IBM2825II" + } as ParametricPLICode, + + /** + * This message can be used to help find code that may be very expensive if executed + * as part of a loop or to find code involving conversions of unlike types. + * (see page 5) + */ + IBM2826I: { + "code": "IBM2826I", + "severity": "I", + "message": (variablename: string, sourcetype: string, targettype: string) => `For assignment to ${variablename} , conversion from ${sourcetype} to ${targettype} will be done by library call.`, + "fullCode": "IBM2826II" + } as ParametricPLICode, + + /** + * For example, the conversion of the FLOAT DEC(15) value 321.1234 to FIXED DEC(15,15) + * will produce the inexact result 0.123399999999952. However, the conversion of the + * FLOAT DEC(15) value 54321.1234 to FIXED DEC(15,15) will produce the incorrect result + * 0.372036854775807. Incorrect results can be avoided in a conversion to FIXED DEC(p,q) + * if the absolute value of the source is less than 10**(18-p). + * (see page 5) + */ + IBM2827I: { + "code": "IBM2827I", + "severity": "I", + "message": (sourcetype: string, targettype: string) => `Conversion from ${sourcetype} to ${targettype} can produce an inexact or incorrect result.`, + "fullCode": "IBM2827II" + } as ParametricPLICode, + + /** + * If the VALUE type function is applied to a structure type which has an initial attribute + * on only some of its elements, then the structure instance will be only partially + * initialized. For example, the compiler will flag the following code with this message + * because B2 has no initial value - it will have the initial values from type a only + * if B2 is also declared with the attribute init( value(: a :) ). + * ```pli + * if ( a < b ) = true then + * define structure + * 1 a, + * 2 a1 fixed bin(31) init( 17 ), + * 2 a2 fixed bin(31) init( 19 ); + * define structure + * 1 b, + * 2 b1 fixed bin(31) init( 119 ), + * 2 b2 type a; + * dcl x type b; + * ``` 5 + * ```pli + * x = value(: b :); + * ``` + * (see page 5) + */ + IBM2830I: { + "code": "IBM2830I", + "severity": "I", + "message": (typename: string) => `VALUE(: ${typename} :) will return an instance of the structure type that is only partially initialized.`, + "fullCode": "IBM2830II" + } as ParametricPLICode, + + /** + * This message warns that the compiler has detected an ASSERT UNREACHABLE statement + * that can never be run as the flow of control must always pass it by. + * (see page 6) + */ + IBM2831I: { + "code": "IBM2831I", + "severity": "I", + "message": "ASSERT statement may never be executed.", + "fullCode": "IBM2831II" + } as SimplePLICode, + + /** + * The compiler will perform no inling if the TEST option is on. + * (see page 6) + */ + IBM2832I: { + "code": "IBM2832I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} and all other PROCEDUREs since the TEST option is on.`, + "fullCode": "IBM2832II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE that has ENTRY statements. + * (see page 6) + */ + IBM2833I: { + "code": "IBM2833I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it contains ENTRY statements.`, + "fullCode": "IBM2833II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE or BEGIN block that contains other PROCEDUREs + * or BEGIN blocks. + * (see page 6) + */ + IBM2834I: { + "code": "IBM2834I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it contains nested PROCEDUREs and/or BEGIN blocks.`, + "fullCode": "IBM2834II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE that requires has the NODESCRIPTOR option + * but would normally be passed descriptors with its arguments. + * (see page 6) + */ + IBM2835I: { + "code": "IBM2835I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it has OPTIONS(NODESCRIPTOR), but has some parameters with nonconstant extents.`, + "fullCode": "IBM2835II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE that which has any labels that are possibly + * the target of a GOTO from another PROCEDURE or BEGIN block. + * (see page 6) + */ + IBM2836I: { + "code": "IBM2836I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it contains labels that may be targets of out-of-block GOTOs.`, + "fullCode": "IBM2836II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE that has any PUT DATA or GET DATA statements + * . + * (see page 6) + */ + IBM2837I: { + "code": "IBM2837I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it contains some DATA-directed I/O statements.`, + "fullCode": "IBM2837II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE that has any condition enablement that differs + * from the default. + * (see page 6) + */ + IBM2838I: { + "code": "IBM2838I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it has non-default condition enablement.`, + "fullCode": "IBM2838II" + } as ParametricPLICode, + + /** + * The compiler will not inline a PROCEDURE that has any ON statements. + * (see page 6) + */ + IBM2839I: { + "code": "IBM2839I", + "severity": "I", + "message": (procedurename: string) => `INLINE directive will be ignored for ${procedurename} since it contains ON-units.`, + "fullCode": "IBM2839II" + } as ParametricPLICode, + + /** + * If the first and third arguments to the TRANSLATE built-in function are both constant, + * then the code is likely trying to reformat a date-time value. This code would be + * easier to understand if the REPATTERN built-in function or, if possible, the DATETIME + * built- in function were used instead. For example, the first two bits of code below + * assign the same value to the target variable shortdate, and the second two bits + * of code also assign the same value to the target variable currentdate. However, + * in each case, the second statement is much clearer. + * ```pli + * shortdate + * = translate( '12.34.5678', + * longdate, + * '56783412abcdefghijkl' ); + * shortdate + * ``` 6 + * ```pli + * = repattern( longdate, + * 'DD.MM.YYYY', + * 'YYYYMMDDHHMISS999' ); + * currentdate + * = translate( '12.34.5678', + * datetime(), + * '56783412abcdefghijkl' ); + * currentdate + * = datetime( 'DD.MM.YYYY' ); + * ``` + * (see page 6) + */ + IBM2840I: { + "code": "IBM2840I", + "severity": "I", + "message": "If TRANSLATE is being used to reformat a date-time value, it would be better to use the REPATTERN or DATETIME built-in function instead.", + "fullCode": "IBM2840II" + } as SimplePLICode, + + /** + * MEMCU12 will perform much better than MEMCONVERT. + * (see page 7) + */ + IBM2841I: { + "code": "IBM2841I", + "severity": "I", + "message": "Changing MEMCONVERT(p,n,1200,q,m,1208 ) to MEMCU12(p,n,q,m) would be better for performance.", + "fullCode": "IBM2841II" + } as SimplePLICode, + + /** + * MEMCU21 will perform much better than MEMCONVERT. + * (see page 7) + */ + IBM2842I: { + "code": "IBM2842I", + "severity": "I", + "message": "Changing MEMCONVERT(p,n,1208,q,m,1200 ) to MEMCU21(p,n,q,m) would be better for performance.", + "fullCode": "IBM2842II" + } as SimplePLICode, + + /** + * This may represent a problem especially if this occurs in an assignment statement + * and += was meant instead of =+. + * (see page 7) + */ + IBM2844I: { + "code": "IBM2844I", + "severity": "I", + "message": (characters: string) => `The characters ${characters} will be accepted as two separate characters. It would be better to separate these characters with a blank.`, + "fullCode": "IBM2844II" + } as ParametricPLICode, + + /** + * This may represent a problem especially if this occurs in an assignment statement + * and -= was meant instead of =-. + * (see page 7) + */ + IBM2845I: { + "code": "IBM2845I", + "severity": "I", + "message": (characters: string) => `The characters ${characters} will be accepted as two separate characters. It would be better to separate these characters with a blank.`, + "fullCode": "IBM2845II" + } as ParametricPLICode, + + /** + * The compiler issues this message if a compilation unit contains a PACKAGE statement + * with exactly one level-1 procedure which in turn has its own nested procedures. + * (see page 7) + */ + IBM2846I: { + "code": "IBM2846I", + "severity": "I", + "message": "It would be better to convert nested PROCEDUREs in a PACKAGE into sister nonnested PROCEDUREs.", + "fullCode": "IBM2846II" + } as SimplePLICode, + + /** + * If a RETURNS statement specifies a VARYING or VARYINGZ variable with a MAXLENGTH + * greater than the length specified in the RETURNS attribute, then it may have a value + * that is too big to be returned without truncation. For example, the variable X in + * the RETURNS statement below has a value ('TooBig') that has length greater than + * 4. It will be trimmed (to 'TooB') to fit the RETURNS attribute. + * ```pli + * x: proc returns( char(4) ); + * dcl x char(8) var; + * x = 'TooBig'; + * return( x ); + * ``` + * (see page 7) + */ + IBM2847I: { + "code": "IBM2847I", + "severity": "I", + "message": (returnlength: string, returnslength: string) => `Source in RETURN statement has a MAXLENGTH of ${returnlength} which is greater than the length of ${returnslength} in the corresponding RETURNS attribute.`, + "fullCode": "IBM2847II" + } as ParametricPLICode, + + /** + * In ADD(x,y,p,q), if the precisions of x and y are large enough compared to p (and + * q), then overflow or size might be raised. + * (see page 7) + */ + IBM2848I: { + "code": "IBM2848I", + "severity": "I", + "message": (xprecision: string, xscale: string, yprecision: string, yscale: string, resultprecision: string, resultscale: string) => `ADD of FIXED DEC( ${xprecision} , ${xscale} ) and FIXED DEC( ${yprecision} , ${yscale} ) with a result precision and scale of ( ${resultprecision} , ${resultscale} ) might overflow.`, + "fullCode": "IBM2848II" + } as ParametricPLICode, + + /** + * Note that this will occur even if the quotient would have the attributes FIXED BIN(p,0) + * in which case no rounding would be possible. For example, if x is FIXED BIN(31), + * then (x\/2) would have the attributes FIXED BIN(31). If x equals 7, then (x\/2) + * would have the value 3, and i x equals -7, then (x\/2) would have the value -3. + * However, if x is 7, CEIL(x\/2) will yield 4, and if x is -7, CEIL(x\/2) will yield + * -3, 7 + * (see page 7) + */ + IBM2851I: { + "code": "IBM2851I", + "severity": "I", + "message": "CEIL will be evaluated by computing the integral quotient and if the quotient is nonnegative, rounding it up by one if the remainder is non-zero.", + "fullCode": "IBM2851II" + } as SimplePLICode, + + /** + * Note that this will occur even if the quotient would have the attributes FIXED BIN(p,0) + * in which case no rounding would be possible. For example, if x is FIXED BIN(31), + * then (x\/2) would have the attributes FIXED BIN(31). If x equals 7, then (x\/2) + * would have the value 3, and i x equals -7, then (x\/2) would have the value -3. + * However, if x is 7, FLOOR(x\/2) will yield 3, and if x is -7, FLOOR(x\/2) will yield + * -4. 8 2600-2799) + * (see page 8) + */ + IBM2852I: { + "code": "IBM2852I", + "severity": "I", + "message": "FLOOR will be evaluated by computing the integral quotient and if the quotient is not positive, rounding it down by one if the remainder is non-zero.", + "fullCode": "IBM2852II" + } as SimplePLICode +}; + +export const Warning = { + + /** + * This message warns that the compiler has detected a statement that can never be run + * as the flow of control must always pass it by. + * (see page 9) + */ + IBM1078I: { + "code": "IBM1078I", + "severity": "W", + "message": "Statement may never be executed.", + "fullCode": "IBM1078IW" + } as SimplePLICode, + + /** + * The number of arguments should match the number of parameters in the ENTRY declaration + * . + * (see page 9) + */ + IBM1079I: { + "code": "IBM1079I", + "severity": "W", + "message": "Too few arguments have been specified for the ENTRY ${ENTRY name } .", + "fullCode": "IBM1079IW" + } as SimplePLICode, + + /** + * A PL\/I keyword which could form a complete statement has been used as statement + * label. This usage is accepted, but a colon may have been used where a semicolon + * was intended. + * ```pli + * dcl a fixed bin(31) ext; + * if a = 0 then + * put skip list( 'a = 0' ) + * else: + * a = a + 1; + * ``` + * (see page 9) + */ + IBM1080I: { + "code": "IBM1080I", + "severity": "W", + "message": (labelname: string) => `The keyword ${labelname} , which could form a complete statement, is accepted as a label name, but a colon may have been used where a semicolon was meant.`, + "fullCode": "IBM1080IW" + } as ParametricPLICode, + + /** + * The expression in the named keyword clause should be a scalar, but an array reference + * was specified. + * ```pli + * dcl p pointer; + * dcl x based char(10); + * dcl a(10) area(1000); + * allocate x in(a) set(p); + * ``` + * (see page 9) + */ + IBM1081I: { + "code": "IBM1081I", + "severity": "W", + "message": (keyword: string) => `${keyword} expression should be scalar. Lower bounds assumed for any missing subscripts.`, + "fullCode": "IBM1081IW" + } as ParametricPLICode, + + /** + * A scalar may be passed as the argument when a structure is expected, but this require + * building a \"dummy\" structure and assigning the scalar to each field in that structure + * . + * ```pli + * dcl e entry( 1 2 fixed bin(31), 2 fixed + * bin(31) ); + * dcl i fixed bin(15); + * call e( i ); + * ``` + * (see page 9) + */ + IBM1082I: { + "code": "IBM1082I", + "severity": "W", + "message": "Argument number ${argument number } in ENTRY reference ${entry name } is a scalar, but its declare specifies a structure.", + "fullCode": "IBM1082IW" + } as SimplePLICode, + + /** + * GOTO statements may not jump into DO loops, and the compiler will flag any GOTO whose + * target is a label constant inside a (different) DO loop. However, if a label inside + * a DO loop is assigned to a label variable, then this kind of error may go undetected + * . + * (see page 9) + */ + IBM1083I: { + "code": "IBM1083I", + "severity": "W", + "message": "Source in label assignment is inside a DO-loop, and an illegal jump into the loop may be attempted. Optimization will also be very inhibited.", + "fullCode": "IBM1083IW" + } as SimplePLICode, + + /** + * Under RULES(NOLAXMARGINS), there should be nothing but blanks after the right margin + * . + * (see page 9) + */ + IBM1084I: { + "code": "IBM1084I", + "severity": "W", + "message": "Nonblanks after right margin are not allowed under RULES(NOLAXMARGINS).", + "fullCode": "IBM1084IW" + } as SimplePLICode, + + /** + * The indicated variable may not have been assigned or initialized a value before it + * is used. + * (see page 9) + */ + IBM1085I: { + "code": "IBM1085I", + "severity": "W", + "message": (variable: string) => `${variable} may be unset when used.`, + "fullCode": "IBM1085IW" + } as ParametricPLICode, + + /** + * The indicated built-in function has an extended float argument, but since the corresponding + * extended routine is not yet available, it will be evaluated using the appropriate + * long routine. + * (see page 9) + */ + IBM1086I: { + "code": "IBM1086I", + "severity": "W", + "message": (builtinfunction: string) => `${builtinfunction} will be evaluated using long rather than extended routines.`, + "fullCode": "IBM1086IW" + } as ParametricPLICode, + + /** + * A value larger than HUGE(1s0) cannot be assigned to a short float. Under hexadecimal + * float, the value 3.141592E+40 could be assigned to a short float, but under IEEE, + * the maximum value that a short float can hold is about 3.40281E+38. + * (see page 10) + */ + IBM1087I: { + "code": "IBM1087I", + "severity": "W", + "message": (assumedvalue: string) => `FLOAT source is too big for its target. An appropriate HUGE value of ${assumedvalue} is assumed.`, + "fullCode": "IBM1087IW" + } as ParametricPLICode, + + /** + * The precision for a float literal is implied by the number of digits in its mantissa. + * For instance 1e99 is implicitly FLOAT DECIMAL(1), but the value 1e99 is larger than + * the largest value a FLOAT DECIMAL(1) can hold. + * (see page 10) + */ + IBM1088I: { + "code": "IBM1088I", + "severity": "W", + "message": "FLOAT literal is too big for its implicit precision. The E in the exponent will be replaced by a D.", + "fullCode": "IBM1088IW" + } as SimplePLICode, + + /** + * If the TO value is equal to the maximum value that a FIXED or PICTURE variable can + * hold, then a loop dominated by that variable will run endlessly unless exited inside + * the loop by a LEAVE or GOTO. For example, in the first code fragment below, x can + * never be bigger than 99, and the loop would be infinite. In the second code fragment + * below, y can never be bigger than 32767, and the loop would be infinite. + * ```pli + * dcl x pic'99'; + * do x = 1 to 99; + * put skip list( x ); + * end; + * dcl y fixed bin(15); + * do y = 1 to 32767; + * put skip list( y ); + * end; + * ``` + * (see page 10) + */ + IBM1089I: { + "code": "IBM1089I", + "severity": "W", + "message": "Control variable in DO loop cannot exceed TO value, and loop may be infinite.", + "fullCode": "IBM1089IW" + } as SimplePLICode, + + /** + * An expression contains a reference to a based variable with a constant value for + * its locator qualifier. This may cause a protection exception on some systems. It + * may also indicate that the variable was declared as based on NULL or SYSNULL and + * that this constant value is being used as its locator qualifier. + * ```pli + * dcl a fixed bin(31) based( null() ); + * a = 0; + * ``` + * (see page 10) + */ + IBM1090I: { + "code": "IBM1090I", + "severity": "W", + "message": "Constant used as locator qualifier.", + "fullCode": "IBM1090IW" + } as SimplePLICode, + + /** + * Except in unusual circumstances, the precision in a FIXED BIN declaration should + * be 7, 15, 31 or 63 if SIGNED and one greater if UNSIGNED. This message may indicate + * that a declare specified, for example, FIXED BIN(8) when UNSIGNED FIXED BIN(8) was + * meant. + * (see page 10) + */ + IBM1091I: { + "code": "IBM1091I", + "severity": "W", + "message": "FIXED BIN precision less than storage allows.", + "fullCode": "IBM1091IW" + } as SimplePLICode, + + /** + * Try to change the code so that it sets and tests a switch instead, or limit GOTOs + * to very small modules that do not need optimization. + * (see page 10) + */ + IBM1092I: { + "code": "IBM1092I", + "severity": "W", + "message": "GOTO whose target is or may be in another block severely limits optimization.", + "fullCode": "IBM1092IW" + } as SimplePLICode, + + /** + * The PLIXOPT string could not be parsed. See the cited LE message for more detail + * . + * (see page 10) + */ + IBM1093I: { + "code": "IBM1093I", + "severity": "W", + "message": "PLIXOPT string is invalid. See related runtime message ${message number } .", + "fullCode": "IBM1093IW" + } as SimplePLICode, + + /** + * The PLIXOPT string contains an invalid item. See the cited LE message for more detail + * . + * (see page 10) + */ + IBM1094I: { + "code": "IBM1094I", + "severity": "W", + "message": (option: string, messagenumber: string) => `Element ${option} in PLIXOPT is invalid. See related runtime message ${messagenumber} .`, + "fullCode": "IBM1094IW" + } as ParametricPLICode, + + /** + * The PLIXOPT string contains a run-time option which is not supported by LE. See the + * cited LE message for more detail. + * (see page 10) + */ + IBM1095I: { + "code": "IBM1095I", + "severity": "W", + "message": (option: string, option2: string, messagenumber: string) => `Element ${option} in PLIXOPT has been remapped to ${option2} . See related runtime message ${messagenumber} .`, + "fullCode": "IBM1095IW" + } as ParametricPLICode, + + /** + * The SPIE and STAE options have been replaced by the TRAP option. TRAP(ON) is equivalent + * to SPIE and STAE; TRAP(OFF) is equivalent to NOSPIE and NOSTAE. The combination + * SPIE and NOSTAE and the combination NOSPIE and STAE are no longer supported. See + * the cited LE message for more detail. + * (see page 11) + */ + IBM1096I: { + "code": "IBM1096I", + "severity": "W", + "message": (messagenumber: string) => `STAE and SPIE in PLIXOPT is not supported. See related runtime message ${messagenumber} .`, + "fullCode": "IBM1096IW" + } as ParametricPLICode, + + /** + * Generally, scalars should not be passed where arrays are expected, but in some situations, + * this may be what you want. + * ```pli + * dcl a entry( (*) fixed bin ) + * option(nodescriptor); + * call a( 0 ); + * ``` + * (see page 11) + */ + IBM1097I: { + "code": "IBM1097I", + "severity": "W", + "message": (argumentnumber: string, ENTRYname: string) => `Scalar accepted as argument number ${argumentnumber} in ENTRY reference ${ENTRYname} although parameter description specifies an array.`, + "fullCode": "IBM1097IW" + } as ParametricPLICode, + + /** + * A comma was followed by a semicolon rather than by a valid syntactical element (such + * as an identifier). The comma will be ignored in order to make the semicolon valid + * . + * ```pli + * dcl 1 a, 2 b fixed bin, 2 c fixed bin, ; + * ``` + * (see page 11) + */ + IBM1098I: { + "code": "IBM1098I", + "severity": "W", + "message": "Extraneous comma at end of statement ignored.", + "fullCode": "IBM1098IW" + } as SimplePLICode, + + /** + * Under RULES(IBM), when a comparison or arithmetic operation has an operand that is + * FIXED BIN and an operand that is FIXED DEC with a non-zero scale factor, then the + * FIXED DEC operand will be converted to FIXED BIN. Under RULES(ANS), when a comparison + * or arithmetic operation has an operand that is FIXED BIN and an operand that is + * FIXED DEC with a zero scale factor, then the FIXED DEC operand will be converted + * to FIXED BIN. In each case, significant digits may be lost, and if there is a fractional + * part, it may not be exactly represented as binary. For instance, under RULES(IBM), + * the assignment statement below will cause the target to have the value 29.19, and + * in the comparison, C will be converted to FIXED BIN(31,10) and significant digits + * will be lost (in fact, SIZE would be raised, but since it is disabled, this program + * would be in error). + * ```pli + * dcl a fixed dec(07,2) init(12.2); + * dcl b fixed bin(31,0) init(17); + * dcl c fixed dec(15,3) init(2097151); + * dcl d fixed bin(31,0) init(0); + * a = a + b; + * if c = d then; + * ``` + * (see page 11) + */ + IBM1099I: { + "code": "IBM1099I", + "severity": "W", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string) => `FIXED DEC( ${sourceprecision} , ${sourcescale} ) operand will be converted to FIXED BIN( ${targetprecision} , ${targetscale} ). Significant digits may be lost.`, + "fullCode": "IBM1099IW" + } as ParametricPLICode, + + /** + * An attribute (REDUCIBLE in the example below) has been specified in the OPTIONS clause + * on a BEGIN statement, but that attribute is not valid for BEGIN blocks. + * ```pli + * begin options( reducible ); + * ``` + * (see page 11) + */ + IBM1100I: { + "code": "IBM1100I", + "severity": "W", + "message": (attributeoption: string) => `The attribute ${attributeoption} is not valid on BEGIN blocks and is ignored.`, + "fullCode": "IBM1100IW" + } as ParametricPLICode, + + /** + * An attribute (DATAONLY in the example below) has been specified in the OPTIONS clause + * on a PROCEDURE statement, but that attribute is not valid for PROCEDUREs. + * ```pli + * a: proc options( dataonly ); + * ``` 11 + * (see page 11) + */ + IBM1101I: { + "code": "IBM1101I", + "severity": "W", + "message": (optionname: string) => `${optionname} is not a known PROCEDURE attribute and is ignored.`, + "fullCode": "IBM1101IW" + } as ParametricPLICode, + + /** + * The indicated attribute is valid on PROCEDURE statements, but not on BEGIN statements + * . + * ```pli + * begin recursive; + * ``` + * (see page 12) + */ + IBM1102I: { + "code": "IBM1102I", + "severity": "W", + "message": (optionname: string) => `${optionname} is not a known BEGIN attribute and is ignored.`, + "fullCode": "IBM1102IW" + } as ParametricPLICode, + + /** + * The compiler option is not supported on this platform. + * ```pli + * *process map; + * ``` + * (see page 12) + */ + IBM1103I: { + "code": "IBM1103I", + "severity": "W", + "message": (optionname: string) => `${optionname} is not a supported compiler option and is ignored.`, + "fullCode": "IBM1103IW" + } as ParametricPLICode, + + /** + * Suboptions of the compiler option are not supported on this platform. + * ```pli + * *process list(4); + * ``` + * (see page 12) + */ + IBM1104I: { + "code": "IBM1104I", + "severity": "W", + "message": (optionname: string) => `Suboptions of the compiler option ${optionname} are not supported and are ignored.`, + "fullCode": "IBM1104IW" + } as ParametricPLICode, + + /** + * Various compiler options have limits on the size of subfields. Refer to the Programming + * Guide for the limits of specific compiler options. + * ```pli + * *process margini( '+-' ); + * ``` + * (see page 12) + */ + IBM1105I: { + "code": "IBM1105I", + "severity": "W", + "message": (optionname: string, numberofletters: string) => `A suboption of the compiler option ${optionname} is too long. It is shortened to length ${numberofletters} .`, + "fullCode": "IBM1105IW" + } as ParametricPLICode, + + /** + * Condition prefixes are not allowed on DECLARE, DEFAULT, IF, ELSE, DO, END, SELECT, + * WHEN or OTHERWISE statements. + * ```pli + * (nofofl): if (x+y) > 0 then + * ``` + * (see page 12) + */ + IBM1106I: { + "code": "IBM1106I", + "severity": "W", + "message": (keyword: string) => `Condition prefixes on ${keyword} statements are ignored.`, + "fullCode": "IBM1106IW" + } as ParametricPLICode, + + /** + * An attribute (DATAONLY in the example below) has been specified in the OPTIONS clause + * on an ENTRY statement, but that attribute is not valid for ENTRY statements. + * ```pli + * a: entry options( dataonly ); + * ``` + * (see page 12) + */ + IBM1107I: { + "code": "IBM1107I", + "severity": "W", + "message": (optionname: string) => `${optionname} is not a known ENTRY statement attribute and is ignored.`, + "fullCode": "IBM1107IW" + } as ParametricPLICode, + + /** + * A character specified in the OR, NOT, QUOTE or NAMES compiler option is already defined + * in the PL\/I character set or by another compiler option. + * ```pli + * *process not('='); + * *process not('!') or('!'); + * ``` + * (see page 12) + */ + IBM1108I: { + "code": "IBM1108I", + "severity": "W", + "message": (char: string, option: string) => `The character ${char} specified in the ${option} option is already defined and may not be redefined. The redefinition will be ignored.`, + "fullCode": "IBM1108IW" + } as ParametricPLICode, + + /** + * If you wish to display the real and imaginary parts of a complex number using different + * formats, use the REAL and IMAG built-in functions and 2 format items. + * ```pli + * put edit ( x ) ( c( e(10,6), e(10,6) ) ); + * ``` + * (see page 12) + */ + IBM1109I: { + "code": "IBM1109I", + "severity": "W", + "message": "The second argument in the C- format item will be ignored.", + "fullCode": "IBM1109IW" + } as SimplePLICode, + + /** + * Split the text into 2 lines. + * ```pli + * %include x; %include y; + * ``` + * (see page 12) + */ + IBM1110I: { + "code": "IBM1110I", + "severity": "W", + "message": "The INCLUDE statement should be on a line by itself. The source on the line after the INCLUDE statement is ignored.", + "fullCode": "IBM1110IW" + } as SimplePLICode, + + /** + * The CHECK prefix is not part of the SAA PL\/I language. + * ```pli + * (check): i = j + 1; + * ``` + * (see page 12) + */ + IBM1111I: { + "code": "IBM1111I", + "severity": "W", + "message": "CHECK prefix is not supported and is ignored.", + "fullCode": "IBM1111IW" + } as SimplePLICode, + + /** + * The CHECK and PENDING conditions are not part of the SAA PL\/I language. + * ```pli + * on check ... + * ``` + * (see page 13) + */ + IBM1112I: { + "code": "IBM1112I", + "severity": "W", + "message": (conditionname: string) => `${conditionname} condition is not supported and is ignored.`, + "fullCode": "IBM1112IW" + } as ParametricPLICode, + + /** + * The named statement, for example the CHECK statement, is not part of the SAA PL\/I + * language. + * (see page 13) + */ + IBM1113I: { + "code": "IBM1113I", + "severity": "W", + "message": (verbname: string) => `${verbname} statement is not supported and is ignored.`, + "fullCode": "IBM1113IW" + } as ParametricPLICode, + + /** + * Both operands in a comparison are constant, and consequently, the result of the comparison + * is also a constant. If this comparison is the expression in an IF clause, for example, + * this means that either the THEN or ELSE clause will never be executed. + * (see page 13) + */ + IBM1114I: { + "code": "IBM1114I", + "severity": "W", + "message": "Comparands are both constant.", + "fullCode": "IBM1114IW" + } as SimplePLICode, + + /** + * For an array, an INITIAL list should not contain more values than the array has elements + * . + * ```pli + * dcl a init( 1, 2 ), b(5) init( (10) 0 ); + * ``` + * (see page 13) + */ + IBM1115I: { + "code": "IBM1115I", + "severity": "W", + "message": (count: string, variablename: string, arraysize: string) => `INITIAL list contains ${count} items, but the array ${variablename} contains only ${arraysize} . Excess is ignored.`, + "fullCode": "IBM1115IW" + } as ParametricPLICode, + + /** + * A comment ends in a different file than it begins. This may indicate that an end-of-comment + * statement is missing. + * (see page 13) + */ + IBM1116I: { + "code": "IBM1116I", + "severity": "W", + "message": "Comment spans more than one file.", + "fullCode": "IBM1116IW" + } as SimplePLICode, + + /** + * A string ends in a different file than it begins. This may indicate that a closing + * quote is missing. + * (see page 13) + */ + IBM1117I: { + "code": "IBM1117I", + "severity": "W", + "message": "String spans more than one file.", + "fullCode": "IBM1117IW" + } as SimplePLICode, + + /** + * A delimiter (for example, a blank or a comma) is required between all identifiers + * and constants. + * ```pli + * dcl 1 a, 2 b, 3c; + * ``` + * (see page 13) + */ + IBM1118I: { + "code": "IBM1118I", + "severity": "W", + "message": (nondelimiter: string, nondelimiter2: string) => `Delimiter missing between ${nondelimiter} and ${nondelimiter2} . A blank is assumed.`, + "fullCode": "IBM1118IW" + } as ParametricPLICode, + + /** + * The control variable in the DO loop is a member of an array, a structure or a union, + * and consequently, the code generated for the loop will not be optimal. + * (see page 13) + */ + IBM1119I: { + "code": "IBM1119I", + "severity": "W", + "message": (name: string) => `Code generated for DO group would be more efficient if control variable ${name} were not an aggregate member.`, + "fullCode": "IBM1119IW" + } as ParametricPLICode, + + /** + * Using one END statement to close more than one group of statements is permitted, + * but it may indicate a coding error. + * (see page 13) + */ + IBM1120I: { + "code": "IBM1120I", + "severity": "W", + "message": "Multiple closure of groups. END statements will be inserted to close intervening groups.", + "fullCode": "IBM1120IW" + } as SimplePLICode, + + /** + * The indicated character is missing, and there are no more characters in the source. + * The missing character has been inserted by the parser in order to correct your source + * . + * (see page 13) + */ + IBM1121I: { + "code": "IBM1121I", + "severity": "W", + "message": (character: string) => `Missing ${character} assumed.`, + "fullCode": "IBM1121IW" + } as ParametricPLICode, + + /** + * The indicated character is missing and has been inserted by the parser in order to + * correct your source. + * ```pli + * display( 'Program starting' ; + * ``` + * (see page 13) + */ + IBM1122I: { + "code": "IBM1122I", + "severity": "W", + "message": (character: string, character2: string) => `Missing ${character} assumed before ${character2} .`, + "fullCode": "IBM1122IW" + } as ParametricPLICode, + + /** + * Certain ENVIRONMENT options, such as RECSIZE, require suboptions. + * ```pli + * dcl f file env( recsize ); + * ``` + * (see page 14) + */ + IBM1123I: { + "code": "IBM1123I", + "severity": "W", + "message": (optionname: string, optionname2: string) => `The ENVIRONMENT option ${optionname} has been specified without a suboption. The option ${optionname2} is ignored.`, + "fullCode": "IBM1123IW" + } as ParametricPLICode, + + /** + * Certain ENVIRONMENT options, such as CONSECUTIVE, should be specified without any + * suboptions. + * ```pli + * dcl f file env( consecutive(1) ); + * ``` + * (see page 14) + */ + IBM1124I: { + "code": "IBM1124I", + "severity": "W", + "message": "A suboption has been specified for the ENVIRONMENT option ${option name } . The suboption will be ignored.", + "fullCode": "IBM1124IW" + } as SimplePLICode, + + /** + * ENVIRONMENT options should not be repeated. + * ```pli + * dcl f file env( consecutive consecutive ); + * ``` + * (see page 14) + */ + IBM1125I: { + "code": "IBM1125I", + "severity": "W", + "message": "The ENVIRONMENT option ${option name } has been specified more than once.", + "fullCode": "IBM1125IW" + } as SimplePLICode, + + /** + * The suboption type is incorrect. + * ```pli + * dcl f file env( regional(5) ); + * ``` + * (see page 14) + */ + IBM1126I: { + "code": "IBM1126I", + "severity": "W", + "message": "The ENVIRONMENT option ${option name } has an invalid suboption. The option will be ignored.", + "fullCode": "IBM1126IW" + } as SimplePLICode, + + /** + * There is no such supported ENVIRONMENT option. + * ```pli + * dcl f file env( unknown ); + * ``` + * (see page 14) + */ + IBM1127I: { + "code": "IBM1127I", + "severity": "W", + "message": (optionname: string) => `${optionname} is not a known ENVIRONMENT option. It will be ignored.`, + "fullCode": "IBM1127IW" + } as ParametricPLICode, + + /** + * The indicated option is valid only with LANGLVL(OS). + * ```pli + * dcl f file env( fb ); + * ``` + * (see page 14) + */ + IBM1128I: { + "code": "IBM1128I", + "severity": "W", + "message": "The ENVIRONMENT option ${option name } conflicts with the LANGLVL compiler option. The option will be ignored.", + "fullCode": "IBM1128IW" + } as SimplePLICode, + + /** + * An EXEC SQL or EXEC CICS statement has been found in the source program. The compiler + * will ignore these statements. + * ```pli + * exec sql ...; + * ``` + * (see page 14) + */ + IBM1129I: { + "code": "IBM1129I", + "severity": "W", + "message": (verbname: string, processorname: string) => `${verbname} ${processorname} statement ignored up to closing semicolon.`, + "fullCode": "IBM1129IW" + } as ParametricPLICode, + + /** + * The maximum length of external names is set by the EXTNAME suboption of the LIMITS + * compiler option. + * ```pli + * dcl this_name_is_long static external + * pointer; + * ``` 14 + * (see page 14) + */ + IBM1130I: { + "code": "IBM1130I", + "severity": "W", + "message": (identifier: string, identifier2: string) => `The external name ${identifier} is too long. It will be shortened to ${identifier2} .`, + "fullCode": "IBM1130IW" + } as ParametricPLICode, + + /** + * The name specified in the EXTERNAL attribute in the EXPORTS clause overrides the + * name specified in the EXTERNAL attribute on the PROCEDURE statement. + * ```pli + * a: package exports( b ext('_B') ); + * b: proc ext( 'BB' ); + * ``` + * (see page 15) + */ + IBM1131I: { + "code": "IBM1131I", + "severity": "W", + "message": (name: string) => `An EXTERNAL name specification for ${name} has been specified on its PROCEDURE statement and in the EXPORTS clause of the PACKAGE statement. The EXPORTS specification will be used.`, + "fullCode": "IBM1131IW" + } as ParametricPLICode, + + /** + * The name specified in the EXTERNAL attribute in the RESERVES clause overrides the + * name specified in the EXTERNAL attribute in the DECLARE statement. + * ```pli + * a: package reserves( b ext('_B') ); + * dcl b ext( 'BB' ) static ... + * ``` + * (see page 15) + */ + IBM1132I: { + "code": "IBM1132I", + "severity": "W", + "message": (name: string) => `An EXTERNAL name specification for ${name} has been specified in its declaration and in the RESERVES clause of the PACKAGE statement. The RESERVES specification will be used.`, + "fullCode": "IBM1132IW" + } as ParametricPLICode, + + /** + * An element of a FORMAT CONSTANT array has not been defined, for example, f(2) in + * the example below. + * ```pli + * f(1): format( x(2), a ); + * f(3): format( x(4), a ); + * ``` + * (see page 15) + */ + IBM1133I: { + "code": "IBM1133I", + "severity": "W", + "message": (labelname: string) => `The FORMAT CONSTANT array ${labelname} is not fully initialized.`, + "fullCode": "IBM1133IW" + } as ParametricPLICode, + + /** + * The named variable defines a statement label array, but not all the elements in that + * array are labels for statements in the containing procedure. + * ```pli + * l(1): display( ... ); + * l(3): display( ... ); + * ``` + * (see page 15) + */ + IBM1134I: { + "code": "IBM1134I", + "severity": "W", + "message": "The LABEL CONSTANT array ${label reference } is not fully initialized.", + "fullCode": "IBM1134IW" + } as SimplePLICode, + + /** + * An argument to one of the logical operators (or, and or not) is a constant. The result + * of the operation may also be a constant. If this operation is the expression in + * an IF clause, for example, this means that either the THEN or ELSE clause will never + * be executed. + * ```pli + * if a | '1'b then + * ``` + * (see page 15) + */ + IBM1135I: { + "code": "IBM1135I", + "severity": "W", + "message": "Logical operand is constant.", + "fullCode": "IBM1135IW" + } as SimplePLICode, + + /** + * A function, for example, a PROCEDURE or ENTRY statement with the RETURNS attribute, + * has been invoked in a CALL statement. The value that is returned by the function + * will be discarded, but the OPTIONAL attribute should be used to indicate that this + * is valid. + * (see page 15) + */ + IBM1136I: { + "code": "IBM1136I", + "severity": "W", + "message": "Function invoked as a subroutine.", + "fullCode": "IBM1136IW" + } as SimplePLICode, + + /** + * The named attribute is invalid in GENERIC description lists. + * ```pli + * dcl g generic ( f1 when( connected ), + * f2 otherwise ); + * ``` + * (see page 15) + */ + IBM1137I: { + "code": "IBM1137I", + "severity": "W", + "message": (attribute: string) => `The attribute ${attribute} is invalid in GENERIC descriptions and will be ignored.`, + "fullCode": "IBM1137IW" + } as ParametricPLICode, + + /** + * The array will be incompletely initialized. If the named variable is part of a structure, + * subsequent elements in 15 that structure with this problem will be flagged with + * message 2602. This may be a programming error (in the example below, 4 should probably + * have been 6) and may cause exceptions when the program is run. + * ```pli + * dcl a(8) fixed dec init( 1, 2, (4) 0 ); + * ``` + * (see page 15) + */ + IBM1138I: { + "code": "IBM1138I", + "severity": "W", + "message": (count: string, variablename: string, arraysize: string) => `Number of items in INITIAL list is ${count} for the array ${variablename} which contains ${arraysize} elements.`, + "fullCode": "IBM1138IW" + } as ParametricPLICode, + + /** + * The %CONTROL statement must be followed by FORMAT or NOFORMAT option enclosed in + * parentheses and then a semicolon. + * (see page 16) + */ + IBM1139I: { + "code": "IBM1139I", + "severity": "W", + "message": "Syntax of the CONTROL statement is incorrect.", + "fullCode": "IBM1139IW" + } as SimplePLICode, + + /** + * The LANGLVL option in the %OPTION statement must be specified as either LANGLVL(SAA) + * or LANGLVL(SAA2). + * (see page 16) + */ + IBM1140I: { + "code": "IBM1140I", + "severity": "W", + "message": "Syntax of the LANGLVL option in the OPTION statement is incorrect.", + "fullCode": "IBM1140IW" + } as SimplePLICode, + + /** + * The %NOPRINT statement must be followed, with optional intervening blanks, by a semicolon + * . + * (see page 16) + */ + IBM1141I: { + "code": "IBM1141I", + "severity": "W", + "message": "Syntax of the NOPRINT statement is incorrect.", + "fullCode": "IBM1141IW" + } as SimplePLICode, + + /** + * The %PAGE statement must be followed, with optional intervening blanks, by a semicolon + * . + * (see page 16) + */ + IBM1142I: { + "code": "IBM1142I", + "severity": "W", + "message": "Syntax of the PAGE statement is incorrect.", + "fullCode": "IBM1142IW" + } as SimplePLICode, + + /** + * The %PRINT statement must be followed, with optional intervening blanks, by a semicolon + * . + * (see page 16) + */ + IBM1143I: { + "code": "IBM1143I", + "severity": "W", + "message": "Syntax of the PRINT statement is incorrect.", + "fullCode": "IBM1143IW" + } as SimplePLICode, + + /** + * Skip amounts greater than 999 are not supported. + * ```pli + * %skip(2000); + * ``` + * (see page 16) + */ + IBM1144I: { + "code": "IBM1144I", + "severity": "W", + "message": "Number of lines specified with SKIP must be between 0 and 999 inclusive.", + "fullCode": "IBM1144IW" + } as SimplePLICode, + + /** + * The %SKIP statement must be followed by a semicolon with optional intervening blanks + * and a parenthesized integer. + * (see page 16) + */ + IBM1145I: { + "code": "IBM1145I", + "severity": "W", + "message": "Syntax of the SKIP statement is incorrect.", + "fullCode": "IBM1145IW" + } as SimplePLICode, + + /** + * The TEST option in the %OPTION statement must be specified without any suboptions + * . + * (see page 16) + */ + IBM1146I: { + "code": "IBM1146I", + "severity": "W", + "message": "Syntax of the TEST option in the OPTION statement is incorrect.", + "fullCode": "IBM1146IW" + } as SimplePLICode, + + /** + * The NOTEST option in the %OPTION statement must be specified without any suboptions + * . + * (see page 16) + */ + IBM1147I: { + "code": "IBM1147I", + "severity": "W", + "message": "Syntax of the NOTEST option in the OPTION statement is incorrect.", + "fullCode": "IBM1147IW" + } as SimplePLICode, + + /** + * The %PUSH statement must be followed, with optional intervening blanks, by a semicolon + * . + * (see page 16) + */ + IBM1148I: { + "code": "IBM1148I", + "severity": "W", + "message": "Syntax of the PUSH statement is incorrect.", + "fullCode": "IBM1148IW" + } as SimplePLICode, + + /** + * The %POP statement must be followed, with optional intervening blanks, by a semicolon + * . + * (see page 16) + */ + IBM1149I: { + "code": "IBM1149I", + "severity": "W", + "message": "Syntax of the POP statement is incorrect.", + "fullCode": "IBM1149IW" + } as SimplePLICode, + + /** + * The %NOTE statement must be followed by, in parentheses, a note and an optional return + * code, and then a semicolon. + * (see page 16) + */ + IBM1150I: { + "code": "IBM1150I", + "severity": "W", + "message": "Syntax of the NOTE statement is incorrect.", + "fullCode": "IBM1150IW" + } as SimplePLICode, + + /** + * The maximum FIXED BIN precision depends on the LIMITS option. + * (see page 16) + */ + IBM1151I: { + "code": "IBM1151I", + "severity": "W", + "message": (maximumvalue: string) => `FIXED BINARY precision is reduced to ${maximumvalue} .`, + "fullCode": "IBM1151IW" + } as ParametricPLICode, + + /** + * The maximum FIXED DEC precision depends on the LIMITS option. + * (see page 17) + */ + IBM1152I: { + "code": "IBM1152I", + "severity": "W", + "message": (maximumvalue: string) => `FIXED DECIMAL precision is reduced to ${maximumvalue} .`, + "fullCode": "IBM1152IW" + } as ParametricPLICode, + + /** + * The maximum FLOAT BIN precision is 64 on Intel, 106 on AIX and 109 on z\/OS. + * (see page 17) + */ + IBM1153I: { + "code": "IBM1153I", + "severity": "W", + "message": (maximumvalue: string) => `FLOAT BINARY precision is reduced to ${maximumvalue} .`, + "fullCode": "IBM1153IW" + } as ParametricPLICode, + + /** + * The maximum FLOAT DEC precision is 18 on Intel, 32 on AIX and 33 on z\/OS except + * for DFP which has a maximum of 34. + * (see page 17) + */ + IBM1154I: { + "code": "IBM1154I", + "severity": "W", + "message": (maximumvalue: string) => `FLOAT DECIMAL precision is reduced to ${maximumvalue} .`, + "fullCode": "IBM1154IW" + } as ParametricPLICode, + + /** + * Some members of an aggregate referenced in an I\/O statement are noncomputational. + * The computational members will be correctly processed, but the noncomputational + * ones will be ignored. + * ```pli + * dcl 1 x, + * 2 y ptr, + * 3 fixed bin(31); + * put skip list(x); + * ``` + * (see page 17) + */ + IBM1155I: { + "code": "IBM1155I", + "severity": "W", + "message": (aggregatename: string) => `The aggregate ${aggregatename} contains noncomputational values. Those values will be ignored.`, + "fullCode": "IBM1155IW" + } as ParametricPLICode, + + /** + * Under SYSTEM(CICS), SYSTEM(TSO) and SYSTEM(IMS), the arguments to the MAIN procedure + * should all have type POINTER. + * (see page 17) + */ + IBM1156I: { + "code": "IBM1156I", + "severity": "W", + "message": "Arguments to MAIN PROCEDURE are not all POINTER.", + "fullCode": "IBM1156IW" + } as SimplePLICode, + + /** + * This message is used by %NOTE statements with a return code of 4. + * (see page 17) + */ + IBM1157I: { + "code": "IBM1157I", + "severity": "W", + "message": (note: string) => `${note}`, + "fullCode": "IBM1157IW" + } as ParametricPLICode, + + /** + * A closing quote or parenthesis is missing in the specification of a compiler option. + * A quoted string must not cross line boundaries. + * (see page 17) + */ + IBM1158I: { + "code": "IBM1158I", + "severity": "W", + "message": (option: string, option2: string) => `A ${option} is missing in the specification of the ${option2} option. One is assumed.`, + "fullCode": "IBM1158IW" + } as ParametricPLICode, + + /** + * An invalid compiler option has been specified. + * (see page 17) + */ + IBM1159I: { + "code": "IBM1159I", + "severity": "W", + "message": (option: string) => `The string ${option} is not recognized as a valid option keyword and is ignored.`, + "fullCode": "IBM1159IW" + } as ParametricPLICode, + + /** + * Printer control characters are not supported on input source records. + * (see page 17) + */ + IBM1160I: { + "code": "IBM1160I", + "severity": "W", + "message": "The third argument to the MARGINS option is not supported.", + "fullCode": "IBM1160IW" + } as SimplePLICode, + + /** + * A suboption of a compiler option is incorrect. The suboption may be unknown or outside + * the allowable range. + * ```pli + * *process flag(q) margins(1002); + * ``` + * (see page 17) + */ + IBM1161I: { + "code": "IBM1161I", + "severity": "W", + "message": (suboption: string, option: string) => `The suboption ${suboption} is not valid for the ${option} compiler option.`, + "fullCode": "IBM1161IW" + } as ParametricPLICode, + + /** + * A required suboption of a compiler option is missing. + * ```pli + * *process or; + * ``` + * (see page 17) + */ + IBM1162I: { + "code": "IBM1162I", + "severity": "W", + "message": (suboption: string) => `A required suboption is missing for the ${suboption} option.`, + "fullCode": "IBM1162IW" + } as ParametricPLICode, + + /** + * Required suboptions of a compiler option are missing. 17 + * ```pli + * *process margins; + * ``` + * (see page 17) + */ + IBM1163I: { + "code": "IBM1163I", + "severity": "W", + "message": (option: string) => `Required sub-fields are missing for the ${option} option. Default values are assumed.`, + "fullCode": "IBM1163IW" + } as ParametricPLICode, + + /** + * The option, for example REORDER, is accepted outside of the OPTIONS attribute, but + * it should be specified within the OPTIONS attribute. This would also conform to + * the ANSI standard. + * (see page 18) + */ + IBM1164I: { + "code": "IBM1164I", + "severity": "W", + "message": (optionname: string) => `${optionname} should be specified within OPTIONS, but is accepted as is.`, + "fullCode": "IBM1164IW" + } as ParametricPLICode, + + /** + * The only supported LINKAGE options are OPTLINK and SYSTEM. + * (see page 18) + */ + IBM1165I: { + "code": "IBM1165I", + "severity": "W", + "message": (optionname: string) => `The OPTIONS option ${optionname} has been specified more than once.`, + "fullCode": "IBM1165IW" + } as ParametricPLICode, + + /** + * The only supported LINKAGE suboptions are OPTLINK and SYSTEM, and the only supported + * CMPAT suboptions are V1, V2, V3, and LE. + * (see page 18) + */ + IBM1166I: { + "code": "IBM1166I", + "severity": "W", + "message": (suboptionname: string, optionname: string, optionname2: string) => `${suboptionname} is not a known ${optionname} suboption. The ${optionname2} option will be ignored.`, + "fullCode": "IBM1166IW" + } as ParametricPLICode, + + /** + * The maximum number of pending %PUSH statements is 63. + * (see page 18) + */ + IBM1167I: { + "code": "IBM1167I", + "severity": "W", + "message": "Maximum number of PUSH statements exceeded. The control statement is ignored.", + "fullCode": "IBM1167IW" + } as SimplePLICode, + + /** + * A %POP has been issued when no %PUSH statement are pending. + * (see page 18) + */ + IBM1168I: { + "code": "IBM1168I", + "severity": "W", + "message": "No PUSH statements are in effect. The POP control statement is ignored.", + "fullCode": "IBM1168IW" + } as SimplePLICode, + + /** + * This message applies to the FIXED and FLOAT built- in functions when only one argument + * is given. The precision is not set to a default, but is instead derived from the + * argument. For example, if x is FLOAT BIN(21), FIXED(x) will return a FIXED BIN(21) + * value. + * (see page 18) + */ + IBM1169I: { + "code": "IBM1169I", + "severity": "W", + "message": (builtinname: string) => `No precision was specified for the result of the ${builtinname} built- in function. The precision will be determined from the argument.`, + "fullCode": "IBM1169IW" + } as ParametricPLICode, + + /** + * The indicated element of the OPTIONS list is not supported. + * ```pli + * dcl a ext entry options( nomap ); + * ``` + * (see page 18) + */ + IBM1170I: { + "code": "IBM1170I", + "severity": "W", + "message": "The OPTIONS attribute ${option attribute } is not supported and is ignored.", + "fullCode": "IBM1170IW" + } as SimplePLICode, + + /** + * WHEN or OTHERWISE clauses are not required on SELECT statements, but their absence + * may indicate a coding error. + * (see page 18) + */ + IBM1171I: { + "code": "IBM1171I", + "severity": "W", + "message": "SELECT statement contains no WHEN or OTHERWISE clauses.", + "fullCode": "IBM1171IW" + } as SimplePLICode, + + /** + * User-specified string has zero length. This can occur when OR('') has been specified + * on the command line or when the backslash character is specified as the only character + * in the OR string. In the latter case, the backslash character has been interpreted + * as an escape character, and so the string appears to have zero length. + * (see page 18) + */ + IBM1172I: { + "code": "IBM1172I", + "severity": "W", + "message": (optionname: string) => `A zero length string has been entered for the ${optionname} option. The option is ignored.`, + "fullCode": "IBM1172IW" + } as ParametricPLICode, + + /** + * SELECT statements do not require WHEN clauses, but their absence may indicate a coding + * error. + * (see page 18) + */ + IBM1173I: { + "code": "IBM1173I", + "severity": "W", + "message": "SELECT statement contains no WHEN clauses.", + "fullCode": "IBM1173IW" + } as SimplePLICode, + + /** + * The reference specified in the FROM or INTO clause may not be byte-aligned. If the + * reference is indeed not byte-aligned, unpredictable results may occur. + * (see page 18) + */ + IBM1174I: { + "code": "IBM1174I", + "severity": "W", + "message": "The reference in the ${frominto clause } clause may not be byte- aligned.", + "fullCode": "IBM1174IW" + } as SimplePLICode, + + /** + * The maximum precision for FIXED BINARY constants is specified by the FIXEDBIN suboption + * of the LIMITS compiler option. + * (see page 19) + */ + IBM1175I: { + "code": "IBM1175I", + "severity": "W", + "message": "FIXED BINARY constant contains too many digits. Excess nonsignificant digits will be ignored.", + "fullCode": "IBM1175IW" + } as SimplePLICode, + + /** + * The maximum precision for FIXED DECIMAL constants is specified by the FIXEDDEC suboption + * of the LIMITS compiler option. + * (see page 19) + */ + IBM1176I: { + "code": "IBM1176I", + "severity": "W", + "message": "FIXED DECIMAL constant contains too many digits. Excess nonsignificant digits will be ignored.", + "fullCode": "IBM1176IW" + } as SimplePLICode, + + /** + * Float binary constants are limited to 64 digits on Intel, 32 on AIX and 33 on z\/OS + * . + * (see page 19) + */ + IBM1177I: { + "code": "IBM1177I", + "severity": "W", + "message": "Mantissa in FLOAT BINARY constant contains more digits than the implementation maximum. Excess nonsignificant digits will be ignored.", + "fullCode": "IBM1177IW" + } as SimplePLICode, + + /** + * Float decimal constants are limited to 18 digits on Intel, 106 on AIX and 109 on + * z\/OS. + * (see page 19) + */ + IBM1178I: { + "code": "IBM1178I", + "severity": "W", + "message": "Mantissa in FLOAT DECIMAL constant contains more digits than the implementation maximum. Excess nonsignificant digits will be ignored.", + "fullCode": "IBM1178IW" + } as SimplePLICode, + + /** + * The precision for a float literal is implied by the number of digits in its mantissa. + * For instance 1e99 is implicitly FLOAT DECIMAL(1), but the value 1e99 is larger than + * the largest value a FLOAT DECIMAL(1) can hold. + * (see page 19) + */ + IBM1179I: { + "code": "IBM1179I", + "severity": "W", + "message": "FLOAT literal is too big for its implicit precision. An appropriate HUGE value is assumed.", + "fullCode": "IBM1179IW" + } as SimplePLICode, + + /** + * This message applies to the ADDR, CURRENTSTORAGE\/SIZE and STORAGE\/SIZE built-in + * functions. Applying any one of these built-in functions to a variable that is not + * byte-aligned may not produce the results you expect. + * (see page 19) + */ + IBM1180I: { + "code": "IBM1180I", + "severity": "W", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} is not byte aligned.`, + "fullCode": "IBM1180IW" + } as ParametricPLICode, + + /** + * In the following code snippet, the WHILE clause applies only to the last DO specification, + * that is only when I = 5; + * ```pli + * do i = 1, 3, 5 while( j < 5 ); + * ``` + * (see page 19) + */ + IBM1181I: { + "code": "IBM1181I", + "severity": "W", + "message": "A WHILE or UNTIL option at the end of a series of DO specifications applies only to the last specification.", + "fullCode": "IBM1181IW" + } as SimplePLICode, + + /** + * A procedure contains code that will cause it to be recursively invoked, but the procedure + * was not declared with RECURSIVE attribute. + * ```pli + * a: proc( n ); + * ... + * if n > 0 then call a; + * ``` + * (see page 19) + */ + IBM1182I: { + "code": "IBM1182I", + "severity": "W", + "message": "Invocation of a NONRECURSIVE PROCEDURE from within that PROCEDURE is invalid. RECURSIVE attribute is assumed.", + "fullCode": "IBM1182IW" + } as SimplePLICode, + + /** + * The SIGNAL statement is ignored if the condition it would raise is disabled. Some + * conditions, like SIZE, are disabled by default. + * ```pli + * (nofofl): signal fixedoverflow; + * ``` 19 + * (see page 19) + */ + IBM1183I: { + "code": "IBM1183I", + "severity": "W", + "message": (conditionname: string) => `${conditionname} condition is disabled. Statement is ignored.`, + "fullCode": "IBM1183IW" + } as ParametricPLICode, + + /** + * The string in the INITIAL clause ('TooBig' in the example below) will be trimmed + * to fit (to 'TooB'). + * ```pli + * dcl x char(4) static init('tooBig'); + * ``` + * (see page 20) + */ + IBM1184I: { + "code": "IBM1184I", + "severity": "W", + "message": (stringlength: string, variablename: string, stringlength2: string) => `Source with length ${stringlength} in INITIAL clause for ${variablename} has length greater than the length ${stringlength2} of that INITIAL variable.`, + "fullCode": "IBM1184IW" + } as ParametricPLICode, + + /** + * The string in the RETURNS clause ('TooBig' in the example below) will be trimmed + * to fit (to 'TooB'). + * ```pli + * x: proc returns( char(4) ); + * ... + * return( 'TooBig' ); + * ``` + * (see page 20) + */ + IBM1185I: { + "code": "IBM1185I", + "severity": "W", + "message": (stringlength: string) => `Source with length ${stringlength} in RETURN statement has length greater than that in the corresponding RETURNS attribute.`, + "fullCode": "IBM1185IW" + } as ParametricPLICode, + + /** + * The source in the assignment ('TooBig' in the example below) will be trimmed to fit + * (to 'TooB'). + * ```pli + * dcl x char(4); + * x = 'TooBig'; + * ``` + * (see page 20) + */ + IBM1186I: { + "code": "IBM1186I", + "severity": "W", + "message": (stringlength: string, stringlength2: string) => `Source with length ${stringlength} in string assignment has length greater than the length ${stringlength2} of the target.`, + "fullCode": "IBM1186IW" + } as ParametricPLICode, + + /** + * The source in the entry invocation ('TooBig' in the example below) will be trimmed + * to fit (to 'TooB'). + * ```pli + * dcl x entry( char(4) ); + * call x( 'TooBig' ); + * ``` + * (see page 20) + */ + IBM1187I: { + "code": "IBM1187I", + "severity": "W", + "message": (argumentnumber: string, entryname: string, stringlength: string) => `Argument number ${argumentnumber} in ENTRY reference ${entryname} has length ${stringlength} which is greater than that of the corresponding parameter.`, + "fullCode": "IBM1187IW" + } as ParametricPLICode, + + /** + * The length of the string produced by concatenating two strings must not be greater + * than the maximum allowed for the derived string type. + * (see page 20) + */ + IBM1188I: { + "code": "IBM1188I", + "severity": "W", + "message": "Result of concatenating two strings is too long.", + "fullCode": "IBM1188IW" + } as SimplePLICode, + + /** + * If NODESCRIPTOR is specified (or implied) for a procedure, aggregate parameters should + * have the CONNECTED attribute. The CONNECTED attribute can be explicitly coded, or + * it can be implied by the DEFAULT(CONNECTED) compiler option. + * (see page 20) + */ + IBM1189I: { + "code": "IBM1189I", + "severity": "W", + "message": (parametername: string) => `NODESCRIPTOR attribute conflicts with the NONCONNECTED attribute for the parameter ${parametername} . CONNECTED is assumed.`, + "fullCode": "IBM1189IW" + } as ParametricPLICode, + + /** + * The named option is not part of the PL\/I language definition as specified in the + * LANGLVL compiler option. + * (see page 20) + */ + IBM1190I: { + "code": "IBM1190I", + "severity": "W", + "message": (optionname: string) => `The OPTIONS option ${optionname} conflicts with the LANGLVL compiler option. The option will be applied.`, + "fullCode": "IBM1190IW" + } as ParametricPLICode, + + /** + * When dividing a FIXED BIN(p1,0) value by a FIXED BIN(p2,0) value where 31 > p1, the + * result will have the attributes FIXED BIN(p1,0). With ANSI 76, it would have the + * attributes FIXED BIN(31,31-p1). + * (see page 20) + */ + IBM1191I: { + "code": "IBM1191I", + "severity": "W", + "message": "Result of FIXED BIN divide will not be scaled.", + "fullCode": "IBM1191IW" + } as SimplePLICode, + + /** + * In a dominated SELECT statement, if a WHEN clause has the same value as an earlier + * WHEN clause, the code for the second WHEN clause will never be executed. This message + * will be produced only if the SELECT statement is otherwise suitable for transformation + * into a branch table. + * (see page 20) + */ + IBM1192I: { + "code": "IBM1192I", + "severity": "W", + "message": "WHEN clauses contain duplicate values.", + "fullCode": "IBM1192IW" + } as SimplePLICode, + + /** + * This message is produced if a block contains more statements than allowed by the + * MAXSTMT compiler option. It may point to blocks that are excessively large. + * (see page 20) + */ + IBM1193I: { + "code": "IBM1193I", + "severity": "W", + "message": (statementcount: string, blockname: string) => `${statementcount} statements in block ${blockname} .`, + "fullCode": "IBM1193IW" + } as ParametricPLICode, + + /** + * A MAIN procedure should have at most one argument, except under SYSTEM(CICS) and + * SYSTEM(IMS). + * (see page 21) + */ + IBM1194I: { + "code": "IBM1194I", + "severity": "W", + "message": "More than one argument to MAIN PROCEDURE.", + "fullCode": "IBM1194IW" + } as SimplePLICode, + + /** + * The argument to the MAIN procedure should be CHARACTER VARYING, except under SYSTEM(CICS), + * SYSTEM(TSO) and SYSTEM(IMS). + * (see page 21) + */ + IBM1195I: { + "code": "IBM1195I", + "severity": "W", + "message": "Argument to MAIN PROCEDURE is not CHARACTER VARYING.", + "fullCode": "IBM1195IW" + } as SimplePLICode, + + /** + * Any INITIAL attribute specified for an AREA variable is ignored. The variable will, + * instead, be initialized with the EMPTY built-in function. + * (see page 21) + */ + IBM1196I: { + "code": "IBM1196I", + "severity": "W", + "message": "AREA initialized with EMPTY - INITIAL attribute is ignored.", + "fullCode": "IBM1196IW" + } as SimplePLICode, + + /** + * All file conditions should be qualified with a file reference, but ENDFILE and ENDPAGE + * are accepted without a file reference. SYSIN and SYSPRINT are then assumed, respectively + * . + * (see page 21) + */ + IBM1197I: { + "code": "IBM1197I", + "severity": "W", + "message": (filename: string) => `${filename} assumed as file condition reference.`, + "fullCode": "IBM1197IW" + } as ParametricPLICode, + + /** + * An ENTRY reference is used where the result of invoking that entry is probably meant + * to be used. + * ```pli + * dcl e1 entry returns( ptr ); + * dcl q ptr based; + * e1->q = null(); + * dcl e2 entry returns( bit(1) ); + * if e2 then ... + * ``` + * (see page 21) + */ + IBM1198I: { + "code": "IBM1198I", + "severity": "W", + "message": (variablename: string) => `A null argument list is assumed for ${variablename} .`, + "fullCode": "IBM1198IW" + } as ParametricPLICode, + + /** + * The %LINE directive must be followed, with optional intervening blanks, by a parenthesis, + * a line number, a comma, a file name and a closing parenthesis. + * ```pli + * %line( 19, test.pli ); + * ``` + * (see page 21) + */ + IBM1199I: { + "code": "IBM1199I", + "severity": "W", + "message": "Syntax of the LINE directive is incorrect.", + "fullCode": "IBM1199IW" + } as SimplePLICode, + + /** + * The DATE built-in returns a two-digit year. It might be better to use the DATETIME + * built-in which returns a four-digit year. + * (see page 21) + */ + IBM1200I: { + "code": "IBM1200I", + "severity": "W", + "message": "Use of DATE built-in function may cause problems.", + "fullCode": "IBM1200IW" + } as SimplePLICode, + + /** + * There is a conflict of suboptions for the LANGLVL compiler option. The SAA2 and OS + * suboptions are mutually exclusive. + * ```pli + * *process langlvl(saa2 os); + * ``` + * (see page 21) + */ + IBM1201I: { + "code": "IBM1201I", + "severity": "W", + "message": (suboption: string, option: string) => `${suboption} conflicts with a previously specified suboption for the ${option} compiler option.`, + "fullCode": "IBM1201IW" + } as ParametricPLICode, + + /** + * The only option supported in the %OPTION statement is the LANGLVL option. + * (see page 21) + */ + IBM1202I: { + "code": "IBM1202I", + "severity": "W", + "message": "Syntax of the OPTION statement is incorrect.", + "fullCode": "IBM1202IW" + } as SimplePLICode, + + /** + * Change the invocation of PLITEST so that no argument is passed. + * (see page 21) + */ + IBM1203I: { + "code": "IBM1203I", + "severity": "W", + "message": "Argument to PLITEST is ignored.", + "fullCode": "IBM1203IW" + } as SimplePLICode, + + /** + * LABEL variables require block activation information, and hence they cannot be initialized + * at compile- time. For a STATIC LABEL variable with the INITIAL attribute, if the + * variable is a member of a structure or a union, a severe message will be issued. + * Otherwise, its attributes will be changed to INTERNAL CONSTANT in order to eliminate + * the requirement for block activation 21 information. Such a variable must be initialized + * with LABEL CONSTANTs from containing blocks. + * (see page 21) + */ + IBM1204I: { + "code": "IBM1204I", + "severity": "W", + "message": "INTERNAL CONSTANT assumed for initialized STATIC LABEL.", + "fullCode": "IBM1204IW" + } as SimplePLICode, + + /** + * If two arguments of the NAMES option are specified, they must be the same length. + * The second argument is the uppercase value of the first. If a character in the first + * string does not have an uppercase value, use the character itself as the uppercase + * value. For example: + * ```pli + * names( '$!@' '$!@') + * ``` + * (see page 22) + */ + IBM1205I: { + "code": "IBM1205I", + "severity": "W", + "message": (option: string) => `Arguments of the ${option} compiler option must be the same length.`, + "fullCode": "IBM1205IW" + } as ParametricPLICode, + + /** + * In an expression of the form x & y, x | y, or x ^ y, x and y should both have BIT + * type. + * (see page 22) + */ + IBM1206I: { + "code": "IBM1206I", + "severity": "W", + "message": "BIT operators should be applied only to BIT operands.", + "fullCode": "IBM1206IW" + } as SimplePLICode, + + /** + * If the operand has a numeric type, the result is the length that value would have + * after it was converted to string. The length of a numeric type is NOT the same as + * its storage requirement. + * (see page 22) + */ + IBM1207I: { + "code": "IBM1207I", + "severity": "W", + "message": "Operand to LENGTH built-in function should have string type.", + "fullCode": "IBM1207IW" + } as SimplePLICode, + + /** + * The array will be incompletely initialized. If the named variable is part of a structure, + * subsequent elements in that structure with this problem will be flagged with message + * 2603. An asterisk can be used as an initialization factor to initialize all the + * elements with one value. In the example below, a(1) is initialized with the value + * 13, while the elements a(2) through a(8) are uninitialized. In contrast, all the + * elements in b are initialized to 13. + * ```pli + * dcl a(8) fixed bin init( 13 ); + * dcl b(8) fixed bin init( (*) 13 ); + * ``` + * (see page 22) + */ + IBM1208I: { + "code": "IBM1208I", + "severity": "W", + "message": "INITIAL list for the array ${variable name } contains only one item.", + "fullCode": "IBM1208IW" + } as SimplePLICode, + + /** + * Since ISAM is not being simulated on the OS\/2 platform, the file will be treated + * in a manner similar to VSAM KSDS. The file specified in the first declaration below + * would be handled in the same manner as the file in the second declaration. Both + * are treated as ORGANIZATION(INDEXED). + * ```pli + * dcl f1 file env(indexed); + * dcl f2 file env(organization(indexed)); + * ``` + * (see page 22) + */ + IBM1209I: { + "code": "IBM1209I", + "severity": "W", + "message": (filename: string) => `INDEXED environment option for file ${filename} will be treated as ORGANIZATION(INDEXED).`, + "fullCode": "IBM1209IW" + } as ParametricPLICode, + + /** + * The format width will be too small for output if the number is negative. It might + * be valid if the format is being used for input. + * (see page 22) + */ + IBM1210I: { + "code": "IBM1210I", + "severity": "W", + "message": (keyword: string) => `The field width specified in the ${keyword} -format item may be too small for complete output of the data item.`, + "fullCode": "IBM1210IW" + } as ParametricPLICode, + + /** + * The source in the assignment ('TooBig' in the example below) will be trimmed to fit + * (to 'TooB'). If the target is a pseudovariable, message 1186 is issued instead. + * ```pli + * dcl x char(4); + * x = 'TooBig'; + * ``` + * (see page 22) + */ + IBM1211I: { + "code": "IBM1211I", + "severity": "W", + "message": (stringlength: string, stringlength2: string, variable: string) => `Source with length ${stringlength} in string assignment has length greater than the length ${stringlength2} of the target ${variable} .`, + "fullCode": "IBM1211IW" + } as ParametricPLICode, + + /** + * A width must be specified on A format items when specified on a GET statement. + * ```pli + * get edit(name) (a); + * ``` + * (see page 22) + */ + IBM1212I: { + "code": "IBM1212I", + "severity": "W", + "message": "The A format item requires an argument when used in GET statement. An L format item is assumed in its place.", + "fullCode": "IBM1212IW" + } as SimplePLICode, + + /** + * The named procedure is not external and is never referenced in any live code in the + * compilation unit. This may represent an error (if it was supposed to be called) + * or an opportunity to eliminate some dead code. + * (see page 22) + */ + IBM1213I: { + "code": "IBM1213I", + "severity": "W", + "message": (procname: string) => `The PROCEDURE ${procname} is not referenced.`, + "fullCode": "IBM1213IW" + } as ParametricPLICode, + + /** + * An argument passed BYADDR to an entry does not match the corresponding parameter + * in the entry description. The address of the argument will not be passed to the + * entry. Instead, the argument will be assigned to a temporary with attributes that + * do match the parameter in the entry description, and the address of that temporary + * will be passed to the entry. This means that if the entry alters the value of this + * parameter, the alteration will not be visible in the calling routine. + * ```pli + * dcl e entry( fixed bin(31) ); + * dcl i fixed bin(15); + * call e( i ); + * ``` + * (see page 23) + */ + IBM1214I: { + "code": "IBM1214I", + "severity": "W", + "message": (argumentnumber: string, entryname: string) => `A dummy argument will be created for argument number ${argumentnumber} in ENTRY reference ${entryname} .`, + "fullCode": "IBM1214IW" + } as ParametricPLICode, + + /** + * It will be given the default attributes, but this may be because of an error in the + * declare. For instance, in the following example, parentheses may be missing + * ```pli + * dcl a, b fixed bin; + * ``` + * (see page 23) + */ + IBM1215I: { + "code": "IBM1215I", + "severity": "W", + "message": (variablename: string) => `The variable ${variablename} is declared without any data attributes.`, + "fullCode": "IBM1215IW" + } as ParametricPLICode, + + /** + * It will be given the default attributes, but this may be because of an error in the + * declare. For instance, in the following example, the level number on c and d should + * probably be 3. + * ```pli + * dcl a, b fixed bin; + * 1 a, + * 2 b, + * 2 c, + * 2 d; + * ``` + * (see page 23) + */ + IBM1216I: { + "code": "IBM1216I", + "severity": "W", + "message": "The structure member ${variable name } is declared without any data attributes. A level number may be incorrect.", + "fullCode": "IBM1216IW" + } as SimplePLICode, + + /** + * It will be given the default attributes, but this may be because of an error in the + * declare. For instance, in the following example, the level number on c and d should + * probably be 3. + * ```pli + * dcl a, b fixed bin; + * 1 a, + * 2 *, + * 2 c, + * 2 d; + * ``` + * (see page 23) + */ + IBM1217I: { + "code": "IBM1217I", + "severity": "W", + "message": "An unnamed structure member is declared without any data attributes. A level number may be incorrect.", + "fullCode": "IBM1217IW" + } as SimplePLICode, + + /** + * To eliminate this message, apply the CHAR or BIT built-in function to the first argument + * . + * ```pli + * dcl i fixed bin; + * display( substr(i,4) ); + * ``` + * (see page 23) + */ + IBM1218I: { + "code": "IBM1218I", + "severity": "W", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function should have string type.`, + "fullCode": "IBM1218IW" + } as ParametricPLICode, + + /** + * This message is not produced if the LEAVE statement specifies a label. In the following + * loop, the LEAVE statement will cause only the immediately enclosing DO-group to + * be exited; the loop will not be exited. + * ```pli + * do i = 1 to n; + * if a(i) > 0 then + * do; + * call f; + * leave; + * end; + * else; + * end; + * ``` + * (see page 23) + */ + IBM1219I: { + "code": "IBM1219I", + "severity": "W", + "message": "LEAVE will exit noniterative DO- group.", + "fullCode": "IBM1219IW" + } as SimplePLICode, + + /** + * This message is produced when a variable is compared to a constant equal to the largest + * or smallest value that the variable could assume. In the following loop, the variable + * x can never be greater than 99, and hence the implied comparison executed each time + * through the loop will always result in a '1'b. + * ```pli + * dcl x pic'99'; + * do x = 1 to 99; + * end; + * ``` + * (see page 23) + */ + IBM1220I: { + "code": "IBM1220I", + "severity": "W", + "message": "Result of comparison is always constant.", + "fullCode": "IBM1220IW" + } as SimplePLICode, + + /** + * This message is produced if a statement uses more bytes for temporaries than allowed + * by the MAXTEMP compiler option. + * (see page 24) + */ + IBM1221I: { + "code": "IBM1221I", + "severity": "W", + "message": (count: string) => `Statement uses ${count} bytes for temporaries.`, + "fullCode": "IBM1221IW" + } as ParametricPLICode, + + /** + * Comparisons involving data containing 2-digit year fields may cause problems if exactly + * one of the years is later than 1999. + * (see page 24) + */ + IBM1222I: { + "code": "IBM1222I", + "severity": "W", + "message": "Comparison involving 2-digit year is problematic.", + "fullCode": "IBM1222IW" + } as SimplePLICode, + + /** + * In a comparison, if one comparand has the DATE attribute, the other should also. + * If the non-date is a literal with a value that is valid for the date pattern, it + * will be viewed as if it had the same DATE attribute as the date comparand. So, in + * the following code, '670101' will be interpreted as if it had the DATE('YYMMDD') + * attribute. + * ```pli + * dcl x char(6) date('YYMMDD'); + * if x > '670101' then ... + * ``` + * (see page 24) + */ + IBM1223I: { + "code": "IBM1223I", + "severity": "W", + "message": "Literal in comparison interpreted with DATE attribute.", + "fullCode": "IBM1223IW" + } as SimplePLICode, + + /** + * In a comparison, if one comparand has the DATE attribute, the other should also. + * If the non-date is a literal with a value that is not valid for the date pattern, + * the DATE attribute will be ignored. So, in the following code, the comparison will + * be evaluated as if x did not have the DATE attribute. + * ```pli + * dcl x char(6) date('YYMMDD'); + * if x > '' then ... + * ``` + * (see page 24) + */ + IBM1224I: { + "code": "IBM1224I", + "severity": "W", + "message": "DATE attribute ignored in comparison with non-date literal.", + "fullCode": "IBM1224IW" + } as SimplePLICode, + + /** + * If the target in an explicit or implicit assignment has the DATE attribute, the source + * should also. If it does not, the DATE attribute will be ignored. So, in the following + * code, the assignment will be performed as if x did not have the DATE attribute. + * ```pli + * dcl x char(6) date('YYMMDD'); + * x = ''; + * ``` + * (see page 24) + */ + IBM1225I: { + "code": "IBM1225I", + "severity": "W", + "message": "DATE attribute ignored in conversion from literal.", + "fullCode": "IBM1225IW" + } as SimplePLICode, + + /** + * Look in STDOUT to see the message issued by the compiler backend. + * (see page 24) + */ + IBM2600I: { + "code": "IBM2600I", + "severity": "W", + "message": "Compiler backend issued warning messages to STDOUT.", + "fullCode": "IBM2600IW" + } as SimplePLICode, + + /** + * The indicated character is missing and has been inserted by the parser in order to + * correct your source. + * ```pli + * xx: dcl test fixed bin; + * ``` + * (see page 24) + */ + IBM2601I: { + "code": "IBM2601I", + "severity": "W", + "message": (character: string, character2: string) => `Missing ${character} assumed before ${character2} . DECLARE and other nonexecutable statements should not have labels.`, + "fullCode": "IBM2601IW" + } as ParametricPLICode, + + /** + * The array will be incompletely initialized. If the named variable is part of a structure, + * the first element in that structure with this problem will be flagged with message + * 1138. This may be a programming error (in 24 the example below, 6 should probably + * have been 7) and may cause exceptions when the program is run. + * ```pli + * dcl + * 1 a, + * 2 b(8) fixed bin init( 1, (7) 29 ), + * 2 c(8) fixed bin init( 1, (6) 29 ); + * ``` + * (see page 24) + */ + IBM2602I: { + "code": "IBM2602I", + "severity": "W", + "message": (count: string, variablename: string, arraysize: string) => `Number of items in INITIAL list is ${count} for the array ${variablename} which contains ${arraysize} elements.`, + "fullCode": "IBM2602IW" + } as ParametricPLICode, + + /** + * The array will be incompletely initialized. If the named variable is part of a structure, + * the first element in that structure with this problem will be flagged with message + * 1208. An asterisk can be used as an initialization factor to initialize all the + * elements with one value. In the example below, b(1) and c(1) are initialized with + * the value 13, while the elements b(2) through b(8) and c(2) through c(8) are uninitialized. + * In contrast, all the elements in d are initialized to 13. + * ```pli + * dcl + * 1 a, + * 2 b(8) fixed bin init( 13 ), + * 2 d(8) fixed bin init( 13 ), + * 2 e(8) fixed bin init( (*) 13 ); + * ``` + * (see page 25) + */ + IBM2603I: { + "code": "IBM2603I", + "severity": "W", + "message": "INITIAL list for the array ${variable name } contains only one item.", + "fullCode": "IBM2603IW" + } as SimplePLICode, + + /** + * If the source in a conversion to FIXED DECIMAL is a FIXED DECIMAL or PICTURE variable + * with a different precision and scale factor, and if the difference between the precisions + * is not as large as the the difference between the scale factors, then significant + * digits may be lost. If the SIZE condition were enabled, code would be generated + * to detect any such occurrence, and this message would not be issued. + * ```pli + * dcl a fixed dec(04) init(1009); + * dcl b fixed dec(03); + * b = a; + * ``` + * (see page 25) + */ + IBM2604I: { + "code": "IBM2604I", + "severity": "W", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string) => `FIXED DEC( ${sourceprecision} , ${sourcescale} ) will be converted to FIXED DEC( ${targetprecision} , ${targetscale} ). Significant digits may be lost.`, + "fullCode": "IBM2604IW" + } as ParametricPLICode, + + /** + * The specified line contains an invalid ANS print control character. The valid characters + * are: blank, 0, -, + and 1. + * (see page 25) + */ + IBM2605I: { + "code": "IBM2605I", + "severity": "W", + "message": "Invalid carriage control character. Blank assumed.", + "fullCode": "IBM2605IW" + } as SimplePLICode, + + /** + * If the REFER object has any other attributes, it will be converted to and from REAL + * FIXED BIN(31,0) via library calls. + * (see page 25) + */ + IBM2606I: { + "code": "IBM2606I", + "severity": "W", + "message": (referencename: string) => `Code generated for the REFER object ${referencename} would be more efficient if the REFER object had the attributes REAL FIXED BIN(p,0).`, + "fullCode": "IBM2606IW" + } as ParametricPLICode, + + /** + * If the source in a conversion to FIXED DECIMAL is a PICTURE variable with a different + * precision and scale factor, and if the difference between the precisions is not + * as large as the the difference between the scale factors, then significant digits + * may be lost. If the SIZE condition were enabled, code would be generated to detect + * any such occurrence, and this message would not be issued. + * ```pli + * dcl a pic'(4)9' init(1009); + * dcl b fixed dec(03); + * b = a; + * ``` + * (see page 25) + */ + IBM2607I: { + "code": "IBM2607I", + "severity": "W", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string) => `PICTURE representing FIXED DEC( ${sourceprecision} , ${sourcescale} ) will be converted to FIXED DEC( ${targetprecision} , ${targetscale} ). Significant digits may be lost.`, + "fullCode": "IBM2607IW" + } as ParametricPLICode, + + /** + * If the source in a conversion to a PICTURE is a PICTURE variable with a different + * precision and scale factor, and if the difference between the precisions is not + * as large as the the difference between the scale factors, then significant digits + * may be lost. If the SIZE condition were enabled, code would be generated to detect + * any such occurrence, and this message would not be issued. + * ```pli + * ``` 25 + * ```pli + * dcl a pic'(4)9' init(1009); + * dcl b pic'(3)9'; + * b = a; + * ``` + * (see page 25) + */ + IBM2608I: { + "code": "IBM2608I", + "severity": "W", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string) => `PICTURE representing FIXED DEC( ${sourceprecision} , ${sourcescale} ) will be converted to PICTURE representing FIXED DEC( ${targetprecision} , ${targetscale} ). Significant digits may be lost.`, + "fullCode": "IBM2608IW" + } as ParametricPLICode, + + /** + * If a comment contains a semicolon, it may indicate that there is an earlier unintentionally + * unclosed comment that is accidentally commenting out some source as in this exampl + * e + * ```pli + * \/* start of unclosed comment + * dcl b pic'(3)9'; + * \/* next comment *\/ + * ``` + * (see page 26) + */ + IBM2609I: { + "code": "IBM2609I", + "severity": "W", + "message": (linenumber: string, filenumber: string) => `Comment contains a semicolon on line ${linenumber} . ${filenumber} .`, + "fullCode": "IBM2609IW" + } as ParametricPLICode, + + /** + * This message applies to the MULTIPLY, DIVIDE, ADD, and SUBTRACT built-in functions: + * if one argument to one of these functions is FIXED DEC while the other is FIXED + * BIN, then the specified precision will not be interpreted as a FIXED DEC precision. + * This may cause improper truncation of data. For example, the result of the following + * multiply will have the attributes FIXED BIN(15), not FIXED DEC(15), and that might + * cause the result to be improperly truncated. + * ```pli + * dcl a fixed bin(31); + * dcl b fixed dec(15); + * b = multiply( a, 1000, 15 ); + * ``` + * (see page 26) + */ + IBM2610I: { + "code": "IBM2610I", + "severity": "W", + "message": (BUILTINname: string) => `One argument to ${BUILTINname} built-in function is FIXED DEC while the other is FIXED BIN. Compiler will not interpret precision as FIXED DEC.`, + "fullCode": "IBM2610IW" + } as ParametricPLICode, + + /** + * In a dominated SELECT statement, if a WHEN clause has the same value as an earlier + * WHEN clause, the code for the second WHEN clause will never be executed. This message + * will be produced only if the SELECT statement is otherwise suitable for transformation + * into a branch table. + * (see page 26) + */ + IBM2611I: { + "code": "IBM2611I", + "severity": "W", + "message": (binaryvalue: string) => `The binary value ${binaryvalue} appears in more than one WHEN clause.`, + "fullCode": "IBM2611IW" + } as ParametricPLICode, + + /** + * In a dominated SELECT statement, if a WHEN clause has the same value as an earlier + * WHEN clause, the code for the second WHEN clause will never be executed. This message + * will be produced only if the SELECT statement is otherwise suitable for transformation + * into a branch table. + * (see page 26) + */ + IBM2612I: { + "code": "IBM2612I", + "severity": "W", + "message": "The character string ${character string } appears in more than one WHEN clause.", + "fullCode": "IBM2612IW" + } as SimplePLICode, + + /** + * The indicated variable may not have been assigned or initialized a value before it + * is used as an INOUT parameter. This is problematic unless it is used only as an + * OUTONLY parameter. + * (see page 26) + */ + IBM2613I: { + "code": "IBM2613I", + "severity": "W", + "message": (variable: string) => `RULES(NOLAXINOUT) violation: ${variable} is being passed as an INOUT parameter, but may be unset.`, + "fullCode": "IBM2613IW" + } as ParametricPLICode, + + /** + * This message will flag statements such as the following, where the \"equals\" is + * meant to be an \"and\" or \"or\". + * ```pli + * if ( a < b ) = ( c < d ) then + * ``` + * (see page 26) + */ + IBM2614I: { + "code": "IBM2614I", + "severity": "W", + "message": "Both comparands are Booleans.", + "fullCode": "IBM2614IW" + } as SimplePLICode, + + /** + * DO-loops should normally be iterative, but if the DO- loop specification consists + * of just one assignment, then it will always excute once and only once. A semicolon + * after the DO may be missing, as in this example + * ```pli + * do + * edsaup.tprs = ads162.tprs; + * edsaup.tops = ads162.tops; + * end; + * ``` + * (see page 26) + */ + IBM2615I: { + "code": "IBM2615I", + "severity": "W", + "message": "DO-loop will always execute exactly once. A semicolon after the DO may be missing.", + "fullCode": "IBM2615IW" + } as SimplePLICode, + + /** + * If the SIZE or STG built-in function is applied to a CHAR(*) VARYING (or VARYINGZ) + * parameter when there is no descriptor available, then the size of the actual storage + * allocated to the variable cannot be determined and only the current size can be + * returned. + * (see page 26) + */ + IBM2616I: { + "code": "IBM2616I", + "severity": "W", + "message": (variable: string) => `Size of parameter ${variable} will return the currentsize value since no descriptor is available.`, + "fullCode": "IBM2616IW" + } as ParametricPLICode, + + /** + * It is generally very unwise to pass a label to another routine. It would be good + * to think about redesigning any code doing this. The compiler will issue this message + * when a LABEL is passed to an ENTRY declared with OPTIONS( COBOL ) or OPTIONS( ASM + * ) or OPTIONS( FORTRAN ). The only valid use of this label in the called routine + * would be to pass it on to another PL\/I routine. + * (see page 27) + */ + IBM2617I: { + "code": "IBM2617I", + "severity": "W", + "message": "Passing a LABEL to a non-PL/I routine is very poor coding practice and will cause the compiler to generate less than optimal code.", + "fullCode": "IBM2617IW" + } as SimplePLICode, + + /** + * A suboption of a suboption of a compiler option is incorrect. The suboption may be + * unknown or outside the allowable range. + * ```pli + * *process limits(extname(2000)); + * ``` + * (see page 27) + */ + IBM2618I: { + "code": "IBM2618I", + "severity": "W", + "message": (suboption: string, option: string, option2: string) => `The suboption ${suboption} is not valid for the suboption ${option} of the ${option2} compiler option.`, + "fullCode": "IBM2618IW" + } as ParametricPLICode, + + /** + * Changing REFER objects may not produce the expected results. For example, in the + * following example, the assignment will not change any of the elements in the array + * d. + * ```pli + * dcl + * 1 a based(p), + * 2 b fixed bin(31), + * 2 c fixed bin(31), + * 2 d( 10 refer(c) ), + * 3 e fixed bin(31), + * 3 f fixed bin(31); + * a = ''; + * ``` + * (see page 27) + */ + IBM2620I: { + "code": "IBM2620I", + "severity": "W", + "message": "Target structure contains REFER objects. Results are undefined if the assignment changes any REFER object.", + "fullCode": "IBM2620IW" + } as SimplePLICode, + + /** + * The first statement in an ON ERROR block should usually be an ON ERROR SYSTEM statement. + * This will tend to prevent an infinite loop if there is an error in the rest of the + * code in the ON ERROR block. + * (see page 27) + */ + IBM2621I: { + "code": "IBM2621I", + "severity": "W", + "message": "ON ERROR block does not start with ON ERROR SYSTEM. An error inside the block may lead to an infinite loop.", + "fullCode": "IBM2621IW" + } as SimplePLICode, + + /** + * If the initial value in a DO loop is set via an ENTRY, then you may get unexpected + * results if that ENTRY also changes the TO or BY value. For example, in the first + * loop below, the function \"first\" should not change the value of the variable \"last\". + * It would be better to change this code into the form of the second loop below. + * ```pli + * do x = first() to last; + * end; + * temp = first(); + * do x = temp to last; + * end; + * ``` + * (see page 27) + */ + IBM2622I: { + "code": "IBM2622I", + "severity": "W", + "message": "ENTRY used to set the initial value in a DO loop will be invoked after any TO or BY values are set.", + "fullCode": "IBM2622IW" + } as SimplePLICode, + + /** + * Under DFP, the conversion of FLOAT DEC to FLOAT BIN requires an expensive library + * call that will lead to poor performance. To avoid this, the DECIMAL built-in function + * can be applied to the FIXED BIN operand. For example, it would be better to change + * the first assignment statement into the form of the second below. + * ```pli + * dcl n fixed bin(31); + * dcl f float dec(16); + * f = n + f; + * f = dec(n) + f; + * ``` + * (see page 27) + */ + IBM2623I: { + "code": "IBM2623I", + "severity": "W", + "message": "Mixing FIXED BIN and FLOAT DEC produces a FLOAT BIN result. Under DFP, this will lead to poor performance.", + "fullCode": "IBM2623IW" + } as SimplePLICode, + + /** + * Under DFP, the conversion of FLOAT DEC to FLOAT BIN requires an expensive library + * call that will lead to poor performance. To avoid this, the DECIMAL built-in function + * can be applied to the BIT operand. For example, it would be better to change the + * first assignment statement into the form of the second below. + * ```pli + * dcl b bit(8); + * dcl f float dec(16); + * f = b + f; + * f = dec(b) + f; + * ``` + * (see page 27) + */ + IBM2624I: { + "code": "IBM2624I", + "severity": "W", + "message": "Mixing BIT and FLOAT DEC produces a FLOAT BIN result. 27 Under DFP, this will lead to poor performance.", + "fullCode": "IBM2624IW" + } as SimplePLICode, + + /** + * Under DFP, the conversion of FLOAT DEC to FLOAT BIN requires an expensive library + * call that will lead to poor performance. + * (see page 28) + */ + IBM2625I: { + "code": "IBM2625I", + "severity": "W", + "message": "Mixing FLOAT BIN and FLOAT DEC produces a FLOAT BIN result. Under DFP, this will lead to poor performance.", + "fullCode": "IBM2625IW" + } as SimplePLICode, + + /** + * While technically valid, a SUBSTR reference with a third argument that is a constant + * of zero probably represents a coding error. + * (see page 28) + */ + IBM2626I: { + "code": "IBM2626I", + "severity": "W", + "message": "Use of SUBSTR with a third argument equal to 0 is somewhat pointless since the result will always be a null string.", + "fullCode": "IBM2626IW" + } as SimplePLICode, + + /** + * XMI metadata is generated for BASED structures using REFER only if their use of REFER + * is \"simple\". + * (see page 28) + */ + IBM2627I: { + "code": "IBM2627I", + "severity": "W", + "message": (identifier: string) => `No metadata will be generated for the structure ${identifier} since its use of REFER is too complex.`, + "fullCode": "IBM2627IW" + } as ParametricPLICode, + + /** + * BYVALUE parameters larger than 32 bytes require too much overhead and are bad for + * performance. + * (see page 28) + */ + IBM2628I: { + "code": "IBM2628I", + "severity": "W", + "message": "BYVALUE parameters should ideally be no larger than 32 bytes.", + "fullCode": "IBM2628IW" + } as SimplePLICode, + + /** + * No debug symbol information will be generated for the named variable, and hence it + * cannot be referenced when using the debugger. + * (see page 28) + */ + IBM2629I: { + "code": "IBM2629I", + "severity": "W", + "message": (identifier: string) => `No debug symbol information will be generated for ${identifier} .`, + "fullCode": "IBM2629IW" + } as ParametricPLICode, + + /** + * If the scale factor for the result of an operation exceeds the precision of the result, + * then unexpected fixedoverflow exceptions may occur. This can happen, for example, + * when multiplying two FIXED DEC(15,8) variables under the LIMITS(FIXEDDEC(15)) option + * because the result of such a multiplication would have the attributes FIXED DEC(15,16). + * To eliminate this message, the PRECISION built-in function could be used to reduce + * the scale factor of one of the operands or the MULTIPLY built-in function could + * be used to override the default attributes for the result. + * (see page 28) + */ + IBM2630I: { + "code": "IBM2630I", + "severity": "W", + "message": (operandattributes: string, operandattributes2: string, resultattributes: string) => `The operands in an arithmetic operation have the attributes ${operandattributes} and ${operandattributes2} which will produce a result with the attributes ${resultattributes} . This means that its scale factor is greater than its precision! That may lead to an overflow and unexpected results.`, + "fullCode": "IBM2630IW" + } as ParametricPLICode, + + /** + * This message applies to the MULTIPLY, DIVIDE, ADD, and SUBTRACT built-in functions: + * if one argument to one of these functions is FIXED DEC while the other is FLOAT + * BIN, then the specified precision will not be interpreted as a FIXED DEC precision. + * This may cause improper truncation of data. For example, the result of the following + * multiply will have the attributes FLOAT BIN(15), not FIXED DEC(15), and that might + * cause the result to be improperly truncated. + * ```pli + * dcl a float bin(31); + * dcl b fixed dec(15); + * b = multiply( a, 1000, 15 ); + * ``` 28 + * (see page 28) + */ + IBM2631I: { + "code": "IBM2631I", + "severity": "W", + "message": (BUILTINname: string) => `One argument to ${BUILTINname} built-in function is FIXED DEC while the other is FLOAT BIN. Compiler will not interpret precision as FIXED DEC.`, + "fullCode": "IBM2631IW" + } as ParametricPLICode, + + /** + * This message applies to the MULTIPLY, DIVIDE, ADD, and SUBTRACT built-in functions: + * if one argument to one of these functions is FIXED DEC while the other is FLOAT + * DEC, then the specified precision will not be interpreted as a FIXED DEC precision. + * This may cause improper truncation of data. For example, the result of the following + * multiply will have the attributes FLOAT DEC(15), not FIXED DEC(15), and that might + * cause the result to be improperly truncated. + * ```pli + * dcl a float dec(15); + * dcl b fixed dec(15); + * b = multiply( a, 1000, 15 ); + * ``` + * (see page 29) + */ + IBM2632I: { + "code": "IBM2632I", + "severity": "W", + "message": (BUILTINname: string) => `One argument to ${BUILTINname} built-in function is FIXED DEC while the other is FLOAT DEC. Compiler will not interpret precision as FIXED DEC.`, + "fullCode": "IBM2632IW" + } as ParametricPLICode, + + /** + * Code using such variables will work only as long as the size of the POINTER or OFFSET + * variable remains the same as the size of the FIXED BIN variable. + * (see page 29) + */ + IBM2633I: { + "code": "IBM2633I", + "severity": "W", + "message": "Given the support for addressing arithmetic, basing a POINTER or OFFSET on a FIXED BIN is unnecessary, and it will also fail to work properly if the size of a POINTER changes.", + "fullCode": "IBM2633IW" + } as SimplePLICode, + + /** + * Code using such variables will work only as long as the size of the POINTER or OFFSET + * variable remains the same as the size of the FIXED BIN variable. + * (see page 29) + */ + IBM2634I: { + "code": "IBM2634I", + "severity": "W", + "message": "Given the support for addressing arithmetic, basing a FIXED BIN on a POINTER or OFFSET is unnecessary, and it will also fail to work properly if the size of a POINTER changes.", + "fullCode": "IBM2634IW" + } as SimplePLICode, + + /** + * If the scale factor for the result of an operation is negative, then the ones digits + * will be lost and that may cause problems. This can happen, for example, when dividing + * a FIXED DEC(11,2) variable by a FIXED DEC(31,29) variable because the result of + * such a division would have the attributes FIXED DEC(31,-7). To eliminate this message, + * the PRECISION built-in function could be used to reduce the scale factor of one + * of the operands or the DIVIDE built-in function could be used to override the default + * attributes for the result. + * (see page 29) + */ + IBM2635I: { + "code": "IBM2635I", + "severity": "W", + "message": (operandattributes: string, operandattributes2: string, resultattributes: string) => `The operands in an arithmetic operation have the attributes ${operandattributes} and ${operandattributes2} which will produce a result with the attributes ${resultattributes} . This means that its scale factor is negative! That may lead to the loss of significant digits and unexpected results.`, + "fullCode": "IBM2635IW" + } as ParametricPLICode, + + /** + * In a dominated SELECT statement, if a WHEN clause has the same value as an earlier + * WHEN clause, the code for the second WHEN clause will never be executed. This message + * will be produced only if the SELECT statement is otherwise suitable for transformation + * into a branch table. + * (see page 29) + */ + IBM2636I: { + "code": "IBM2636I", + "severity": "W", + "message": (ordinalname: string) => `The ordinal ${ordinalname} appears in more than one WHEN clause.`, + "fullCode": "IBM2636IW" + } as ParametricPLICode, + + /** + * If an ENTRY is used as a function, it should be declared with the RETURNS attribute. + * The compiler will apply the RETURNS attribute to both of the ENTRYs in this example, + * but for E, the compiler will assume it will return FLOAT DEC while for M, it will + * assume it will return FIXED BIN. + * ```pli + * dcl e entry; + * dcl m entry; + * a = e(); + * a = m(); + * ``` + * (see page 29) + */ + IBM2637I: { + "code": "IBM2637I", + "severity": "W", + "message": "An ENTRY invoked as a function should have the RETURNS attribute.", + "fullCode": "IBM2637IW" + } as SimplePLICode, + + /** + * This message is produced if a statement uses more intermediate language instructions. + * than allowed by the MAXGEN compiler option. It may point to statements that are + * excessively complex. + * (see page 29) + */ + IBM2638I: { + "code": "IBM2638I", + "severity": "W", + "message": (count: string) => `Statement used ${count} intermediate language instructions.`, + "fullCode": "IBM2638IW" + } as ParametricPLICode, + + /** + * This message is produced if a statement uses more intermediate language instructions. + * than allowed by the MAXGEN compiler option. It may point to statements that are + * excessively complex. This message, rather than message IBM2638, is produced under + * the same situations as message IBM2638 except the STMT number option must also be + * in effect. + * (see page 30) + */ + IBM2639I: { + "code": "IBM2639I", + "severity": "W", + "message": (count: string) => `Previous statement used ${count} intermediate language instructions.`, + "fullCode": "IBM2639IW" + } as ParametricPLICode, + + /** + * Changing REFER objects might cause subsequent code to fail. For example, in the following + * code, the first assignment causes the second assignment to overwrite storage. + * ```pli + * dcl + * 1 a based(p), + * 2 b fixed bin(31), + * 2 c fixed bin(31), + * 2 d( 10 refer(c) ), + * 3 e fixed bin(31), + * 3 f fixed bin(31); + * allocate a; + * a.c = 15; + * a.f = 0;; + * ``` + * (see page 30) + */ + IBM2640I: { + "code": "IBM2640I", + "severity": "W", + "message": "Target is a REFER object. Results are undefined if an assignment changes a REFER object.", + "fullCode": "IBM2640IW" + } as SimplePLICode, + + /** + * A suboption of a compiler option has been incorrectly specified. It must be followed + * by a left parenthesis and then a (possibly empty) list of items and a closing right + * parenthesis. + * ```pli + * *process deprecate(builtin); + * ``` + * (see page 30) + */ + IBM2641I: { + "code": "IBM2641I", + "severity": "W", + "message": (option: string, option2: string) => `The suboption ${option} of the ${option2} compiler option must be followed by a (possibly empty) parenthesized list.`, + "fullCode": "IBM2641IW" + } as ParametricPLICode, + + /** + * Specifying OPTIONS(REENTRANT) on a PROCEDURE or BEGIN block has no effect on the + * generated code. Your code will be reentrant only if it does not alter any STATIC + * variables. You can use the DEFAULT(NONASGN) compiler option to force the compiler + * to flag assignments to STATIC variables. + * (see page 30) + */ + IBM2642I: { + "code": "IBM2642I", + "severity": "W", + "message": "OPTIONS(REENTRANT) is ignored.", + "fullCode": "IBM2642IW" + } as SimplePLICode, + + /** + * The named built-in function was specified in the BUILTIN suboption of the DEPRECATENEXT + * option, and so any explicit or contextual declaration of it is flagged. + * (see page 30) + */ + IBM2643I: { + "code": "IBM2643I", + "severity": "W", + "message": (builtin: string) => `The built-in function ${builtin} will be deprecated.`, + "fullCode": "IBM2643IW" + } as ParametricPLICode, + + /** + * The named INCLUDE file was specified in the INCLUDE suboption of the DEPRECATENEXT + * option, and so any attempt to include it is flagged. + * (see page 30) + */ + IBM2644I: { + "code": "IBM2644I", + "severity": "W", + "message": (filename: string) => `The INCLUDE file ${filename} will be deprecated.`, + "fullCode": "IBM2644IW" + } as ParametricPLICode, + + /** + * The named ENTRY was specified in the ENTRY suboption of the DEPRECATENEXT option, + * and so any explicit or contextual declaration of it is flagged. + * (see page 30) + */ + IBM2645I: { + "code": "IBM2645I", + "severity": "W", + "message": (entryname: string) => `The ENTRY named ${entryname} will be deprecated.`, + "fullCode": "IBM2645IW" + } as ParametricPLICode, + + /** + * The named VARIABLE was specified in the VARIABLE suboption of the DEPRECATENEXT option, + * and so any explicit or contextual declaration of it is flagged. + * (see page 30) + */ + IBM2646I: { + "code": "IBM2646I", + "severity": "W", + "message": (variable: string) => `The VARIABLE named ${variable} will be deprecated.`, + "fullCode": "IBM2646IW" + } as ParametricPLICode, + + /** + * The named statement was specified in the STMT suboption of the DEPRECATENEXT option, + * and so any use of that statement is flagged. + * (see page 30) + */ + IBM2647I: { + "code": "IBM2647I", + "severity": "W", + "message": (statementname: string) => `The ${statementname} statement will be deprecated.`, + "fullCode": "IBM2647IW" + } as ParametricPLICode, + + /** + * Change the declaration to STATIC, or remove the INITIAL items and copy the INITIAL + * items from a STATIC variable. + * (see page 30) + */ + IBM2648I: { + "code": "IBM2648I", + "severity": "W", + "message": (count: string) => `Declaration contains ${count} INITIAL items.`, + "fullCode": "IBM2648IW" + } as ParametricPLICode, + + /** + * In INLIST( x, y1, y2, ... ), no y value should appear twice. This message will be + * produced only if the INLIST function is otherwise suitable for transformation into + * a branch table. + * (see page 30) + */ + IBM2649I: { + "code": "IBM2649I", + "severity": "W", + "message": (binaryvalue: string) => `The binary value ${binaryvalue} appears more than once in the INLIST argument set.`, + "fullCode": "IBM2649IW" + } as ParametricPLICode, + + /** + * In INLIST( x, y1, y2, ... ), no y value should appear twice. This message will be + * produced only if the INLIST function is otherwise suitable for transformation into + * a branch table. + * (see page 31) + */ + IBM2650I: { + "code": "IBM2650I", + "severity": "W", + "message": (ordinalname: string) => `The ordinal ${ordinalname} appears more than once in the INLIST argument set.`, + "fullCode": "IBM2650IW" + } as ParametricPLICode, + + /** + * This message is produced if a block contains more branches than allowed by the MAXBRANCH + * compiler option. It may point to blocks that are excessively complex. + * (see page 31) + */ + IBM2651I: { + "code": "IBM2651I", + "severity": "W", + "message": (blockname: string, count: string) => `Block ${blockname} contains ${count} branches.`, + "fullCode": "IBM2651IW" + } as ParametricPLICode, + + /** + * In the statement REINIT x, x should contain some element with an INITIAL attribute. + * If not, no code will be generated for the statement. + * (see page 31) + */ + IBM2652I: { + "code": "IBM2652I", + "severity": "W", + "message": "REINIT reference contains no element with an INITIAL attribute.", + "fullCode": "IBM2652IW" + } as SimplePLICode, + + /** + * For example, rather than specifying PP(SQL(VERSION(AUTO))), specify PP(SQL('VERSION(AUTO)')) + * . + * (see page 31) + */ + IBM2653I: { + "code": "IBM2653I", + "severity": "W", + "message": "The list of preprocessor options must be enclosed in quotation marks.", + "fullCode": "IBM2653IW" + } as SimplePLICode, + + /** + * The INITIAL attribute for BASED has an effect only if the BASED variable is used + * in an ALLOCATE statement. But for code such as the following, it has no effect on + * either the variable A or B. + * ```pli + * dcl a fixed bin(31); + * dcl b bit(32) based(addr(a)) init(''b); + * ``` + * (see page 31) + */ + IBM2654I: { + "code": "IBM2654I", + "severity": "W", + "message": "INITIAL attribute for BASED on ADDR has no effect on the base variable.", + "fullCode": "IBM2654IW" + } as SimplePLICode, + + /** + * If the 2 strings in the IBMZIOP module are equal, then different values for the options + * specified there are not allowed in the +DD options files, the invocation parameter, + * the options environment variable or the PROCESS statements. The conflicting options + * will be ignored. + * (see page 31) + */ + IBM2655I: { + "code": "IBM2655I", + "severity": "W", + "message": "Some options conflict with the non-overridable options.", + "fullCode": "IBM2655IW" + } as SimplePLICode, + + /** + * In the following example, DEFBUF does not overlay the first 10 bytes of BUFFER. Instead, + * each array element of DEFBUF overlays the first byte of the first byte of the corresponding + * array element of BUFFER. + * ```pli + * DCL BUFFER(10) CHAR (300); + * DCL DEFBUF(10) CHAR(1) DEF BUFFER; + * ``` + * (see page 31) + */ + IBM2656I: { + "code": "IBM2656I", + "severity": "W", + "message": "Simple defining applies to ${variable name } . If string-overlay defining is intended, then add POS(1) to its declaration.", + "fullCode": "IBM2656IW" + } as SimplePLICode, + + /** + * This is probably a coding error. + * (see page 31) + */ + IBM2657I: { + "code": "IBM2657I", + "severity": "W", + "message": "Both logical AND operands are identical.", + "fullCode": "IBM2657IW" + } as SimplePLICode, + + /** + * This is probably a coding error. + * (see page 31) + */ + IBM2658I: { + "code": "IBM2658I", + "severity": "W", + "message": "Both logical OR operands are identical.", + "fullCode": "IBM2658IW" + } as SimplePLICode, + + /** + * If an AUTOMATIC or STATIC structure consists entirely of scalar fields all of which + * have the INITIAL attribute and none of which have their address taken, then the + * compiler could probably generate much better code if all the INITIAL keywords were + * change to VALUE keywords. If the STATIC or AUTOMATIC attribute is 31 explicitly + * specified, it would also have to be removed from the declare. + * (see page 31) + */ + IBM2659I: { + "code": "IBM2659I", + "severity": "W", + "message": (variablename: string) => `Generated code would be better if all the INITIAL attributes in the declare for ${variablename} were changed to VALUE.`, + "fullCode": "IBM2659IW" + } as ParametricPLICode, + + /** + * This message warns that the compiler has detected code that could lead to an error + * under some conditions. + * ```pli + * oops: proc( x ) returns( fixed bin(31 ); + * dcl x fixed bin(31); + * select; + * when( x > 0 ) return( 1 ); + * when( x = 0 ) return( 0 ); + * otherwise; + * end; + * end; + * ``` The compiler will issue this message for E15 sort exits unless the E15 sort exit + * specifies the OPTIONAL attribute as part of the RETURNS option on its PROCEDURE + * statement. + * (see page 32) + */ + IBM2660I: { + "code": "IBM2660I", + "severity": "W", + "message": (procedurename: string, procedurename2: string) => `Program logic may lead to the END statement for ${procedurename} even though ${procedurename2} is a function that should return a value.`, + "fullCode": "IBM2660IW" + } as ParametricPLICode, + + /** + * In INLIST( x, y1, y2, ... ), no y value should appear twice. This message will be + * produced only if the INLIST function is otherwise suitable for transformation into + * a branch table. + * (see page 32) + */ + IBM2661I: { + "code": "IBM2661I", + "severity": "W", + "message": (stringvalue: string) => `The string ${stringvalue} appears more than once in the INLIST argument set.`, + "fullCode": "IBM2661IW" + } as ParametricPLICode, + + /** + * In INLIST( x, y1, y2, ... ), no y value should appear twice. This message will be + * produced only if the INLIST function is otherwise suitable for transformation into + * a branch table. + * (see page 32) + */ + IBM2662I: { + "code": "IBM2662I", + "severity": "W", + "message": "INLIST argument set contains duplicate values.", + "fullCode": "IBM2662IW" + } as SimplePLICode, + + /** + * In a SELECT statement, if a WHEN clause has the same expression as the previousr + * expression in the WHEN clauses in that SELECT statement, then the code is probably + * in error. The compiler will not report all such errors, but only those where an + * expression is duplicated in one of the four previous expressions. + * (see page 32) + */ + IBM2663I: { + "code": "IBM2663I", + "severity": "W", + "message": "WHEN clause contains an expression that matches the previous expression in the containing SELECT statement.", + "fullCode": "IBM2663IW" + } as SimplePLICode, + + /** + * In a SELECT statement, if a WHEN clause has the same expression as one of the earlier + * expressions in the WHEN clauses in that SELECT statement, then the code is probably + * in error. The compiler will not report all such errors, but only those where an + * expression is duplicated in one of the four previous expressions. + * (see page 32) + */ + IBM2664I: { + "code": "IBM2664I", + "severity": "W", + "message": (count: string) => `WHEN clause contains an expression that matches the expression ${count} previous in the containing SELECT statement.`, + "fullCode": "IBM2664IW" + } as ParametricPLICode, + + /** + * If an EXTERNAL variable is intended to define LE runtime options, then it must be + * a scalar CHAR VARYING string with an INITIAL value. + * (see page 32) + */ + IBM2665I: { + "code": "IBM2665I", + "severity": "W", + "message": "EXTERNAL PLIXOPT declare specifies run-time options only if the variable has the attribute CHARACTER VARYING INITIAL and is not an array.", + "fullCode": "IBM2665IW" + } as SimplePLICode, + + /** + * Returning the address of a variable in AUTOMATIC storage is likely to produce code + * that cannot work successfully. + * (see page 32) + */ + IBM2666I: { + "code": "IBM2666I", + "severity": "W", + "message": "RETURN expression holds the address of a variable in AUTOMATIC storage.", + "fullCode": "IBM2666IW" + } as SimplePLICode, + + /** + * The extents in one declare should not depend on the size of a later declare. The + * compiler will swap the two declares, but this might introduce other problems. It + * might be better to move the first declare after the second. + * (see page 32) + */ + IBM2667I: { + "code": "IBM2667I", + "severity": "W", + "message": (first: string, second: string) => `The string lengths in the declare for ${first} depend on the size of ${second} whose declare comes later in the block. Consider moving the first declare after the second.`, + "fullCode": "IBM2667IW" + } as ParametricPLICode, + + /** + * This message is produced if a typed structure with some VALUE attributes needs more + * bytes than allowed by the MAXINIT compiler option. Use of the VALUE type function + * will add a full copy of the structure to the generated object's constant area and + * may lead to binder problems. + * (see page 32) + */ + IBM2668I: { + "code": "IBM2668I", + "severity": "W", + "message": (type: string, count: string) => `Using the VALUE function with the structure type ${type} adds ${count} bytes to the generated object.`, + "fullCode": "IBM2668IW" + } as ParametricPLICode, + + /** + * Attributes such as ALIGNED and UNALIGNED may be specified in a DEFINE ALIAS statement, + * but they will be ignored and should be removed. + * (see page 33) + */ + IBM2669I: { + "code": "IBM2669I", + "severity": "W", + "message": (attributekeyword: string) => `The ${attributekeyword} attribute is ignored in an ALIAS definition.`, + "fullCode": "IBM2669IW" + } as ParametricPLICode, + + /** + * The parameter to MAIN has a maximum length that depends on the system and should + * not be declared with a fixed maximum length. + * (see page 33) + */ + IBM2670I: { + "code": "IBM2670I", + "severity": "W", + "message": "The parameter to MAIN should be declared as CHAR(*) VARYING.", + "fullCode": "IBM2670IW" + } as SimplePLICode, + + /** + * Code like this could lead to a protection exception. In the following example, snce + * the variable X is NONASSIGNABLE, the compiler could have passed the address of a + * constant fullword 17 to the routine TEST. If so, if E changed its parameter (as + * the attribute OUTONLY says it could), then a protection exception would result. + * ```pli + * call oops( 17 ); + * test: proc( x ); + * dcl x fixed bin(31) NONASSIGNABLE; + * dcl e ext entry( ASSIGNABLE fixed + * bin(31) ); + * call e(x); + * end; + * ``` + * (see page 33) + */ + IBM2671I: { + "code": "IBM2671I", + "severity": "W", + "message": (X: string, n: string, E: string, A: string, D: string) => `The variable ${X} is passed as argument number ${n} to entry ${E} . The corresponding parameter has the ${A} attribute, and hence the variable could be modified despite having the ${D} attribute.`, + "fullCode": "IBM2671IW" + } as ParametricPLICode, + + /** + * Named constants should be declared with the VALUE attribute rather than the attributes + * STATIC INIT. This will cause the compiler to generate much better code. For example, + * in the following code, if ASIZE and CLEN are constant, ten it would be much better + * to change their declares. + * ```pli + * dcl asize fixed bin(31) static init(100); + * dcl clen fixed bin(31) static init(20); + * dcl a(asize) char(clen); + * ``` + * (see page 33) + */ + IBM2672I: { + "code": "IBM2672I", + "severity": "W", + "message": (extentvariable: string) => `If ${extentvariable} is constant, then removing its STATIC attribute and changing its INITIAL attribute to the VALUE attribute would improve the performance of the generated code.`, + "fullCode": "IBM2672IW" + } as ParametricPLICode, + + /** + * This message will flag statements such as the following. In the first IF statement, + * it would be better if \"true\" were a named constant, i.e. if it were declared with + * the VALUE attribute rather than STATIC INIT In the second IF statement, the true\/false + * value of (a < b ) is compared to c, and this will be true for any value of c that + * is bigger than 1. The IF clause is probably meant to be (a < b ) & (b < c). + * ```pli + * dcl true bit(1) static init('1'b); + * if ( a < b ) = true then + * if a < b < c then + * ``` + * (see page 33) + */ + IBM2673I: { + "code": "IBM2673I", + "severity": "W", + "message": "Boolean is compared with something other than a BIT(1) restricted expression.", + "fullCode": "IBM2673IW" + } as SimplePLICode, + + /** + * Defined structures must occupy a number of bytes that is a multiple of the structure + * s alignment. So, for example, if a structure contains an aligned fixed bin(31) (or + * other aligned fullword) field as its most stringently aligned item, then the structure + * must occupy a multiple of 4 bytes. The following structure does not meet this requirement + * : + * ```pli + * define structure + * 1 point, + * 2 x fixed bin(31), + * ``` 33 + * ```pli + * 2 y char(1); + * ``` + * (see page 33) + */ + IBM2674I: { + "code": "IBM2674I", + "severity": "W", + "message": (structname: string, alignment: string, storagesize: string) => `The defined structure ${structname} is ${alignment} byte aligned, but occupies only ${storagesize} bytes of storage. This may lead to addressing problems and data corruption.`, + "fullCode": "IBM2674IW" + } as ParametricPLICode, + + /** + * If the control variable in a DO loop is a PICTURE variable, then more code will be + * generated for the loop than if the control variable were a FIXED BIN variable. Moreover, + * such loops may easily be miscoded so that they will loop infinitely. + * (see page 34) + */ + IBM2675I: { + "code": "IBM2675I", + "severity": "W", + "message": "Use of PICTURE as DO control variable is not recommended.", + "fullCode": "IBM2675IW" + } as SimplePLICode, + + /** + * The control variable in the DO loop has one of the types: scaled fixed binary, nonnative + * fixed binary, fixed decimal, or picture. Consequently, the code generated for the + * loop will not be optimal. + * (see page 34) + */ + IBM2676I: { + "code": "IBM2676I", + "severity": "W", + "message": "Code generated for DO group would be more efficient if control variable had type FIXED BIN with zero scale factor.", + "fullCode": "IBM2676IW" + } as SimplePLICode, + + /** + * The named variable is an array that is initialized but appears never to be changed. + * If it is constant, the compiler would not generate code to initialize it every time + * the block where it is declared is entered. This change could potentially signiifcantly + * improve performance. + * (see page 34) + */ + IBM2677I: { + "code": "IBM2677I", + "severity": "W", + "message": (variablename: string) => `Generated code would be better if the declare for ${variablename} were changed from AUTOMATIC to STATIC NONASSIGNABLE.`, + "fullCode": "IBM2677IW" + } as ParametricPLICode, + + /** + * The DO statement has the form DO x = A to B; where A > B. or the form DO x = A to + * B BY -1; where A < B. This will cause the loop body to be skipped. One or more of + * the values A and B may be incorrect. + * ```pli + * do jx = 11 to 10; + * . . . + * end; + * ``` + * (see page 34) + */ + IBM2678I: { + "code": "IBM2678I", + "severity": "W", + "message": "Loop will never be run. TO value may be incorrect.", + "fullCode": "IBM2678IW" + } as SimplePLICode, + + /** + * The GONUMBER can be placed in the SEPRATE sidefile only if the TEST options specifies + * that the sidefile should be created. + * (see page 34) + */ + IBM2679I: { + "code": "IBM2679I", + "severity": "W", + "message": "GONUMBER(SEPARATE) changed to GONUMBER(NOSEPARATE) since the SEPARATE suboption for the GONUMBER option should be specified only when the TEST option and its SEPARATE suboption are also specified.", + "fullCode": "IBM2679IW" + } as SimplePLICode, + + /** + * The control variable in the DO loop should have storage class STATIC or AUTOMATIC + * and not PARAMETER and especially not BASED, DEFINED, or CONTROLLED, + * (see page 34) + */ + IBM2680I: { + "code": "IBM2680I", + "severity": "W", + "message": "Code generated for DO group would perform better if control variable was STATIC or AUTOMATIC.", + "fullCode": "IBM2680IW" + } as SimplePLICode, + + /** + * In REPATTERN( d, p, q ), if LENGTH( d ) is larger than LENGTH( q ), the code is valid + * only if d starts with as many blanks as the difference in those lengths. + * (see page 34) + */ + IBM2681I: { + "code": "IBM2681I", + "severity": "W", + "message": (sourcelength: string, sourcepattern: string) => `Source has length ${sourcelength} which is greater than the length of the source pattern ${sourcepattern} . Unless the source has enough leading blanks, invoking this REPATTERN will cause the ERROR condition to be raised. The required checking will also cause this REPATTERN not to be inlined.`, + "fullCode": "IBM2681IW" + } as ParametricPLICode, + + /** + * This message is produced if a STATIC variable requires more space than allowed by + * the MAXINIT compiler option. 34 2400-2599) + * (see page 34) + */ + IBM2682I: { + "code": "IBM2682I", + "severity": "W", + "message": (name: string, count: string) => `The variable ${name} needs ${count} storage bytes which exceeds the MAXSTATIC limit.`, + "fullCode": "IBM2682IW" + } as ParametricPLICode +}; + +export const Error = { + + /** + * The maximum size allowed for an AREA variable is 16777216. + * (see page 35) + */ + IBM1226I: { + "code": "IBM1226I", + "severity": "E", + "message": (maximumvalue: string) => `Area extent is reduced to ${maximumvalue} .`, + "fullCode": "IBM1226IE" + } as ParametricPLICode, + + /** + * In certain contexts, for example after an IF-THEN clause, only executable statements + * are permitted. A DECLARE, DEFINE, DEFAULT or FORMAT statement has been found in + * one of these contexts. A null statement, (a statement consisting of only a semicolon) + * will be inserted before the offending statement. + * (see page 35) + */ + IBM1227I: { + "code": "IBM1227I", + "severity": "E", + "message": (keyword: string, keyword2: string) => `${keyword} statement is not allowed where an executable statement is required. A null statement will be inserted before the ${keyword2} statement.`, + "fullCode": "IBM1227IE" + } as ParametricPLICode, + + /** + * In certain contexts, for example after an IF-THEN clause, only executable statements + * are permitted. A DEFAULT statement has been found in one of these contexts. A null + * statement (a statement consisting of only a semicolon) will be inserted in place + * of the DEFAULT statement. + * (see page 35) + */ + IBM1228I: { + "code": "IBM1228I", + "severity": "E", + "message": "DEFAULT statement is not allowed where an executable statement is required. The DEFAULT statement will be enrolled in the current block, and a null statement will be inserted in its place.", + "fullCode": "IBM1228IE" + } as SimplePLICode, + + /** + * In certain contexts, for example after an IF-THEN clause, only executable statements + * are permitted. A FORMAT statement has been found in one of these contexts. A null + * statement (a statement consisting of only a semicolon) will be inserted in place + * of the FORMAT statement. + * (see page 35) + */ + IBM1229I: { + "code": "IBM1229I", + "severity": "E", + "message": "FORMAT statement is not allowed where an executable statement is required. The FORMAT statement will be enrolled in the current block, and a null statement will be inserted in its place.", + "fullCode": "IBM1229IE" + } as SimplePLICode, + + /** + * Argument lists are valid only for ENTRY references. + * ```pli + * dcl a(15) entry returns( fixed bin(31) ); + * i = a(3)(4); + * ``` + * (see page 35) + */ + IBM1230I: { + "code": "IBM1230I", + "severity": "E", + "message": (variablename: string) => `Arguments have been specified for the variable ${variablename} , but it is not an entry variable.`, + "fullCode": "IBM1230IE" + } as ParametricPLICode, + + /** + * Argument\/subscript lists are valid only for ENTRY and array references. + * ```pli + * dcl a fixed bin; + * i = a(3); + * ``` + * (see page 35) + */ + IBM1231I: { + "code": "IBM1231I", + "severity": "E", + "message": "Arguments/subscripts have been specified for the variable ${variable name } , but it is neither an entry nor an array variable.", + "fullCode": "IBM1231IE" + } as SimplePLICode, + + /** + * A comma was followed by a semicolon rather than by a valid syntactical element (such + * as an identifier). The comma will be ignored in order to make the semicolon valid. + * Under RULES(LAXPUNC), a message with the same text, but lesser severity would be + * issued + * ```pli + * dcl 1 a, 2 b fixed bin, 2 c fixed bin, ; + * ``` + * (see page 35) + */ + IBM1232I: { + "code": "IBM1232I", + "severity": "E", + "message": "RULES(NOLAXPUNC) violation: extraneous comma at end of statement ignored.", + "fullCode": "IBM1232IE" + } as SimplePLICode, + + /** + * The indicated character is missing, and there are no more characters in the source. + * The missing character has been inserted by the parser in order to correct your source. + * Under RULES(LAXPUNC), a message with the same text, but lesser severity would be + * issued + * (see page 35) + */ + IBM1233I: { + "code": "IBM1233I", + "severity": "E", + "message": (character: string) => `RULES(NOLAXPUNC) violation: missing ${character} assumed.`, + "fullCode": "IBM1233IE" + } as ParametricPLICode, + + /** + * The indicated character is missing and has been inserted by the parser in order to + * correct your source. Under RULES(LAXPUNC), a message with the same text, but lesser + * severity would be issued + * ```pli + * display( 'Program starting' ; + * ``` + * (see page 36) + */ + IBM1234I: { + "code": "IBM1234I", + "severity": "E", + "message": (character: string, character2: string) => `RULES(NOLAXPUNC) violation: missing ${character} assumed before ${character2} .`, + "fullCode": "IBM1234IE" + } as ParametricPLICode, + + /** + * Data items cannot be transmitted unless a data format item is given in the format + * list. + * ```pli + * put edit ( (130)'-' ) ( col(1) ); + * ``` + * (see page 36) + */ + IBM1235I: { + "code": "IBM1235I", + "severity": "E", + "message": "No data format item in format list.", + "fullCode": "IBM1235IE" + } as SimplePLICode, + + /** + * A label specified on a PROCEDURE, PACKAGE or ENTRY statement should have no subscripts + * . + * (see page 36) + */ + IBM1236I: { + "code": "IBM1236I", + "severity": "E", + "message": (keyword: string) => `Subscripts on ${keyword} labels are ignored.`, + "fullCode": "IBM1236IE" + } as ParametricPLICode, + + /** + * An undeclared variable is used with an arguments list. This should give it a contextual + * declaration as BUILTIN, but its name is not that of a built-in function. + * (see page 36) + */ + IBM1237I: { + "code": "IBM1237I", + "severity": "E", + "message": (variablename: string) => `EXTERNAL ENTRY attribute is assumed for ${variablename} .`, + "fullCode": "IBM1237IE" + } as ParametricPLICode, + + /** + * The sift amount in ISLL is should not be greater than the precision of the result + * . + * ```pli + * i = isll( n, 221 ); + * ``` + * (see page 36) + */ + IBM1238I: { + "code": "IBM1238I", + "severity": "E", + "message": (BUILTINname: string) => `The second argument to the ${BUILTINname} built-in function is greater than the precision of the result.`, + "fullCode": "IBM1238IE" + } as ParametricPLICode, + + /** + * The named attribute is either not part of the PL\/I language or is not supported + * on this platform. + * ```pli + * dcl f file transient; + * ``` + * (see page 36) + */ + IBM1239I: { + "code": "IBM1239I", + "severity": "E", + "message": (attribute: string) => `The ${attribute} attribute is not supported and is ignored.`, + "fullCode": "IBM1239IE" + } as ParametricPLICode, + + /** + * The RETURNS descriptor may not specify an array. + * ```pli + * dcl a entry returns( (12) fixed bin ); + * ``` + * (see page 36) + */ + IBM1240I: { + "code": "IBM1240I", + "severity": "E", + "message": (attribute: string) => `The ${attribute} attribute is invalid in a RETURNS descriptor.`, + "fullCode": "IBM1240IE" + } as ParametricPLICode, + + /** + * Equal and not equal are defined for complex variables, but you have attempted to + * relate them in some other way. + * (see page 36) + */ + IBM1241I: { + "code": "IBM1241I", + "severity": "E", + "message": "Equality and inequality are the only valid comparisons of COMPLEX numbers.", + "fullCode": "IBM1241IE" + } as SimplePLICode, + + /** + * Other relationships between program control data are not defined. Perhaps a variable + * was misspelled. + * (see page 36) + */ + IBM1242I: { + "code": "IBM1242I", + "severity": "E", + "message": "Equality and inequality are the only valid comparisons of program control data.", + "fullCode": "IBM1242IE" + } as SimplePLICode, + + /** + * REGIONAL(2) and REGIONAL(3) ENVIRONMENT options are syntax-checked during compile-time + * but are not supported during run-time. + * (see page 36) + */ + IBM1243I: { + "code": "IBM1243I", + "severity": "E", + "message": "REGIONAL( ${integerspecification(2 or3) } ) ENVIRONMENT option is not supported.", + "fullCode": "IBM1243IE" + } as SimplePLICode, + + /** + * This applies to the KEYLENGTH, KEYLOC and RECSIZE suboptions. + * (see page 36) + */ + IBM1244I: { + "code": "IBM1244I", + "severity": "E", + "message": (option: string) => `The variable specified as the ${option} value in an ENVIRONMENT option must be a STATIC scalar 36 with the attributes REAL FIXED BIN(31,0).`, + "fullCode": "IBM1244IE" + } as ParametricPLICode, + + /** + * This applies to the PASSWORD suboption. + * (see page 37) + */ + IBM1245I: { + "code": "IBM1245I", + "severity": "E", + "message": (option: string) => `The variable specified as the ${option} value in an ENVIRONMENT option must be a STATIC scalar with the attribute CHARACTER.`, + "fullCode": "IBM1245IE" + } as ParametricPLICode, + + /** + * This message applies, for example, to the ADDR built- in function. The value returned + * by the ADDR function is the address of the first byte of its argument. If you use + * this pointer to refer to a based variable, the variable may be mapped over storage + * occupied by some other variable, rather than the storage occupied by the argument + * . + * (see page 37) + */ + IBM1246I: { + "code": "IBM1246I", + "severity": "E", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built-in function should be CONNECTED.`, + "fullCode": "IBM1246IE" + } as ParametricPLICode, + + /** + * The required implicit conversions will be performed, but this may indicate a programming + * error. This message will not be issued if the RULES(LAXCONV) option is specified + * . + * ```pli + * i = i * '2'; + * ``` + * (see page 37) + */ + IBM1247I: { + "code": "IBM1247I", + "severity": "E", + "message": "RULES(NOLAXCONV) violation: arithmetic operands should both be numeric.", + "fullCode": "IBM1247IE" + } as SimplePLICode, + + /** + * The argument to the named built-in function should have arithmetic type. The required + * implicit conversion will be performed, but this may indicate a programming error. + * This message will not be issued if the RULES(LAXCONV) option is specified. + * (see page 37) + */ + IBM1248I: { + "code": "IBM1248I", + "severity": "E", + "message": (BUILTINname: string) => `RULES(NOLAXCONV) violation: argument to ${BUILTINname} built- in function should have arithmetic type.`, + "fullCode": "IBM1248IE" + } as ParametricPLICode, + + /** + * The argument to the named built-in function should have CHARACTER type. The required + * implicit conversion will be performed, but this may indicate a programming error + * . + * (see page 37) + */ + IBM1249I: { + "code": "IBM1249I", + "severity": "E", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built-in function should have CHARACTER type.`, + "fullCode": "IBM1249IE" + } as ParametricPLICode, + + /** + * The required implicit conversion will be performed, but this may indicate a programming + * error. This message will not be issued if the RULES(LAXCONV) option is specified + * . + * ```pli + * x = max( x, y, z, '2' ); + * ``` + * (see page 37) + */ + IBM1252I: { + "code": "IBM1252I", + "severity": "E", + "message": (argumentnumber: string, BUILTINname: string) => `RULES(NOLAXCONV) violation: argument number ${argumentnumber} to ${BUILTINname} built-in function should have arithmetic type.`, + "fullCode": "IBM1252IE" + } as ParametricPLICode, + + /** + * The required implicit conversion will be performed, but this may indicate a programming + * error. This message will not be issued if the RULES(LAXCONV) option is specified + * . + * ```pli + * a = - b; + * ``` + * (see page 37) + */ + IBM1254I: { + "code": "IBM1254I", + "severity": "E", + "message": "RULES(NOLAXCONV) violation: arithmetic prefix operand should be numeric.", + "fullCode": "IBM1254IE" + } as SimplePLICode, + + /** + * The second argument to built-in functions such as COPY and REPEAT must be nonnegative + * . + * ```pli + * x = copy( y, -1 ); + * ``` 37 + * (see page 37) + */ + IBM1272I: { + "code": "IBM1272I", + "severity": "E", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function is negative. It will be changed to 0.`, + "fullCode": "IBM1272IE" + } as ParametricPLICode, + + /** + * The third argument to built-in functions such as COMPARE, PLIFILL, and PLIMOVE must + * be nonnegative. + * ```pli + * call plimove( a, b, -1 ); + * ``` + * (see page 38) + */ + IBM1273I: { + "code": "IBM1273I", + "severity": "E", + "message": (BUILTINname: string) => `Third argument to ${BUILTINname} built-in function is negative. It will be changed to 0.`, + "fullCode": "IBM1273IE" + } as ParametricPLICode, + + /** + * Expressions in IF, WHILE, UNTIL and undominated WHEN clauses should have the attributes + * BIT(1) NONVARYING. If not, the expression should be compared to an appropriate null + * value. This message will not be issued if the RULES(LAXIF) option is specified. + * ```pli + * dcl x bit(8) aligned; + * ... + * if x then ... + * ``` + * (see page 38) + */ + IBM1274I: { + "code": "IBM1274I", + "severity": "E", + "message": "RULES(NOLAXIF) violation: conditional expression does not have the attributes BIT(1).", + "fullCode": "IBM1274IE" + } as SimplePLICode, + + /** + * OPTIONS(RETCODE) is not supported on ATTACH references. + * (see page 38) + */ + IBM1281I: { + "code": "IBM1281I", + "severity": "E", + "message": "OPTIONS(RETCODE) on ATTACH reference is invalid and will be ignored.", + "fullCode": "IBM1281IE" + } as SimplePLICode, + + /** + * In an expression of the form x**y, x and y should not have string type. This message + * will not be issued if the RULES(LAXCONV) option is specified. + * (see page 38) + */ + IBM1287I: { + "code": "IBM1287I", + "severity": "E", + "message": "RULES(NOLAXCONV) violation: exponentiation operands should have numeric type.", + "fullCode": "IBM1287IE" + } as SimplePLICode, + + /** + * The maximum length allowed for a WIDECHAR variable is set by the STRING suboption + * of the LIMITS option. + * (see page 38) + */ + IBM1293I: { + "code": "IBM1293I", + "severity": "E", + "message": (maximumvalue: string) => `WIDECHAR extent is reduced to ${maximumvalue} .`, + "fullCode": "IBM1293IE" + } as ParametricPLICode, + + /** + * The maximum length allowed for a BIT variable is set by the STRING suboption of the + * LIMITS option. + * (see page 38) + */ + IBM1294I: { + "code": "IBM1294I", + "severity": "E", + "message": "BIT extent is reduced to ${maximum value } .", + "fullCode": "IBM1294IE" + } as SimplePLICode, + + /** + * The default lower bound is 1, but the upper bound must be greater than the lower + * bound. + * ```pli + * dcl x(-5) fixed bin; + * ``` + * (see page 38) + */ + IBM1295I: { + "code": "IBM1295I", + "severity": "E", + "message": "Sole bound specified is less than 1. An upper bound of 1 is assumed.", + "fullCode": "IBM1295IE" + } as SimplePLICode, + + /** + * The arguments passed to the MAIN procedure when SYSTEM(IMS) or SYSTEM(CICS) is in + * effect should not have the BYADDR attribute. + * ```pli + * *process system(ims); + * a: proc( x ); + * dcl x ptr byaddr; + * ``` + * (see page 38) + */ + IBM1296I: { + "code": "IBM1296I", + "severity": "E", + "message": "The BYADDR option conflicts with the SYSTEM option.", + "fullCode": "IBM1296IE" + } as SimplePLICode, + + /** + * In a BY NAME, the source and target structures should have at least one matching + * base element identifier. + * ```pli + * dcl 1 a, 2 b, 2 c, 2 d; + * dcl 1 w, 2 x, 2 y, 2 z; + * a = w, by name; + * ``` + * (see page 38) + */ + IBM1297I: { + "code": "IBM1297I", + "severity": "E", + "message": "Source and target in BY NAME assignment have no matching assignable base identifiers.", + "fullCode": "IBM1297IE" + } as SimplePLICode, + + /** + * In a B3 literal, each character must be either 0-7. + * (see page 38) + */ + IBM1298I: { + "code": "IBM1298I", + "severity": "E", + "message": "Characters in B3 literals must be 0-7.", + "fullCode": "IBM1298IE" + } as SimplePLICode, + + /** + * The maximum length allowed for a CHARACTER variable is set by the STRING suboption + * of the LIMITS option. + * (see page 39) + */ + IBM1299I: { + "code": "IBM1299I", + "severity": "E", + "message": (maximumvalue: string) => `CHARACTER extent is reduced to ${maximumvalue} .`, + "fullCode": "IBM1299IE" + } as ParametricPLICode, + + /** + * This is an E-level message because RULES(NOLAXDCL) has been specified. + * (see page 39) + */ + IBM1300I: { + "code": "IBM1300I", + "severity": "E", + "message": (variablename: string, attribute: string) => `RULES(NOLAXDCL) violation: ${variablename} is contextually declared as ${attribute} .`, + "fullCode": "IBM1300IE" + } as ParametricPLICode, + + /** + * An E in a FLOAT constant must be followed by at least one decimal digit (optionally + * preceded by a sign). + * (see page 39) + */ + IBM1301I: { + "code": "IBM1301I", + "severity": "E", + "message": "A DECIMAL exponent is required.", + "fullCode": "IBM1301IE" + } as SimplePLICode, + + /** + * Each block should contain no more than 31 DEFAULT predicates. + * (see page 39) + */ + IBM1302I: { + "code": "IBM1302I", + "severity": "E", + "message": "The limit on the number of DEFAULT predicates in a block has already been reached. This and subsequent DEFAULT predicates in this block will be ignored.", + "fullCode": "IBM1302IE" + } as SimplePLICode, + + /** + * The LBOUND, HBOUND, and DIMENSION built-in functions require two arguments when applied + * to arrays having more than one dimension. + * ```pli + * dcl a(5,10) fixed bin; + * do i = 1 to lbound(a); + * ``` + * (see page 39) + */ + IBM1303I: { + "code": "IBM1303I", + "severity": "E", + "message": "A second argument to the ${BUILTIN name } built-in function must be supplied for arrays with more than one dimension. A value of 1 is assumed.", + "fullCode": "IBM1303IE" + } as SimplePLICode, + + /** + * The DIMENSION, HBOUND and LBOUND built-in functions require that the second argument + * be positive. + * (see page 39) + */ + IBM1304I: { + "code": "IBM1304I", + "severity": "E", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function is not positive. A value of 1 is assumed.`, + "fullCode": "IBM1304IE" + } as ParametricPLICode, + + /** + * The second argument to the LBOUND, HBOUND, and DIMENSION built-in functions must + * be no greater than the number of dimensions of their array arguments. + * ```pli + * dcl a(5,10) fixed bin; + * do i = 1 to lbound(a,3); + * ``` + * (see page 39) + */ + IBM1305I: { + "code": "IBM1305I", + "severity": "E", + "message": (BUILTINname: string, dimensioncount: string) => `Second argument to ${BUILTINname} built-in function is greater than the number of dimensions for the first argument. A value of ${dimensioncount} is assumed.`, + "fullCode": "IBM1305IE" + } as ParametricPLICode, + + /** + * Level 1 variable names must not be repeated in the same block. + * ```pli + * dcl a fixed bin, a float; + * ``` + * (see page 39) + */ + IBM1306I: { + "code": "IBM1306I", + "severity": "E", + "message": (identifier: string) => `Repeated declaration of ${identifier} is invalid and will be ignored.`, + "fullCode": "IBM1306IE" + } as ParametricPLICode, + + /** + * The precision attribute must be specified only once in a declare. + * ```pli + * dcl a fixed(15) bin(31); + * ``` + * (see page 39) + */ + IBM1307I: { + "code": "IBM1307I", + "severity": "E", + "message": "Duplicate specification of arithmetic precision. Subsequent specification ignored.", + "fullCode": "IBM1307IE" + } as SimplePLICode, + + /** + * The variable names at any given sublevel within a structure or union must be unique + * . + * ```pli + * ``` 39 + * ```pli + * dcl 1 a, 2 b fixed, 2 b float; + * ``` + * (see page 39) + */ + IBM1308I: { + "code": "IBM1308I", + "severity": "E", + "message": (identifier: string) => `Repeated declaration of ${identifier} is invalid. The name will be replaced by an asterisk.`, + "fullCode": "IBM1308IE" + } as ParametricPLICode, + + /** + * Attributes like INITIAL must not be repeated for an element of a DECLARE statement + * . + * ```pli + * dcl a fixed init(0) bin init(2); + * ``` + * (see page 40) + */ + IBM1309I: { + "code": "IBM1309I", + "severity": "E", + "message": (attribute: string) => `Duplicate specification of ${attribute} . Subsequent specification ignored.`, + "fullCode": "IBM1309IE" + } as ParametricPLICode, + + /** + * Attributes must be consistent. + * ```pli + * dcl a fixed real float; + * ``` + * (see page 40) + */ + IBM1310I: { + "code": "IBM1310I", + "severity": "E", + "message": (character: string) => `The attribute ${character} conflicts with previous attributes and is ignored.`, + "fullCode": "IBM1310IE" + } as ParametricPLICode, + + /** + * The external name should contain some nonblank characters. + * ```pli + * dcl x external( ' ' ); + * ``` + * (see page 40) + */ + IBM1311I: { + "code": "IBM1311I", + "severity": "E", + "message": "EXTERNAL name contains no non- blank characters and is ignored.", + "fullCode": "IBM1311IE" + } as SimplePLICode, + + /** + * WX literals must represent unicode strings and hence must contain a multiple of 4 + * hex digits. + * ```pli + * x = '00'wx; + * ``` + * (see page 40) + */ + IBM1312I: { + "code": "IBM1312I", + "severity": "E", + "message": "WX literals should contain a multiple of 4 hex digits.", + "fullCode": "IBM1312IE" + } as SimplePLICode, + + /** + * ELSE clauses are valid immediately after an IF-THEN statement. + * ```pli + * do; if a > b then; end; else a = 0; + * ``` + * (see page 40) + */ + IBM1314I: { + "code": "IBM1314I", + "severity": "E", + "message": "ELSE clause outside of an open IF- THEN statement is ignored.", + "fullCode": "IBM1314IE" + } as SimplePLICode, + + /** + * END statements for groups with a subscripted label must have labels that are also + * subscripted. + * ```pli + * a(1): do; + * ... + * end a; + * ``` + * (see page 40) + */ + IBM1315I: { + "code": "IBM1315I", + "severity": "E", + "message": "END label matches a label on an open group, but that group label is subscripted.", + "fullCode": "IBM1315IE" + } as SimplePLICode, + + /** + * A Label on END statement must match a LABEL on an open BEGIN, DO, PACKAGE, PROCEDURE, + * or SELECT statement. + * ```pli + * a: do; + * ... + * end b; + * ``` + * (see page 40) + */ + IBM1316I: { + "code": "IBM1316I", + "severity": "E", + "message": "END label is not a label on any open group.", + "fullCode": "IBM1316IE" + } as SimplePLICode, + + /** + * After an OTHERWISE unit in a SELECT statement, only an END statement is valid. + * ```pli + * select; + * when ( ... ) + * do; + * end; + * otherwise + * do; + * end; + * display( .... ); + * ``` + * (see page 40) + */ + IBM1317I: { + "code": "IBM1317I", + "severity": "E", + "message": "An END statement may be missing after an OTHERWISE unit. One will be inserted.", + "fullCode": "IBM1317IE" + } as SimplePLICode, + + /** + * There was a conflict detected in the ENVIRONMENT options specification. In the example + * ENV(CONSECUTIVE INDEXED), the INDEXED option conflicts with the CONSECUTIVE option + * . + * (see page 40) + */ + IBM1318I: { + "code": "IBM1318I", + "severity": "E", + "message": "The ENVIRONMENT option ${option name } conflicts with preceding ENVIRONMENT options. This option will be ignored.", + "fullCode": "IBM1318IE" + } as SimplePLICode, + + /** + * During the conversion of a user expression during the compilation, the target string + * was found to be shorter than the source, thus causing the STRINGSIZE condition to + * be raised. + * (see page 41) + */ + IBM1319I: { + "code": "IBM1319I", + "severity": "E", + "message": "STRINGSIZE condition raised while evaluating expression. Result is truncated.", + "fullCode": "IBM1319IE" + } as SimplePLICode, + + /** + * If all the arguments in a SUBSTR reference are constants or restricted expressions, + * the reference will be evaluated at compile- time and the STRINGRANGE condition will + * occur if the arguments do not comply with the rules described for the SUBSTR built-in + * function. + * ```pli + * a = substr( 'abcdef', 5, 4 ); + * ``` + * (see page 41) + */ + IBM1320I: { + "code": "IBM1320I", + "severity": "E", + "message": "STRINGRANGE condition raised while evaluating expression. Arguments are adjusted to fit.", + "fullCode": "IBM1320IE" + } as SimplePLICode, + + /** + * LEAVE\/ITERATE statements for groups with a subscripted label must have labels that + * are also subscripted. + * ```pli + * a(1): do; + * ... + * leave a; + * ``` + * (see page 41) + */ + IBM1321I: { + "code": "IBM1321I", + "severity": "E", + "message": "LEAVE/ITERATE label matches a label on an open DO group, but that DO group label is subscripted.", + "fullCode": "IBM1321IE" + } as SimplePLICode, + + /** + * LEAVE\/ITERATE must specify a label on an open DO loop in the same block as the LEAVE\/ITERATE + * statement. + * ```pli + * a: do loop; + * begin; + * leave a; + * ``` + * (see page 41) + */ + IBM1322I: { + "code": "IBM1322I", + "severity": "E", + "message": "LEAVE/ITERATE label is not a label on any open DO group in its containing block.", + "fullCode": "IBM1322IE" + } as SimplePLICode, + + /** + * ITERATE\/LEAVE statements are valid only inside DO groups. + * ```pli + * a: begin; + * ... + * leave a; + * ... + * end a; + * ``` + * (see page 41) + */ + IBM1323I: { + "code": "IBM1323I", + "severity": "E", + "message": "ITERATE/LEAVE statement is invalid outside an open DO statement. The statement will be ignored.", + "fullCode": "IBM1323IE" + } as SimplePLICode, + + /** + * Names in the EXPORTS clause of a package statement must be unique. + * ```pli + * a: package exports( a1, a2, a1 ); + * ``` + * (see page 41) + */ + IBM1324I: { + "code": "IBM1324I", + "severity": "E", + "message": (name: string) => `The name ${name} occurs more than once in the EXPORTS clause.`, + "fullCode": "IBM1324IE" + } as ParametricPLICode, + + /** + * Each name in the EXPORTS clause of a package statement must be the name of some level-1 + * procedure in that package. + * ```pli + * a: package exports( a1, a2, a3 ); + * ``` + * (see page 41) + */ + IBM1325I: { + "code": "IBM1325I", + "severity": "E", + "message": (name: string) => `The name ${name} occurs in the EXPORTS clause, but is not the name of any nonnested PROCEDURE.`, + "fullCode": "IBM1325IE" + } as ParametricPLICode, + + /** + * An asterisk may be used only for structure or union names, or for members of structures + * or unions. An 41 asterisk may not be used for a level-1 structure name that specifies + * the LIKE attribute. + * ```pli + * dcl * char(20) static init('who can use + * me'); + * ``` + * (see page 41) + */ + IBM1326I: { + "code": "IBM1326I", + "severity": "E", + "message": "Variables declared without a name must be structure members or followed by a substructure list.", + "fullCode": "IBM1326IE" + } as SimplePLICode, + + /** + * If the parameter is EBCDIC or has the attribute NONNATIVE, unpredictable results + * can occur. + * (see page 42) + */ + IBM1327I: { + "code": "IBM1327I", + "severity": "E", + "message": "The CHARACTER VARYING parameter to MAIN should be ASCII with the attribute NATIVE.", + "fullCode": "IBM1327IE" + } as SimplePLICode, + + /** + * If the parameter is ASCII or has the attribute LITTLEENDIAN, unpredictable results + * can occur. This message applies only to SYSTEM(MVS) etc. + * (see page 42) + */ + IBM1328I: { + "code": "IBM1328I", + "severity": "E", + "message": "The CHARACTER VARYING parameter to MAIN should be EBCDIC with the attribute BIGENDIAN.", + "fullCode": "IBM1328IE" + } as SimplePLICode, + + /** + * Under RULES(NOMULTIENTRY), there should be no ENTRY statements in your source program + * . + * (see page 42) + */ + IBM1329I: { + "code": "IBM1329I", + "severity": "E", + "message": "ENTRY statements are not allowed under RULES(NOMULTIENTRY).", + "fullCode": "IBM1329IE" + } as SimplePLICode, + + /** + * The I in an iSUB token must represent a valid dimension number. + * ```pli + * dcl b(8) fixed bin def(0sub,1); + * ``` + * (see page 42) + */ + IBM1330I: { + "code": "IBM1330I", + "severity": "E", + "message": "The I in an iSUB token must be bigger than zero. A value of 1 is assumed.", + "fullCode": "IBM1330IE" + } as SimplePLICode, + + /** + * The I in an iSUB token must have only 1 or 2 digits. + * ```pli + * dcl b(8) fixed bin def(001sub,1); + * ``` + * (see page 42) + */ + IBM1331I: { + "code": "IBM1331I", + "severity": "E", + "message": "The I in an iSUB token must have no more than 2 digits. A value of 1 is assumed.", + "fullCode": "IBM1331IE" + } as SimplePLICode, + + /** + * A width must be specified on A, B, and G format items when specified on a GET statement + * . + * ```pli + * get edit(name) (a); + * ``` + * (see page 42) + */ + IBM1332I: { + "code": "IBM1332I", + "severity": "E", + "message": (formatitem: string) => `The ${formatitem} format item requires an argument when used in GET statement. A value of 1 is assumed.`, + "fullCode": "IBM1332IE" + } as ParametricPLICode, + + /** + * All array bounds in generic descriptions must be asterisks. + * ```pli + * dcl x generic ( e1 when( (10) fixed ), ... + * ``` + * (see page 42) + */ + IBM1333I: { + "code": "IBM1333I", + "severity": "E", + "message": "Non-asterisk array bounds are not permitted in GENERIC descriptions.", + "fullCode": "IBM1333IE" + } as SimplePLICode, + + /** + * All string lengths and area sizes in generic descriptions must be asterisks. + * ```pli + * dcl x generic ( e1 when( char(10) ), ... + * ``` + * (see page 42) + */ + IBM1334I: { + "code": "IBM1334I", + "severity": "E", + "message": "String lengths and area sizes are not permitted in GENERIC descriptions.", + "fullCode": "IBM1334IE" + } as SimplePLICode, + + /** + * Any ENTRY attribute in a generic description list must not be qualified with an entry + * description list. + * ```pli + * dcl x generic ( e1 when( entry( ptr ) ), ... + * ``` + * (see page 42) + */ + IBM1335I: { + "code": "IBM1335I", + "severity": "E", + "message": "Entry description lists are not permitted in GENERIC descriptions.", + "fullCode": "IBM1335IE" + } as SimplePLICode, + + /** + * The maximum length allowed for a GRAPHIC variable is set by the STRING suboption + * of the LIMITS option. + * (see page 42) + */ + IBM1336I: { + "code": "IBM1336I", + "severity": "E", + "message": (maximumvalue: string) => `GRAPHIC extent is reduced to ${maximumvalue} .`, + "fullCode": "IBM1336IE" + } as ParametricPLICode, + + /** + * GX literals must represent graphic strings and hence must contain a multiple of 4 + * hex digits. + * ```pli + * x = '00'gx; + * ``` + * (see page 43) + */ + IBM1337I: { + "code": "IBM1337I", + "severity": "E", + "message": "GX literals should contain a multiple of 4 hex digits.", + "fullCode": "IBM1337IE" + } as SimplePLICode, + + /** + * A variable has been declared with an upper bound that is less than its lower bound. + * The upper and lower bounds will be swapped in order to correct this. For example, + * DECLARE x(3:1) will be changed to DECLARE x(1:3). + * (see page 43) + */ + IBM1338I: { + "code": "IBM1338I", + "severity": "E", + "message": "Upper bound is less than lower bound. Bounds will be reversed.", + "fullCode": "IBM1338IE" + } as SimplePLICode, + + /** + * The maximum length of an identifier is set by the NAME suboption of the LIMITS compiler + * option. + * (see page 43) + */ + IBM1339I: { + "code": "IBM1339I", + "severity": "E", + "message": (identifier: string) => `Identifier is too long. It will be collapsed to ${identifier} .`, + "fullCode": "IBM1339IE" + } as ParametricPLICode, + + /** + * An argument containing BIT data has been found in a call to a COBOL routine. Mapping + * of such structures between PL\/I and COBOL is not supported. + * ```pli + * dcl f ext entry options( cobol ); + * dcl 1 a, 2 b bit(8), 2 c bit(8); + * call f( a ); + * ``` + * (see page 43) + */ + IBM1340I: { + "code": "IBM1340I", + "severity": "E", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } contains BIT data. NOMAP is assumed.", + "fullCode": "IBM1340IE" + } as SimplePLICode, + + /** + * An argument containing UNION data has been found in a call to a COBOL routine. Mapping + * of such structures between PL\/I and COBOL is not supported. + * ```pli + * dcl f ext entry options( cobol ); + * dcl 1 a union, 2 b char(4), 2 c fixed + * bin(31); + * call f( a ); + * ``` + * (see page 43) + */ + IBM1341I: { + "code": "IBM1341I", + "severity": "E", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is or contains a UNION. NOMAP is assumed.", + "fullCode": "IBM1341IE" + } as SimplePLICode, + + /** + * An argument containing non-constant extents has been found in a call to a COBOL routine. + * Mapping of such structures between PL\/I and COBOL is not supported. + * ```pli + * dcl f ext entry options( cobol ); + * dcl n static fixed bin init(17); + * dcl 1 a, 2 b char(n), 2 c fixed bin(31); + * call f( a ); + * ``` + * (see page 43) + */ + IBM1342I: { + "code": "IBM1342I", + "severity": "E", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } contains non-constant extents. NOMAP is assumed.", + "fullCode": "IBM1342IE" + } as SimplePLICode, + + /** + * The suboption should be specified as ARGn where \"n\" is an integer greater than + * 0. + * ```pli + * dcl f ext entry options( cobol + * nomap(arg0) ); + * ``` + * (see page 43) + */ + IBM1343I: { + "code": "IBM1343I", + "severity": "E", + "message": (nomapsuboption: string, option: string) => `${nomapsuboption} is invalid as a suboption of ${option} .`, + "fullCode": "IBM1343IE" + } as ParametricPLICode, + + /** + * NOMAP, NOMAPIN and NOMAPOUT are valid only for COBOL, FORTRAN and ASM Procedures + * and Entrys. + * (see page 43) + */ + IBM1344I: { + "code": "IBM1344I", + "severity": "E", + "message": "NOMAP specifications are valid only for ILC routines.", + "fullCode": "IBM1344IE" + } as SimplePLICode, + + /** + * The level-1 DECLARE statement may be missing. + * ```pli + * dcl + * 2 a, + * ``` 43 + * ```pli + * 3 b, + * 3 c, + * ``` + * (see page 43) + */ + IBM1345I: { + "code": "IBM1345I", + "severity": "E", + "message": "Initial level number in a structure is not 1.", + "fullCode": "IBM1345IE" + } as SimplePLICode, + + /** + * This is required to avoid ambiguities. For example, it is unclear whether all of + * the elements should be initialized with the value 4 or if the first element should + * be initialized with the value 9. + * ```pli + * dcl a(5) fixed bin init( (5)+4 ); + * ``` + * (see page 44) + */ + IBM1346I: { + "code": "IBM1346I", + "severity": "E", + "message": "INIT expression should be enclosed in parentheses.", + "fullCode": "IBM1346IE" + } as SimplePLICode, + + /** + * There is no language element of the form 1su. + * ```pli + * dcl a(10) def b(1su, 1sub ); + * ``` + * (see page 44) + */ + IBM1347I: { + "code": "IBM1347I", + "severity": "E", + "message": "B assumed to complete iSUB.", + "fullCode": "IBM1347IE" + } as SimplePLICode, + + /** + * In a BINARY constant, each digit must be a zero or one. + * (see page 44) + */ + IBM1348I: { + "code": "IBM1348I", + "severity": "E", + "message": "Digit in BINARY constant is not zero or one.", + "fullCode": "IBM1348IE" + } as SimplePLICode, + + /** + * In a BIT literal, each character must be either zero or one. + * (see page 44) + */ + IBM1349I: { + "code": "IBM1349I", + "severity": "E", + "message": "Characters in BIT literals must be 0 or 1.", + "fullCode": "IBM1349IE" + } as SimplePLICode, + + /** + * The indicated character is not part of the PL\/I character set. This can occur if + * a program containing NOT or OR symbols is ported from another machine and those + * symbols are translated to a character that is not part of the PL\/I character set. + * Using the NOT and OR compiler options can help avoid this problem. + * (see page 44) + */ + IBM1350I: { + "code": "IBM1350I", + "severity": "E", + "message": (n: string) => `Character with decimal value ${n} does not belong to the PL/I character set. It will be ignored.`, + "fullCode": "IBM1350IE" + } as ParametricPLICode, + + /** + * In a hex literal, each character must be either 0-9 or A-F. + * (see page 44) + */ + IBM1351I: { + "code": "IBM1351I", + "severity": "E", + "message": "Characters in hex literals must be 0-9 or A-F.", + "fullCode": "IBM1351IE" + } as SimplePLICode, + + /** + * The statement entered could not be parsed because the specified element is invalid + * . + * (see page 44) + */ + IBM1352I: { + "code": "IBM1352I", + "severity": "E", + "message": (character: string) => `The statement element ${character} is invalid. The statement will be ignored.`, + "fullCode": "IBM1352IE" + } as ParametricPLICode, + + /** + * Under LANGLVL(SAA), identifiers must start with an alphabetic character or with one + * of the extralingual characters. They may not start with an underscore. Under LANGLVL(SAA2), + * identifiers may start with an underscore, although names starting with _IBM are + * reserved for use by IBM. + * (see page 44) + */ + IBM1353I: { + "code": "IBM1353I", + "severity": "E", + "message": "Use of underscore as initial character in an identifier accepted although invalid under LANGLVL(SAA).", + "fullCode": "IBM1353IE" + } as SimplePLICode, + + /** + * A reference of the form x(1)(2).y.z is invalid. + * (see page 44) + */ + IBM1354I: { + "code": "IBM1354I", + "severity": "E", + "message": "Multiple argument lists are valid only with the last identifier in a reference.", + "fullCode": "IBM1354IE" + } as SimplePLICode, + + /** + * A reference of the form x().y.z is invalid. + * (see page 44) + */ + IBM1355I: { + "code": "IBM1355I", + "severity": "E", + "message": "Empty argument lists are valid only with the last identifier in a reference.", + "fullCode": "IBM1355IE" + } as SimplePLICode, + + /** + * The indicated character is not part of the PL\/I character set, but was immediately + * followed by the same character. This can occur if a program containing an OR symbol + * is ported from another machine and this symbol is translated to a character that + * is not part of the PL\/I character set. Using the OR compiler option can help avoid + * this problem. + * (see page 44) + */ + IBM1356I: { + "code": "IBM1356I", + "severity": "E", + "message": (n: string) => `Character with decimal value ${n} does not belong to the PL/I character set. It is assumed to be an OR symbol.`, + "fullCode": "IBM1356IE" + } as ParametricPLICode, + + /** + * The indicated character is not part of the PL\/I character set, but was immediately + * followed by an =, < or > symbol. This can occur if a program containing a NOT symbol + * is ported from another machine and this symbol is translated to a character that + * is not part of the PL\/I character set. Using the NOT compiler option can help avoid + * this problem. + * (see page 44) + */ + IBM1357I: { + "code": "IBM1357I", + "severity": "E", + "message": (n: string) => `Character with decimal value ${n} does not belong to the PL/I 44 character set. It is assumed to be a NOT symbol.`, + "fullCode": "IBM1357IE" + } as ParametricPLICode, + + /** + * This applies to the ROUND built-in function. The non- positive value will be changed + * to 1. + * ```pli + * dcl x float bin(53); + * x = round( x, -1 ); + * ``` + * (see page 45) + */ + IBM1358I: { + "code": "IBM1358I", + "severity": "E", + "message": (BUILTINname: string) => `The scale factor specified in ${BUILTINname} built-in function with a floating-point argument must be positive. It will be changed to 1.`, + "fullCode": "IBM1358IE" + } as ParametricPLICode, + + /** + * The names must be in ascending order. + * ```pli + * default range( h : a ) fixed bin; + * ``` + * (see page 45) + */ + IBM1359I: { + "code": "IBM1359I", + "severity": "E", + "message": (identifier: string, identifier2: string) => `Names in RANGE( ${identifier} : ${identifier2} ) are not in ascending order. Order is reversed.`, + "fullCode": "IBM1359IE" + } as ParametricPLICode, + + /** + * The name of a FORMAT constant cannot be used as the name of a LABEL constant as well + * . + * ```pli + * f(1): format( a, x(2), a ); + * f(2): ; + * ``` + * (see page 45) + */ + IBM1360I: { + "code": "IBM1360I", + "severity": "E", + "message": (identifier: string) => `The name ${identifier} has already been defined as a FORMAT constant.`, + "fullCode": "IBM1360IE" + } as ParametricPLICode, + + /** + * The name of a LABEL constant cannot be also used as the name of a FORMAT constant + * . + * ```pli + * f(1): ; + * f(2): format( a, x(2), a ); + * ``` + * (see page 45) + */ + IBM1361I: { + "code": "IBM1361I", + "severity": "E", + "message": (identifier: string) => `The name ${identifier} has already been defined as a LABEL constant.`, + "fullCode": "IBM1361IE" + } as ParametricPLICode, + + /** + * Declarations for label constant arrays are not permitted. + * ```pli + * dcl a(10) label variable; + * a(1): ... + * a(2): ... + * ``` + * (see page 45) + */ + IBM1362I: { + "code": "IBM1362I", + "severity": "E", + "message": (labelname: string) => `The label ${labelname} has already been declared. The explicit declaration of the label will not be accepted.`, + "fullCode": "IBM1362IE" + } as ParametricPLICode, + + /** + * The maximum structure level supported is 255. + * ```pli + * dcl + * 1 a, + * 256 b, + * 2 c, + * ``` + * (see page 45) + */ + IBM1363I: { + "code": "IBM1363I", + "severity": "E", + "message": "Structure level greater than 255 specified. It will be replaced by 255.", + "fullCode": "IBM1363IE" + } as SimplePLICode, + + /** + * A structure level is probably missing. + * ```pli + * dcl + * a, + * 2 b, + * 2 c, + * ``` + * (see page 45) + */ + IBM1364I: { + "code": "IBM1364I", + "severity": "E", + "message": "Elements with level numbers greater than 1 follow an element without a level number. A level number of 1 is assumed.", + "fullCode": "IBM1364IE" + } as SimplePLICode, + + /** + * To determine if a statement is an assignment or another PL\/I statement, many elements + * of the statement may need to be examined. If too many have to be examined, the compiler + * will flag the statement as in error. For instance, the following statement could + * be a DECLARE until the equal sign is encountered by the lexer. + * ```pli + * dcl ( a, b, c ) = d; + * ``` + * (see page 45) + */ + IBM1365I: { + "code": "IBM1365I", + "severity": "E", + "message": "Statement type resolution requires too many lexical units to 45 be examined. The statement will be ignored.", + "fullCode": "IBM1365IE" + } as SimplePLICode, + + /** + * LIKE cannot be specified on a parent structure or union. + * ```pli + * dcl + * 1 a like x, + * 2 b, + * 2 c, + * ``` + * (see page 46) + */ + IBM1366I: { + "code": "IBM1366I", + "severity": "E", + "message": "Level number following LIKE specification is greater than than the level number for the LIKE specification. LIKE attribute will be ignored.", + "fullCode": "IBM1366IE" + } as SimplePLICode, + + /** + * A WHEN or OTHERWISE may be missing. + * ```pli + * select; + * i = i + 1; + * when ( a > 0 ) + * ... + * ``` + * (see page 46) + */ + IBM1367I: { + "code": "IBM1367I", + "severity": "E", + "message": "Statements inside a SELECT must be preceded by a WHEN or an OTHERWISE clause. Statement is ignored.", + "fullCode": "IBM1367IE" + } as SimplePLICode, + + /** + * The named attribute is valid only on parent structures. + * ```pli + * dcl + * 1 a, + * 2 b union, + * 2 c1 fixed bin(31), + * 2 c2 float bin(21), + * ... + * ``` + * (see page 46) + */ + IBM1368I: { + "code": "IBM1368I", + "severity": "E", + "message": (character: string) => `The attribute ${character} is invalid if it is not followed by an element with a greater logical level.`, + "fullCode": "IBM1368IE" + } as ParametricPLICode, + + /** + * OPTIONS(MAIN) may be specified for only one PROCEDURE in a PACKAGE. All but the first + * specification will be ignored. + * (see page 46) + */ + IBM1369I: { + "code": "IBM1369I", + "severity": "E", + "message": "MAIN has already been specified in the PACKAGE.", + "fullCode": "IBM1369IE" + } as SimplePLICode, + + /** + * Extents must be positive. + * ```pli + * dcl x char(-10); + * ``` + * (see page 46) + */ + IBM1370I: { + "code": "IBM1370I", + "severity": "E", + "message": "Extent expression is negative. It will be replaced by the constant 1.", + "fullCode": "IBM1370IE" + } as SimplePLICode, + + /** + * Under the option RULES(NOLAXQUAL), all structure elements should be qualified with + * the name of at least one of their parents. + * (see page 46) + */ + IBM1371I: { + "code": "IBM1371I", + "severity": "E", + "message": (identifier: string) => `RULES(NOLAXQUAL) violation: structure element ${identifier} is not dot qualified.`, + "fullCode": "IBM1371IE" + } as ParametricPLICode, + + /** + * The EXTERNAL attribute is valid only on external procedures and entrys: for example, + * in a non-package, only on the outermost procedure and entry statements contained + * in it, and in a package, only on the procedures and entrys listed in the EXPORTS + * clause of the PACKAGE statement. + * ```pli + * a: proc; + * b: proc ext('_B'); + * ``` + * (see page 46) + */ + IBM1372I: { + "code": "IBM1372I", + "severity": "E", + "message": "EXTERNAL specified on internal entry point.", + "fullCode": "IBM1372IE" + } as SimplePLICode, + + /** + * Under the RULES(NOLAXDCL) option, all variables must be declared except for contextual + * declarations of built-in functions, SYSPRINT and SYSIN. + * (see page 46) + */ + IBM1373I: { + "code": "IBM1373I", + "severity": "E", + "message": (variablename: string) => `RULES(NOLAXDCL) violation: variable ${variablename} is implicitly declared.`, + "fullCode": "IBM1373IE" + } as ParametricPLICode, + + /** + * Only those contextual attributes that can be applied to a parameter will be applied. + * For example, CONSTANT and EXTERNAL, which apply to contextual file declarations, + * will not be applied to file parameters. + * ```pli + * a: proc( f ); + * open file( f ); + * ``` + * (see page 47) + */ + IBM1374I: { + "code": "IBM1374I", + "severity": "E", + "message": (variablename: string) => `Contextual attributes conflicting with PARAMETER will not be applied to ${variablename} .`, + "fullCode": "IBM1374IE" + } as ParametricPLICode, + + /** + * The number of bits, characters or graphics needed for a DEFINED variable must be + * no more than in the base variable. + * ```pli + * dcl a char(10); + * dcl b char(5) defined ( a ) pos( 8 ); + * ``` + * (see page 47) + */ + IBM1375I: { + "code": "IBM1375I", + "severity": "E", + "message": "The DEFINED variable ${variable name } does not fit into its base variable.", + "fullCode": "IBM1375IE" + } as SimplePLICode, + + /** + * Only attributes can be factored into declaration lists. + * ```pli + * dcl 1 a, 2 ( b, 3 c, 3 d ) fixed; + * ``` + * (see page 47) + */ + IBM1376I: { + "code": "IBM1376I", + "severity": "E", + "message": "Factoring of level numbers into declaration lists containing level numbers is invalid. The level numbers in the declaration list will be ignored.", + "fullCode": "IBM1376IE" + } as SimplePLICode, + + /** + * Scale factors are valid only for FIXED values. + * ```pli + * x = binary(1e0,4,2); + * ``` + * (see page 47) + */ + IBM1377I: { + "code": "IBM1377I", + "severity": "E", + "message": "A scale factor has been specified as an argument to the ${BUILTIN name } built-in function, but the result of that function has type FLOAT. The scale factor will be ignored.", + "fullCode": "IBM1377IE" + } as SimplePLICode, + + /** + * GENERIC entry references are not allowed to contain an arguments or subscripts list + * . + * ```pli + * dcl t generic( sub1(10) when((*)), + * sub2 when((*,*)) ); + * ``` + * (see page 47) + */ + IBM1378I: { + "code": "IBM1378I", + "severity": "E", + "message": "An arguments list or subscripts list has been provided for a GENERIC ENTRY reference. It will be ignored.", + "fullCode": "IBM1378IE" + } as SimplePLICode, + + /** + * GENERIC references cannot be locator-qualified. + * ```pli + * dcl x generic ( ... ); + * call p->x; + * ``` + * (see page 47) + */ + IBM1379I: { + "code": "IBM1379I", + "severity": "E", + "message": "Locator qualifier for GENERIC reference is ignored.", + "fullCode": "IBM1379IE" + } as SimplePLICode, + + /** + * In an assignment to a structure, some element of the structure must have the assignable + * attribute. + * ```pli + * dcl + * 1 a based, + * 2 nonasgn fixed bin, + * 2 nonasgn fixed bin; + * p->a = 0; + * ``` + * (see page 47) + */ + IBM1380I: { + "code": "IBM1380I", + "severity": "E", + "message": "Target structure in assignment contains no elements with the ASSIGNABLE attribute. No assignments will be generated.", + "fullCode": "IBM1380IE" + } as SimplePLICode, + + /** + * If a BIT structure (or union) is defined on a variable that is not aligned on a byte + * boundary, unpredictable results may occur. This is especially true if a substructure + * of the DEFINED variable is passed to another routine. + * (see page 47) + */ + IBM1381I: { + "code": "IBM1381I", + "severity": "E", + "message": "DEFINED base for a BIT structure should be aligned.", + "fullCode": "IBM1381IE" + } as SimplePLICode, + + /** + * FORMAT variables require block activation information; they cannot be initialized + * at compile-time. If the variable were a member of a structure, the storage class + * would not be changed to AUTOMATIC, and a severe message would be issued instead + * . + * (see page 48) + */ + IBM1382I: { + "code": "IBM1382I", + "severity": "E", + "message": "INITIAL attribute is invalid for STATIC FORMAT variables. Storage class is changed to AUTOMATIC.", + "fullCode": "IBM1382IE" + } as SimplePLICode, + + /** + * Labels are not permitted on DECLARE, DEFAULT, and DEFINE statements or on WHEN and + * OTHERWISE clauses. + * (see page 48) + */ + IBM1383I: { + "code": "IBM1383I", + "severity": "E", + "message": (keyword: string) => `Labels on ${keyword} statements are invalid and ignored.`, + "fullCode": "IBM1383IE" + } as ParametricPLICode, + + /** + * This message is used to report back end error messages. + * (see page 48) + */ + IBM1384I: { + "code": "IBM1384I", + "severity": "E", + "message": (message: string) => `${message}`, + "fullCode": "IBM1384IE" + } as ParametricPLICode, + + /** + * The base variable in the DEFINED attribute must consist of UNALIGNED, NONVARYING + * string variables of the same string type as the DEFINED variable. + * (see page 48) + */ + IBM1385I: { + "code": "IBM1385I", + "severity": "E", + "message": "Invalid DEFINED - string overlay defining attempted.", + "fullCode": "IBM1385IE" + } as SimplePLICode, + + /** + * When one bit variable is defined on a second (the base), the base may be an array, + * but it must not be subscripted. + * ```pli + * dcl a(20) bit(8) unaligned; + * dcl b bit(8) defined( a(3) ); + * ``` + * (see page 48) + */ + IBM1386I: { + "code": "IBM1386I", + "severity": "E", + "message": "DEFINED base for a BIT variable should not be subscripted.", + "fullCode": "IBM1386IE" + } as SimplePLICode, + + /** + * A parameter can have * extents only if a descriptor is also passed. The NODESCRIPTOR + * attribute will be ignored, and descriptors will be assumed to have been passed for + * all array, structure and string arguments. + * ```pli + * a: proc( x ) options(nodescriptor); + * dcl x char(*); + * ``` + * (see page 48) + */ + IBM1387I: { + "code": "IBM1387I", + "severity": "E", + "message": "The NODESCRIPTOR attribute is invalid when any parameters have * extents. The NODESCRIPTOR attribute will be ignored.", + "fullCode": "IBM1387IE" + } as SimplePLICode, + + /** + * A parameter can have the NONCONNECTED attribute only if a descriptor is also passed + * . + * ```pli + * a: proc( x ) options(nodescriptor); + * dcl x(20) fixed bin nonconnected; + * ``` + * (see page 48) + */ + IBM1388I: { + "code": "IBM1388I", + "severity": "E", + "message": "The NODESCRIPTOR attribute is invalid when any parameters have the NONCONNECTED attribute.", + "fullCode": "IBM1388IE" + } as SimplePLICode, + + /** + * The BUILTIN attribute can be applied only to identifiers that are the names of built-in + * functions or subroutines. + * (see page 48) + */ + IBM1389I: { + "code": "IBM1389I", + "severity": "E", + "message": (identifier: string) => `The identifier ${identifier} is not the name of a built-in function. The BUILTIN attribute will be ignored.`, + "fullCode": "IBM1389IE" + } as ParametricPLICode, + + /** + * This message is used by %NOTE statements with a return code of 8. + * (see page 48) + */ + IBM1390I: { + "code": "IBM1390I", + "severity": "E", + "message": (note: string) => `${note}`, + "fullCode": "IBM1390IE" + } as ParametricPLICode, + + /** + * An end-of-comment marker is probably missing. + * (see page 48) + */ + IBM1391I: { + "code": "IBM1391I", + "severity": "E", + "message": "End-of-source has been encountered after an unmatched comment marker.", + "fullCode": "IBM1391IE" + } as SimplePLICode, + + /** + * A closing quote is probably missing. + * (see page 48) + */ + IBM1392I: { + "code": "IBM1392I", + "severity": "E", + "message": "End-of-source has been encountered after an unmatched quote.", + "fullCode": "IBM1392IE" + } as SimplePLICode, + + /** + * The indicated element of the options list is invalid. + * ```pli + * dcl a file options( assembler ); + * ``` + * (see page 49) + */ + IBM1393I: { + "code": "IBM1393I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list conflicts with other attributes in the declaration. ${optionname} is ignored.`, + "fullCode": "IBM1393IE" + } as ParametricPLICode, + + /** + * The indicated element of the options list is invalid for BEGIN blocks (although it + * may be valid for PROCEDUREs). + * ```pli + * begin options( assembler ); + * ``` + * (see page 49) + */ + IBM1394I: { + "code": "IBM1394I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list is invalid for BEGIN blocks. ${optionname} is ignored.`, + "fullCode": "IBM1394IE" + } as ParametricPLICode, + + /** + * The indicated element of the options list is invalid for PACKAGEs (although it may + * be valid for PROCEDUREs). + * ```pli + * a: package exports(*) options( assembler ); + * ``` + * (see page 49) + */ + IBM1395I: { + "code": "IBM1395I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list is invalid for PACKAGEs. ${optionname} is ignored.`, + "fullCode": "IBM1395IE" + } as ParametricPLICode, + + /** + * The indicated element of the options list is invalid for PROCEDUREs (although it + * may be valid for ENTRYs). + * ```pli + * a: procedure options( inter ); + * ``` + * (see page 49) + */ + IBM1396I: { + "code": "IBM1396I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list is invalid for PROCEDUREs. ${optionname} is ignored.`, + "fullCode": "IBM1396IE" + } as ParametricPLICode, + + /** + * The indicated element of the options list is invalid for nested PROCEDUREs (although + * it may be valid for PROCEDUREs). + * ```pli + * a: proc; + * b: proc options( main ); + * ``` + * (see page 49) + */ + IBM1397I: { + "code": "IBM1397I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list is invalid for nested PROCEDUREs. ${optionname} is ignored.`, + "fullCode": "IBM1397IE" + } as ParametricPLICode, + + /** + * The indicated element of the options list is not a supported option in any statement + * or declaration. + * ```pli + * a: proc options( unknown ); + * ``` + * (see page 49) + */ + IBM1398I: { + "code": "IBM1398I", + "severity": "E", + "message": (optionname: string) => `Invalid item in OPTIONS list. ${optionname} is ignored.`, + "fullCode": "IBM1398IE" + } as ParametricPLICode, + + /** + * The indicated element of the options list is invalid for ENTRY statements (although + * it may be valid for PROCEDUREs). + * ```pli + * a: entry options( chargraphic ); + * ``` + * (see page 49) + */ + IBM1399I: { + "code": "IBM1399I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list is invalid for ENTRY statements. ${optionname} is ignored.`, + "fullCode": "IBM1399IE" + } as ParametricPLICode, + + /** + * The elements of the options list must be consistent, unlike in the example where + * BYVALUE and BYADDR conflict. + * ```pli + * a: proc options( byvalue byaddr ); + * ``` + * (see page 49) + */ + IBM1400I: { + "code": "IBM1400I", + "severity": "E", + "message": (optionname: string) => `Item in OPTIONS list conflicts with preceding items. ${optionname} is ignored.`, + "fullCode": "IBM1400IE" + } as ParametricPLICode, + + /** + * Parameter attributes, such as BYVALUE or CONNECTED, may be specified only for parameters + * . + * ```pli + * a: proc; + * dcl x byvalue ptr; + * ``` + * (see page 49) + */ + IBM1401I: { + "code": "IBM1401I", + "severity": "E", + "message": "Parameter attributes have been specified for a variable that is not a parameter. The parameter attributes are ignored.", + "fullCode": "IBM1401IE" + } as SimplePLICode, + + /** + * The POSITION attribute must specify a positive value. + * ```pli + * dcl a def b pos(-10); + * ``` + * (see page 50) + */ + IBM1402I: { + "code": "IBM1402I", + "severity": "E", + "message": "Constant in POSITION attribute is less than 1.", + "fullCode": "IBM1402IE" + } as SimplePLICode, + + /** + * The source should contain END statements for all PACKAGEs, PROCEDUREs, BEGIN blocks, + * DO groups, and SELECT statements, as well as statements for all IF-THEN and ELSE + * clauses. + * (see page 50) + */ + IBM1403I: { + "code": "IBM1403I", + "severity": "E", + "message": "The end of the source was reached before the logical end of the program. Null statements and END statements will be inserted as necessary to complete the program.", + "fullCode": "IBM1403IE" + } as SimplePLICode, + + /** + * Declarations for internal procedures are not permitted. + * ```pli + * a: proc; + * dcl b entry options(byvalue); + * b: proc; + * ``` + * (see page 50) + */ + IBM1404I: { + "code": "IBM1404I", + "severity": "E", + "message": (procname: string) => `The PROCEDURE name ${procname} has already been declared. The explicit declaration of the PROCEDURE name will not be accepted.`, + "fullCode": "IBM1404IE" + } as ParametricPLICode, + + /** + * A function can return only one value. + * ```pli + * dcl b entry returns( ptr, ptr ); + * ``` + * (see page 50) + */ + IBM1405I: { + "code": "IBM1405I", + "severity": "E", + "message": "Only one description is allowed in a returns descriptor.", + "fullCode": "IBM1405IE" + } as SimplePLICode, + + /** + * The string represented by a repetition factor applied to another string must conform + * to the same limits imposed on strings without repetition factors. + * ```pli + * a = (32767) 'abc'; + * ``` + * (see page 50) + */ + IBM1406I: { + "code": "IBM1406I", + "severity": "E", + "message": (repetitionfactor: string, string: string) => `The product of the repetition factor ${repetitionfactor} and the length of the constant ${string} to which it is applied is greater than the maximum length allowed for a constant. The repetition factor will be ignored.`, + "fullCode": "IBM1406IE" + } as ParametricPLICode, + + /** + * Scale factors must lie between -128 and 127 inclusive. + * (see page 50) + */ + IBM1407I: { + "code": "IBM1407I", + "severity": "E", + "message": "Scale factor is bigger than 127. It will be replaced by 127.", + "fullCode": "IBM1407IE" + } as SimplePLICode, + + /** + * Scale factors must lie between -128 and 127 inclusive. + * (see page 50) + */ + IBM1408I: { + "code": "IBM1408I", + "severity": "E", + "message": "Scale factor is less than -128. It will be replaced by -128.", + "fullCode": "IBM1408IE" + } as SimplePLICode, + + /** + * A WHEN or OTHERWISE clause has been found outside of a SELECT statement. + * (see page 50) + */ + IBM1409I: { + "code": "IBM1409I", + "severity": "E", + "message": "A SELECT statement may be missing. A SELECT statement, without an expression, will be inserted.", + "fullCode": "IBM1409IE" + } as SimplePLICode, + + /** + * An END statement enclosing a statement such as DO or SELECT has been found before + * the statement required after ELSE. + * ```pli + * do; + * if a > b then + * ... + * else + * end; + * ``` 50 + * (see page 50) + */ + IBM1410I: { + "code": "IBM1410I", + "severity": "E", + "message": "Semicolon inserted after ELSE keyword.", + "fullCode": "IBM1410IE" + } as SimplePLICode, + + /** + * An END statement enclosing a statement such as DO or SELECT has been found before + * the statement required after ON condition. + * ```pli + * do; + * ... + * on zdiv + * end; + * ``` + * (see page 51) + */ + IBM1411I: { + "code": "IBM1411I", + "severity": "E", + "message": "Semicolon inserted after ON clause.", + "fullCode": "IBM1411IE" + } as SimplePLICode, + + /** + * An END statement may be misplaced or a semicolon may be missing. + * (see page 51) + */ + IBM1412I: { + "code": "IBM1412I", + "severity": "E", + "message": "Semicolon inserted after OTHERWISE keyword.", + "fullCode": "IBM1412IE" + } as SimplePLICode, + + /** + * An END statement may be misplaced or a semicolon may be missing. + * (see page 51) + */ + IBM1413I: { + "code": "IBM1413I", + "severity": "E", + "message": "Semicolon inserted after THEN keyword.", + "fullCode": "IBM1413IE" + } as SimplePLICode, + + /** + * An END statement may be misplaced or a semicolon may be missing. + * (see page 51) + */ + IBM1414I: { + "code": "IBM1414I", + "severity": "E", + "message": "Semicolon inserted after WHEN clause.", + "fullCode": "IBM1414IE" + } as SimplePLICode, + + /** + * The source file contains statements after the END statement that closed the first + * PACKAGE or PROCEDURE. These statements will be ignored, but their presence may indicate + * a programming error. + * (see page 51) + */ + IBM1415I: { + "code": "IBM1415I", + "severity": "E", + "message": "Source file does not end with the logical end of the program.", + "fullCode": "IBM1415IE" + } as SimplePLICode, + + /** + * Subscripts can be specified only for elements of an array. + * (see page 51) + */ + IBM1416I: { + "code": "IBM1416I", + "severity": "E", + "message": (variablename: string) => `Subscripts have been specified for the variable ${variablename} , but it is not an array variable.`, + "fullCode": "IBM1416IE" + } as ParametricPLICode, + + /** + * Otherwise the STRINGRANGE condition would be raised. + * (see page 51) + */ + IBM1417I: { + "code": "IBM1417I", + "severity": "E", + "message": (BUILTINname: string) => `Second argument in ${BUILTINname} reference is less than 1. It will be replaced by 1.`, + "fullCode": "IBM1417IE" + } as ParametricPLICode, + + /** + * Otherwise the STRINGRANGE condition would be raised. + * (see page 51) + */ + IBM1418I: { + "code": "IBM1418I", + "severity": "E", + "message": (BUILTINname: string) => `Second argument in ${BUILTINname} reference is too big. It will be trimmed to fit.`, + "fullCode": "IBM1418IE" + } as ParametricPLICode, + + /** + * Otherwise the STRINGRANGE condition would be raised. + * (see page 51) + */ + IBM1419I: { + "code": "IBM1419I", + "severity": "E", + "message": (BUILTINname: string) => `Third argument in ${BUILTINname} reference is less than 0. It will be replaced by 0.`, + "fullCode": "IBM1419IE" + } as ParametricPLICode, + + /** + * The maximum K constant is 2097151K, and the maximum M constant is 2047M. + * (see page 51) + */ + IBM1420I: { + "code": "IBM1420I", + "severity": "E", + "message": "The factor in ${K/Mconstant } is too large and is replaced by ${maximum factor } .", + "fullCode": "IBM1420IE" + } as SimplePLICode, + + /** + * The maximum number of dimensions allowed for a variable, including all inherited + * dimensions, is 15. + * (see page 51) + */ + IBM1421I: { + "code": "IBM1421I", + "severity": "E", + "message": "More than 15 dimensions have been specified. Excess will be ignored.", + "fullCode": "IBM1421IE" + } as SimplePLICode, + + /** + * A block should contain no more than 500 LIKE references. Under LANGLVL(SAA2), there + * is no limit. + * (see page 51) + */ + IBM1422I: { + "code": "IBM1422I", + "severity": "E", + "message": "Maximum of 500 LIKE attributes per block exceeded.", + "fullCode": "IBM1422IE" + } as SimplePLICode, + + /** + * All AREA variables must be ALIGNED. + * (see page 51) + */ + IBM1423I: { + "code": "IBM1423I", + "severity": "E", + "message": "UNALIGNED attribute conflicts with AREA attribute.", + "fullCode": "IBM1423IE" + } as SimplePLICode, + + /** + * An *\/ was found when there was no open comment. + * (see page 52) + */ + IBM1424I: { + "code": "IBM1424I", + "severity": "E", + "message": "End of comment marker found when there are no open comments. Marker will be ignored.", + "fullCode": "IBM1424IE" + } as SimplePLICode, + + /** + * See the Language Reference Manual for the list of supported compiler directives. + * (see page 52) + */ + IBM1425I: { + "code": "IBM1425I", + "severity": "E", + "message": (directive: string) => `There is no compiler directive ${directive} . Input up to the next semicolon will be ignored.`, + "fullCode": "IBM1425IE" + } as ParametricPLICode, + + /** + * Structure level numbers must be positive. + * (see page 52) + */ + IBM1426I: { + "code": "IBM1426I", + "severity": "E", + "message": "Structure level of 0 replaced by 1.", + "fullCode": "IBM1426IE" + } as SimplePLICode, + + /** + * Numeric precisions must be positive. + * (see page 52) + */ + IBM1427I: { + "code": "IBM1427I", + "severity": "E", + "message": "Numeric precision of 0 replaced by 1.", + "fullCode": "IBM1427IE" + } as SimplePLICode, + + /** + * An X literal may not contain an odd number of digits. + * (see page 52) + */ + IBM1428I: { + "code": "IBM1428I", + "severity": "E", + "message": "X literals should contain a multiple of 2 hex digits.", + "fullCode": "IBM1428IE" + } as SimplePLICode, + + /** + * In DCL 1 a BASED, 2 b FIXED BIN INIT(3), 2 c( n REFER(b)), the initial clause for + * 'b' is invalid and may lead to unpredictable results. + * (see page 52) + */ + IBM1429I: { + "code": "IBM1429I", + "severity": "E", + "message": (variablename: string) => `INITIAL attribute for REFER object ${variablename} is invalid.`, + "fullCode": "IBM1429IE" + } as ParametricPLICode, + + /** + * If an ORDINAL type is declared with the UNSIGNED attribute, any INITIAL values specified + * must be nonnegative. + * (see page 52) + */ + IBM1430I: { + "code": "IBM1430I", + "severity": "E", + "message": (typetype: string, typename: string) => `UNSIGNED attribute for ${typetype} type ${typename} conflicts with negative INITIAL values and is ignored.`, + "fullCode": "IBM1430IE" + } as ParametricPLICode, + + /** + * An ORDINAL type must have a precision larger enough to cover the range of values + * defined for it. + * ```pli + * define ordinal + * colors + * ( red init(0), + * orange init(256) + * yellow init(512) ) unsigned prec(8); + * ``` + * (see page 52) + */ + IBM1431I: { + "code": "IBM1431I", + "severity": "E", + "message": (typetype: string, typename: string) => `PRECISION specified for ${typetype} type ${typename} is too small to cover its INITIAL values and is adjusted to fit.`, + "fullCode": "IBM1431IE" + } as ParametricPLICode, + + /** + * A named type may be defined only once in any block. + * (see page 52) + */ + IBM1432I: { + "code": "IBM1432I", + "severity": "E", + "message": (typename: string) => `The type ${typename} is already defined. The redefinition is ignored.`, + "fullCode": "IBM1432IE" + } as ParametricPLICode, + + /** + * Names in the RESERVES clause of a package statement must be unique. + * ```pli + * a: package reserves( a1, a2, a1 ); + * ``` + * (see page 52) + */ + IBM1433I: { + "code": "IBM1433I", + "severity": "E", + "message": (name: string) => `The name ${name} occurs more than once in the RESERVES clause.`, + "fullCode": "IBM1433IE" + } as ParametricPLICode, + + /** + * Each name in the RESERVES clause of a package statement must be the name of some + * level-1 static external variable in that package. + * ```pli + * a: package reserves( a1, a2, a3 ); + * ``` + * (see page 52) + */ + IBM1434I: { + "code": "IBM1434I", + "severity": "E", + "message": (name: string) => `The name ${name} occurs in the RESERVES clause, but is not the name of any level 1 STATIC EXTERNAL variable.`, + "fullCode": "IBM1434IE" + } as ParametricPLICode, + + /** + * Precision values must be positive. + * ```pli + * middle = divide( todo, 2, 0 ); + * ``` 52 + * (see page 52) + */ + IBM1435I: { + "code": "IBM1435I", + "severity": "E", + "message": (BUILTINname: string) => `A precision value less than 1 has been specified as an argument to the ${BUILTINname} built-in function. It will be replaced by 15.`, + "fullCode": "IBM1435IE" + } as ParametricPLICode, + + /** + * Scale factors must be between -128 and 127 inclusive. + * ```pli + * f = fixed( i, 15, 130 ); + * ``` + * (see page 53) + */ + IBM1436I: { + "code": "IBM1436I", + "severity": "E", + "message": (BUILTINname: string) => `The scale factor specified as an argument to the ${BUILTINname} built-in function is out of the valid range. It will be replaced by the nearest valid value.`, + "fullCode": "IBM1436IE" + } as ParametricPLICode, + + /** + * The maximum FIXED BINARY precision supported allowed depends on the FIXEDBIN suboption + * of the LIMITS option. + * ```pli + * i = signed( n, 63 ); + * ``` + * (see page 53) + */ + IBM1437I: { + "code": "IBM1437I", + "severity": "E", + "message": (BUILTINname: string) => `The second argument to the ${BUILTINname} built-in function is greater than the maximum FIXED BINARY precision. It will be replaced by the maximum value.`, + "fullCode": "IBM1437IE" + } as ParametricPLICode, + + /** + * More arguments were specified in an ENTRY reference than were defined as parameters + * in that ENTRY's declaration. + * ```pli + * dcl e entry( fixed bin ); + * call e( 1, 2 ); + * ``` + * (see page 53) + */ + IBM1438I: { + "code": "IBM1438I", + "severity": "E", + "message": (ENTRYname: string) => `Excess arguments for ENTRY ${ENTRYname} ignored.`, + "fullCode": "IBM1438IE" + } as ParametricPLICode, + + /** + * More arguments were specified for the indicated built- in function than are supported + * by that built-in function. + * ```pli + * i = acos( j, k ); + * ``` + * (see page 53) + */ + IBM1439I: { + "code": "IBM1439I", + "severity": "E", + "message": "Excess arguments for ${BUILTIN name } built-in function ignored.", + "fullCode": "IBM1439IE" + } as SimplePLICode, + + /** + * In a comparison of two ENTRY variables or constants, the ENTRY and RETURNS description + * lists should match. The linkages must also match. + * ```pli + * dcl e1 entry( fixed ), e2 entry( float ); + * if e1 = e2 then + * ``` + * (see page 53) + */ + IBM1441I: { + "code": "IBM1441I", + "severity": "E", + "message": "ENTRY/RETURNS description lists for comparands do not match.", + "fullCode": "IBM1441IE" + } as SimplePLICode, + + /** + * In an assignment of an ENTRY variable or constant, the ENTRY and RETURNS description + * lists for the source should match those of the target. The linkages must also match + * . + * ```pli + * dcl e1 variable entry( fixed ), e2 + * entry( float ); + * e1 = e2; + * ``` + * (see page 53) + */ + IBM1442I: { + "code": "IBM1442I", + "severity": "E", + "message": (targetvariable: string) => `The ENTRY/RETURNS description lists in the ENTRY to be assigned to ${targetvariable} do not match those of the target variable.`, + "fullCode": "IBM1442IE" + } as ParametricPLICode, + + /** + * When initializing an ENTRY variable or constant, the ENTRY and RETURNS description + * lists for the source should match those of the target. The linkages must also match + * . + * ```pli + * dcl e1 variable entry( fixed ); + * dcl e2 variable entry( float ) init( e1 ); + * ``` + * (see page 53) + */ + IBM1443I: { + "code": "IBM1443I", + "severity": "E", + "message": (targetvariable: string) => `An ENTRY/RETURNS description list in an ENTRY in the INITIAL list for ${targetvariable} do not match those of the target variable.`, + "fullCode": "IBM1443IE" + } as ParametricPLICode, + + /** + * When a function returns an ENTRY variable or constant, the ENTRY and RETURNS description + * lists in the returned ENTRY reference should match those in the containing procedure's + * RETURNS option. The linkages must also match. 53 + * ```pli + * a: proc returns( entry( float ) ); + * dcl e1 entry( fixed ); + * return( e1 ); + * ``` + * (see page 53) + */ + IBM1444I: { + "code": "IBM1444I", + "severity": "E", + "message": "The ENTRY/RETURNS description lists in the RETURN statement do not match those in the corresponding RETURNS attribute", + "fullCode": "IBM1444IE" + } as SimplePLICode, + + /** + * This message also occurs if the linkages do not match. + * ```pli + * dcl a entry( entry( float ) ); + * dcl e1 entry( fixed ); + * call a( e1 ); + * ``` + * (see page 54) + */ + IBM1445I: { + "code": "IBM1445I", + "severity": "E", + "message": (argumentnumber: string, entryname: string) => `The ENTRY/RETURNS description lists for argument number ${argumentnumber} in ENTRY reference ${entryname} do not match those in the corresponding parameter.`, + "fullCode": "IBM1445IE" + } as ParametricPLICode, + + /** + * Otherwise the STRINGRANGE condition would be raised. + * (see page 54) + */ + IBM1446I: { + "code": "IBM1446I", + "severity": "E", + "message": (BUILTINname: string) => `Third argument in ${BUILTINname} reference is too big. It will be trimmed to fit.`, + "fullCode": "IBM1446IE" + } as ParametricPLICode, + + /** + * In PL\/I statements, hex literals should be specified with an X suffix. + * (see page 54) + */ + IBM1447I: { + "code": "IBM1447I", + "severity": "E", + "message": "Literals with an X prefix are valid only in EXEC SQL statements.", + "fullCode": "IBM1447IE" + } as SimplePLICode, + + /** + * In the SAA level-1 language definition, extents in BASED variables must all be constant + * except where the REFER option is used. The following would be invalid + * ```pli + * dcl x based char(n); + * ``` + * (see page 54) + */ + IBM1448I: { + "code": "IBM1448I", + "severity": "E", + "message": "Use of nonconstant extents in BASED variables without REFER accepted although invalid under LANGLVL(SAA).", + "fullCode": "IBM1448IE" + } as SimplePLICode, + + /** + * Type functions are not part of the SAA level-1 language. + * (see page 54) + */ + IBM1449I: { + "code": "IBM1449I", + "severity": "E", + "message": (typefunction: string) => `Use of ${typefunction} accepted although invalid under LANGLVL(SAA).`, + "fullCode": "IBM1449IE" + } as ParametricPLICode, + + /** + * The indicated keyword (UNSIGNED in the example below) is not defined in the SAA level-1 + * language. + * ```pli + * dcl x fixed bin unsigned; + * ``` + * (see page 54) + */ + IBM1450I: { + "code": "IBM1450I", + "severity": "E", + "message": (keyword: string) => `${keyword} keyword accepted although invalid under LANGLVL(SAA).`, + "fullCode": "IBM1450IE" + } as ParametricPLICode, + + /** + * The definition of the SAA level-1 language does not include S, D, and Q floating-point + * constants. + * (see page 54) + */ + IBM1451I: { + "code": "IBM1451I", + "severity": "E", + "message": "Use of S, D and Q constants accepted although invalid under LANGLVL(SAA).", + "fullCode": "IBM1451IE" + } as SimplePLICode, + + /** + * The definition of the SAA level-1 language does not permit using underscores in numeric + * and hex constants. + * (see page 54) + */ + IBM1452I: { + "code": "IBM1452I", + "severity": "E", + "message": "Use of underscores in constants accepted although invalid under LANGLVL(SAA).", + "fullCode": "IBM1452IE" + } as SimplePLICode, + + /** + * The definition of the SAA level-1 language does not permit using asterisks for structure + * element names. + * (see page 54) + */ + IBM1453I: { + "code": "IBM1453I", + "severity": "E", + "message": "Use of asterisks for names in declares accepted although invalid under LANGLVL(SAA).", + "fullCode": "IBM1453IE" + } as SimplePLICode, + + /** + * The definition of the SAA level-1 language does not include XN and XU constants. + * (see page 54) + */ + IBM1454I: { + "code": "IBM1454I", + "severity": "E", + "message": "Use of XN and XU constants accepted although invalid under LANGLVL(SAA).", + "fullCode": "IBM1454IE" + } as SimplePLICode, + + /** + * Under LANGLVL(SAA), the DATETIME built-in function cannot have any arguments. + * ```pli + * s = datetime('DDMMYYYY'); + * ``` + * (see page 55) + */ + IBM1455I: { + "code": "IBM1455I", + "severity": "E", + "message": (BUILTINname: string) => `Use of arguments with ${BUILTINname} built-in function accepted although invalid under LANGLVL(SAA).`, + "fullCode": "IBM1455IE" + } as ParametricPLICode, + + /** + * Under LANGLVL(SAA), the VERIFY and INDEX built-in functions are supposed to have + * exactly 2 arguments. + * ```pli + * i = verify( s, j, k ); + * ``` + * (see page 55) + */ + IBM1456I: { + "code": "IBM1456I", + "severity": "E", + "message": (BUILTINname: string) => `Use of 3 arguments with ${BUILTINname} built-in function accepted although invalid under LANGLVL(SAA).`, + "fullCode": "IBM1456IE" + } as ParametricPLICode, + + /** + * Under LANGLVL(SAA), the DIM, LBOUND and HBOUND built-in functions are supposed to + * have 2 arguments. + * ```pli + * i = dim( a ); + * ``` + * (see page 55) + */ + IBM1457I: { + "code": "IBM1457I", + "severity": "E", + "message": (BUILTINname: string) => `Use of 1 argument with ${BUILTINname} built-in function accepted although invalid under LANGLVL(SAA).`, + "fullCode": "IBM1457IE" + } as ParametricPLICode, + + /** + * Under RULES(NOGOTO(STRICT)), there should be no GOTO statements in your source program + * except for those that exit an ON-unit. + * (see page 55) + */ + IBM1458I: { + "code": "IBM1458I", + "severity": "E", + "message": "GOTO is not allowed under RULES(NOGOTO).", + "fullCode": "IBM1458IE" + } as SimplePLICode, + + /** + * The AUTOMATIC variables in a block may be used in the declare statements and the + * executable statements of any contained block, but in the block in which they are + * declared, they should be used only in the executable statements. + * ```pli + * dcl x fixed bin(15) automatic; + * dcl y(x) fixed bin(15) automatic; + * ``` + * (see page 55) + */ + IBM1459I: { + "code": "IBM1459I", + "severity": "E", + "message": "Uninitialized AUTOMATIC variables in a block should not be used in the prologue of that block.", + "fullCode": "IBM1459IE" + } as SimplePLICode, + + /** + * RULES(IBM) allows scaled FIXED BIN, but RULES(ANS) supports it only for FIXED DECIMAL. + * RULES(ANS) will ignore the scale factors in the following declares + * ```pli + * dcl x fixed bin(31,16); + * dcl y entry( fixed bin(31,16) ); + * ``` + * (see page 55) + */ + IBM1460I: { + "code": "IBM1460I", + "severity": "E", + "message": "Under RULES(ANS), nonzero scale factors are not permitted in declarations of FIXED BIN. Declared scale factor will be ignored.", + "fullCode": "IBM1460IE" + } as SimplePLICode, + + /** + * You must recode such statements to avoid this restriction. The compiler will ignore + * the scale factors in the following built-ins + * ```pli + * dcl (x,y) fixed bin(15,0); + * put list( bin(x,31,2) ); + * put list( prec(x,31,2) ); + * ``` + * (see page 55) + */ + IBM1461I: { + "code": "IBM1461I", + "severity": "E", + "message": (BUILTINname: string, precision: string, scalefactor: string) => `Tne result of the ${BUILTINname} built-in would have the attributes FIXED BIN( ${precision} , ${scalefactor} ), but under RULES(ANS), FIXED BIN scale factors must be zero. The scale factor will be set to zero.`, + "fullCode": "IBM1461IE" + } as ParametricPLICode, + + /** + * In a comparison, if one comparand has the DATE attribute, the other should also. + * If the non-date is an expression that could have a value that is valid for the date + * pattern, it will be viewed as if it had the same DATE attribute as the date comparand + * . + * (see page 55) + */ + IBM1462I: { + "code": "IBM1462I", + "severity": "E", + "message": "Expression in comparison interpreted with DATE attribute.", + "fullCode": "IBM1462IE" + } as SimplePLICode, + + /** + * Comparisons are the only infix operations where operands with the DATE attribute + * may be used. If they are used in any other operation, the DATE attribute will be + * ignored. So, in the following code, the addition will be flagged and the DATE attribute + * ignored. + * ```pli + * dcl x char(5) date('YYDDD'); + * put list( x + 1 ); + * ``` + * (see page 55) + */ + IBM1463I: { + "code": "IBM1463I", + "severity": "E", + "message": "Operand with DATE attribute is invalid except in compare or 55 assign. DATE attribute will be ignored.", + "fullCode": "IBM1463IE" + } as SimplePLICode, + + /** + * In a comparison, if one comparand has the DATE attribute, the other should also. + * If the non-date is an expression that could not have a value that is not valid for + * the date pattern, the DATE attribute will be ignored. + * (see page 56) + */ + IBM1464I: { + "code": "IBM1464I", + "severity": "E", + "message": "DATE attribute ignored in comparison with non-date expression.", + "fullCode": "IBM1464IE" + } as SimplePLICode, + + /** + * If the target in an assignment has the DATE attribute, the source should also. If + * the target is a pseudovariable, message 1466 is issued instead. + * ```pli + * dcl x char(6); + * x = date(); + * ``` + * (see page 56) + */ + IBM1465I: { + "code": "IBM1465I", + "severity": "E", + "message": (variable: string) => `Source in assignment has the DATE attribute, but target ${variable} does not. The DATE attribute will be ignored.`, + "fullCode": "IBM1465IE" + } as ParametricPLICode, + + /** + * If the source in an assignment has the DATE attribute, the target should also. + * (see page 56) + */ + IBM1466I: { + "code": "IBM1466I", + "severity": "E", + "message": "Source in assignment has the DATE attribute, but target does not. The DATE attribute will be ignored.", + "fullCode": "IBM1466IE" + } as SimplePLICode, + + /** + * If an INITIAL expression has the DATE attribute, the target should also. + * (see page 56) + */ + IBM1467I: { + "code": "IBM1467I", + "severity": "E", + "message": (variablename: string) => `Source in INITIAL clause for ${variablename} has the DATE attribute but the target does not. The DATE attribute will be ignored.`, + "fullCode": "IBM1467IE" + } as ParametricPLICode, + + /** + * The argument and parameter should match, unlike in the example below + * ```pli + * dcl x entry( char(6) ); + * call x( date() ); + * ``` + * (see page 56) + */ + IBM1468I: { + "code": "IBM1468I", + "severity": "E", + "message": "Argument number ${argument number } in ENTRY reference ${entry name } has the DATE attribute but the corresponding parameter does not. The DATE attribute will be ignored.", + "fullCode": "IBM1468IE" + } as SimplePLICode, + + /** + * The attributes of the RETURNed expression and in the RETURNS option should match, + * unlike in the example below + * ```pli + * x: proc returns( char(6) ); + * ... + * return( date() ); + * ``` + * (see page 56) + */ + IBM1469I: { + "code": "IBM1469I", + "severity": "E", + "message": "Source in RETURN statement has the DATE attribute, but the corresponding RETURNS option does not. The DATE attribute will be ignored.", + "fullCode": "IBM1469IE" + } as SimplePLICode, + + /** + * No other options are valid for the INCLUDE preprocessor. + * (see page 56) + */ + IBM1470I: { + "code": "IBM1470I", + "severity": "E", + "message": "An ID option must be specified for the INCLUDE preprocessor.", + "fullCode": "IBM1470IE" + } as SimplePLICode, + + /** + * The INCLUDE preprocessor ID option must have one suboption consisting of a string + * specifying the INCLUDE directive. + * (see page 56) + */ + IBM1471I: { + "code": "IBM1471I", + "severity": "E", + "message": "The ID option specified for the INCLUDE preprocessor is invalid.", + "fullCode": "IBM1471IE" + } as SimplePLICode, + + /** + * The suboption specified for the INCLUDE preprocessor ID option must be closed with + * a right parenthesis. + * (see page 56) + */ + IBM1472I: { + "code": "IBM1472I", + "severity": "E", + "message": "A closing right parenthesis is missing from the ID option specified for the INCLUDE preprocessor.", + "fullCode": "IBM1472IE" + } as SimplePLICode, + + /** + * A statement that starts with the preprocessor INCLUDE directive specified in that + * preprocessor's ID option must be followed by a name and, optionally, a semicolon + * . + * (see page 57) + */ + IBM1473I: { + "code": "IBM1473I", + "severity": "E", + "message": "The syntax of the preprocessor INCLUDE directive is incorrect.", + "fullCode": "IBM1473IE" + } as SimplePLICode, + + /** + * If the target in an assignment has the DATE attribute, the source should also. If + * the target is a pseudovariable, message 1475 is issued instead. + * ```pli + * dcl x char(6) date('YYMMDD'); + * x = ''; + * ``` + * (see page 57) + */ + IBM1474I: { + "code": "IBM1474I", + "severity": "E", + "message": (variable: string) => `Source in assignment does not have the DATE attribute, but target ${variable} does. The DATE attribute will be ignored.`, + "fullCode": "IBM1474IE" + } as ParametricPLICode, + + /** + * If the target in an assignment has the DATE attribute, the source should also. + * (see page 57) + */ + IBM1475I: { + "code": "IBM1475I", + "severity": "E", + "message": "Target in assignment has the DATE attribute, but source does not. The DATE attribute will be ignored.", + "fullCode": "IBM1475IE" + } as SimplePLICode, + + /** + * If a variable has the DATE attribute, then any INITIAL value for it should also. + * (see page 57) + */ + IBM1476I: { + "code": "IBM1476I", + "severity": "E", + "message": (variablename: string) => `Source in INITIAL clause for ${variablename} does not have the DATE attribute but the target does. The DATE attribute will be ignored.`, + "fullCode": "IBM1476IE" + } as ParametricPLICode, + + /** + * The argument and parameter should match, unlike in the example below + * ```pli + * dcl x entry( char(6) date('YYMMDD') ); + * call x( '' ); + * ``` + * (see page 57) + */ + IBM1477I: { + "code": "IBM1477I", + "severity": "E", + "message": "Argument number ${argument number } in ENTRY reference ${entry name } does not have the DATE attribute but the corresponding parameter does. The DATE attribute will be ignored.", + "fullCode": "IBM1477IE" + } as SimplePLICode, + + /** + * The attributes of the RETURNed expression and in the RETURNS option should match, + * unlike in the example below + * ```pli + * x: proc returns( char(6) date('YYMMDD') ); + * ... + * return( '' ); + * ``` + * (see page 57) + */ + IBM1478I: { + "code": "IBM1478I", + "severity": "E", + "message": "Source in RETURN statement does not have the DATE attribute, but the corresponding RETURNS option does. The DATE attribute will be ignored.", + "fullCode": "IBM1478IE" + } as SimplePLICode, + + /** + * Under RULES(NOMULTIEEXIT), there should be at most one RETURN statement in each PROCEDURE + * and BEGIN block in your source program. + * (see page 57) + */ + IBM1479I: { + "code": "IBM1479I", + "severity": "E", + "message": "Multiple RETURN statements are not allowed under RULES(NOMULTIEXIT).", + "fullCode": "IBM1479IE" + } as SimplePLICode, + + /** + * Under RULES(NOMULTICLOSE), there should be no multiple closure of groups in your + * source program. + * (see page 57) + */ + IBM1480I: { + "code": "IBM1480I", + "severity": "E", + "message": "Multiple closure of groups is not allowed under RULES(NOMULTICLOSE).", + "fullCode": "IBM1480IE" + } as SimplePLICode, + + /** + * Under RULES(NOBYNAME), there should be no BYNAME assignment statements in your source + * program. + * (see page 57) + */ + IBM1481I: { + "code": "IBM1481I", + "severity": "E", + "message": "BYNAME assignment statements are not allowed under RULES(NOBYNAME).", + "fullCode": "IBM1481IE" + } as SimplePLICode, + + /** + * It will be given the default attributes, but this may be because of an error in the + * declare. For instance, in the following example, parentheses may be missing. Under + * RULES(LAXDCL), this is a W-level message. + * ```pli + * dcl a, b fixed bin; + * ``` + * (see page 57) + */ + IBM1482I: { + "code": "IBM1482I", + "severity": "E", + "message": (variablename: string) => `RULES(NOLAXDCL) violation: the variable ${variablename} is declared without any data attributes.`, + "fullCode": "IBM1482IE" + } as ParametricPLICode, + + /** + * It will be given the default attributes, but this may be because of an error in the + * declare. For instance, in the following example, the level number on c and d should + * probably be 3. Under RULES(LAXDCL), this is a W-level message. + * ```pli + * dcl a, b fixed bin; + * 1 a, + * 2 b, + * 2 c, + * 2 d; + * ``` + * (see page 58) + */ + IBM1483I: { + "code": "IBM1483I", + "severity": "E", + "message": (variablename: string) => `RULES(NOLAXDCL) violation: the structure member ${variablename} is declared without any data attributes. A level number may be incorrect.`, + "fullCode": "IBM1483IE" + } as ParametricPLICode, + + /** + * It will be given the default attributes, but this may be because of an error in the + * declare. For instance, in the following example, the level number on c and d should + * probably be 3. Under RULES(LAXDCL), this is a W-level message. + * ```pli + * dcl a, b fixed bin; + * 1 a, + * 2 *, + * 2 c, + * 2 d; + * ``` + * (see page 58) + */ + IBM1484I: { + "code": "IBM1484I", + "severity": "E", + "message": "RULES(NOLAXDCL) violation: an unnamed structure member is declared without any data attributes. A level number may be incorrect.", + "fullCode": "IBM1484IE" + } as SimplePLICode, + + /** + * The compiler assumes that an END statement to close the open DO group is missing, + * but it may be that a SELECT statement to start a nested SELECT is missing. In either + * case, the code is incorrect and should be corrected. + * (see page 58) + */ + IBM1485I: { + "code": "IBM1485I", + "severity": "E", + "message": "A WHEN or OTHERWISE clause has been found inside of an open DO group contained in an open SELECT group. An END statement may be missing and will be inserted in an attempt to fix the problem.", + "fullCode": "IBM1485IE" + } as SimplePLICode, + + /** + * Every ( should have a matching ). + * (see page 58) + */ + IBM1486I: { + "code": "IBM1486I", + "severity": "E", + "message": "Statement contains a mismatching number of ( and ).", + "fullCode": "IBM1486IE" + } as SimplePLICode, + + /** + * Every (: should have a matching :). + * (see page 58) + */ + IBM1487I: { + "code": "IBM1487I", + "severity": "E", + "message": "Statement contains a mismatching number of (: and :).", + "fullCode": "IBM1487IE" + } as SimplePLICode, + + /** + * Do not specify an alternate DD for SYSIN in a *PROCESS statement. + * (see page 58) + */ + IBM1488I: { + "code": "IBM1488I", + "severity": "E", + "message": "Specification of an alternate DD for SYSIN after the source has been opened will be ignored.", + "fullCode": "IBM1488IE" + } as SimplePLICode, + + /** + * Look in STDOUT to see the message issued by the compiler backend. + * (see page 58) + */ + IBM2400I: { + "code": "IBM2400I", + "severity": "E", + "message": "Compiler backend issued error messages to STDOUT.", + "fullCode": "IBM2400IE" + } as SimplePLICode, + + /** + * The indicated character is missing and has been inserted by the parser in order to + * correct your source. Under RULES(LAXPUNC), a message with the same text, but lesser + * severity would be issued + * ```pli + * xx: dcl test fixed bin; + * ``` 58 + * (see page 58) + */ + IBM2401I: { + "code": "IBM2401I", + "severity": "E", + "message": (character: string, character2: string) => `RULES(NOLAXPUNC) violation: missing ${character} assumed before ${character2} . DECLARE and other nonexecutable statements should not have labels.`, + "fullCode": "IBM2401IE" + } as ParametricPLICode, + + /** + * The amount of storage needed for a BASED variable must be no more than provided by + * its base variable. + * ```pli + * dcl a char(10); + * dcl b char(15) based(addr(a)); + * ``` + * (see page 59) + */ + IBM2402I: { + "code": "IBM2402I", + "severity": "E", + "message": (variablename: string, variablename2: string, variablename3: string, variablename4: string) => `${variablename} is declared as BASED on the ADDR of ${variablename2} , but ${variablename3} requires more storage than ${variablename4} .`, + "fullCode": "IBM2402IE" + } as ParametricPLICode, + + /** + * When the NOPROCESS option is in effect, the source should contain no PROCESS statements + * . + * (see page 59) + */ + IBM2403I: { + "code": "IBM2403I", + "severity": "E", + "message": "PROCESS statements are not permitted under the NOPROCESS option.", + "fullCode": "IBM2403IE" + } as SimplePLICode, + + /** + * The amount of storage needed for a BASED variable must be no more than provided by + * its base variable. + * ```pli + * dcl 1 a, 2 a1 char(10), 2 a2 char(10); + * dcl b char(15) based(addr(a2)); + * ``` + * (see page 59) + */ + IBM2404I: { + "code": "IBM2404I", + "severity": "E", + "message": (variablename: string, variablename2: string, variablename3: string, variablename4: string, variablename5: string) => `${variablename} is declared as BASED on the ADDR of ${variablename2} , but ${variablename3} requires more storage than remains in the enclosing level 1 structure ${variablename4} after the location of ${variablename5} .`, + "fullCode": "IBM2404IE" + } as ParametricPLICode, + + /** + * Under RULES(NOEVENDEC), there should be no FIXED DECIMAL data declared with an even + * precision. + * ```pli + * dcl a fixed dec(10); + * ``` + * (see page 59) + */ + IBM2405I: { + "code": "IBM2405I", + "severity": "E", + "message": "Even decimal precisions are not allowed under RULES(NOEVENDEC).", + "fullCode": "IBM2405IE" + } as SimplePLICode, + + /** + * In DEFAULT statements, numeric precisions should be specified only inside VALUE clauses + * . + * ```pli + * dft range(*) fixed bin(31); + * ``` + * (see page 59) + */ + IBM2406I: { + "code": "IBM2406I", + "severity": "E", + "message": "Precision outside VALUE clause will be ignored.", + "fullCode": "IBM2406IE" + } as SimplePLICode, + + /** + * In DEFAULT statements, lengths of strings should be specified only inside VALUE clauses + * . + * ```pli + * dft range(*) bit(8); + * ``` + * (see page 59) + */ + IBM2407I: { + "code": "IBM2407I", + "severity": "E", + "message": "Length outside VALUE clause will be ignored.", + "fullCode": "IBM2407IE" + } as SimplePLICode, + + /** + * In DEFAULT statements, sizes of AREAs should be specified only inside VALUE clauses + * . + * ```pli + * dft range(*) area(10000); + * ``` + * (see page 59) + */ + IBM2408I: { + "code": "IBM2408I", + "severity": "E", + "message": "AREA size outside VALUE clause will be ignored.", + "fullCode": "IBM2408IE" + } as SimplePLICode, + + /** + * All RETURN statements inside functions must specify a value to be returned. + * ```pli + * a: proc returns( fixed bin ); + * return; + * ``` + * (see page 59) + */ + IBM2409I: { + "code": "IBM2409I", + "severity": "E", + "message": "RETURN statement without an expression is invalid inside a nested PROCEDURE that specified the RETURNS attribute.", + "fullCode": "IBM2409IE" + } as SimplePLICode, + + /** + * Functions must contain at least one RETURN statement. + * (see page 59) + */ + IBM2410I: { + "code": "IBM2410I", + "severity": "E", + "message": (functionname: string) => `Function ${functionname} contains no valid RETURN statement.`, + "fullCode": "IBM2410IE" + } as ParametricPLICode, + + /** + * The STRINGOFGRAPHIC( CHARACTER ) option will be ignored if the argument contains + * any elements that are VARYING or if the argument is a NONCONNECTED slice of an array + * . + * (see page 59) + */ + IBM2411I: { + "code": "IBM2411I", + "severity": "E", + "message": "STRINGOFGRAPHIC( CHARACTER ) option is ignored because argument to STRING built-in 59 function is possibly not contiguous.", + "fullCode": "IBM2411IE" + } as SimplePLICode, + + /** + * If a procedure contains a RETURN statement, it should have the RETURNS attribute + * specified on its PROCEDURE statement. + * ```pli + * a: proc; + * return( 0 ); + * end; + * ``` + * (see page 60) + */ + IBM2412I: { + "code": "IBM2412I", + "severity": "E", + "message": "PROCEDURE has no RETURNS attribute, but contains a RETURN statement. A RETURNS attribute will be assumed.", + "fullCode": "IBM2412IE" + } as SimplePLICode, + + /** + * Attributes must be consistent. + * ```pli + * dcl a fixed based connected; + * ``` + * (see page 60) + */ + IBM2413I: { + "code": "IBM2413I", + "severity": "E", + "message": (attribute: string) => `The attribute ${attribute} should be specified only on parameters and descriptors.`, + "fullCode": "IBM2413IE" + } as ParametricPLICode, + + /** + * The specified options conflict and cannot be used together. The compiler will produce + * this message for various conflicts. For example, on ASCII systems, the compiler + * will produce this message if you specify the GRAPHIC and EBCDIC options. Conversely, + * on EBCDIC systems, the compiler will produce this message if you specify the GRAPHIC + * and ASCII options. + * (see page 60) + */ + IBM2414I: { + "code": "IBM2414I", + "severity": "E", + "message": (option: string, option2: string, option3: string) => `The ${option} option conflicts with the ${option2} option. The ${option3} option will be used instead.`, + "fullCode": "IBM2414IE" + } as ParametricPLICode, + + /** + * The indicated APAR will fix a compiler problem with this statement. + * (see page 60) + */ + IBM2415I: { + "code": "IBM2415I", + "severity": "E", + "message": (number: string) => `Without APAR ${number} , compiler would generate incorrect code for this statement.`, + "fullCode": "IBM2415IE" + } as ParametricPLICode, + + /** + * When the LINEDIR option is in effect, only the NOSEPARATE suboption of the TEST option + * is supported. + * (see page 60) + */ + IBM2416I: { + "code": "IBM2416I", + "severity": "E", + "message": "The SEPARATE suboption of TEST is not supported when the LINEDIR option is in effect.", + "fullCode": "IBM2416IE" + } as SimplePLICode, + + /** + * In FETCHABLE code, all CONTROLLED variables should be parameters. + * (see page 60) + */ + IBM2417I: { + "code": "IBM2417I", + "severity": "E", + "message": "In FETCHABLE code compiled with NORENT NOWRITABLE(PRV), it is invalid to ALLOCATE or FREE a CONTROLLED variable unless it is a PARAMETER.", + "fullCode": "IBM2417IE" + } as SimplePLICode, + + /** + * The compiler will issue this message for any level-1 variable that is not referenced + * in a particular storage class named in the RULES option: for example, AUTOMATIC + * variables under RULES(NOUNREF), BASED variables under RULES(NOUNREFBASED), etc + * (see page 60) + */ + IBM2418I: { + "code": "IBM2418I", + "severity": "E", + "message": (variable: string) => `Variable ${variable} is unreferenced.`, + "fullCode": "IBM2418IE" + } as ParametricPLICode, + + /** + * The RTCHECK option will be ignored unless the ARCH option is 8 or greater since the + * necessary instructions are available only with ARCH(8) or later. + * (see page 60) + */ + IBM2419I: { + "code": "IBM2419I", + "severity": "E", + "message": (option: string, level: string) => `${option} is invalid and ignored unless the ARCH option is ${level} or greater.`, + "fullCode": "IBM2419IE" + } as ParametricPLICode, + + /** + * The FLOAT(DFP) option will be ignored unless the ARCH option is 7 or greater since + * the necessary instructions are available only with ARCH(7) or later. + * (see page 60) + */ + IBM2420I: { + "code": "IBM2420I", + "severity": "E", + "message": "DFP is invalid and ignored unless the ARCH option is 7 or greater.", + "fullCode": "IBM2420IE" + } as SimplePLICode, + + /** + * In an ENDFILE block for a file, it is invalid to close that file in the ENDFILE block + * . + * (see page 60) + */ + IBM2421I: { + "code": "IBM2421I", + "severity": "E", + "message": "A file should not be closed in its ENDFILE block.", + "fullCode": "IBM2421IE" + } as SimplePLICode, + + /** + * Under the FLOAT(DFP) option, all FLOAT DECIMAL will be treated as DFP and may not + * be declared as HEXADEC. The attribute is still valid for FLOAT BIN. + * (see page 61) + */ + IBM2422I: { + "code": "IBM2422I", + "severity": "E", + "message": "Under the DFP option, the HEXADEC attribute is not supported for FLOAT DEC.", + "fullCode": "IBM2422IE" + } as SimplePLICode, + + /** + * Under the FLOAT(DFP) option, all FLOAT DECIMAL will be treated as DFP and may not + * be declared as IEEE. The attribute is still valid for FLOAT BIN. + * (see page 61) + */ + IBM2423I: { + "code": "IBM2423I", + "severity": "E", + "message": "Under the DFP option, the IEEE attribute is not supported for FLOAT DEC.", + "fullCode": "IBM2423IE" + } as SimplePLICode, + + /** + * Scale factors are valid only in declares of FIXED BIN or FiXED DEC. The first declaration + * below is invalid and should be changed to one of the subsequent declarations. + * ```pli + * dcl a1 float dec(15,2); + * dcl a2 fixed dec(15,2); + * dcl a3 float dec(15); + * ``` + * (see page 61) + */ + IBM2424I: { + "code": "IBM2424I", + "severity": "E", + "message": "Scale factors are not allowed in FLOAT declarations.", + "fullCode": "IBM2424IE" + } as SimplePLICode, + + /** + * Under RULES(NOELSEIF), the compiler will issue this message for statement where an + * ELSE is immediately followed by an IF statement. + * (see page 61) + */ + IBM2425I: { + "code": "IBM2425I", + "severity": "E", + "message": "Statement with ELSE IF should be rewritten using SELECT.", + "fullCode": "IBM2425IE" + } as SimplePLICode, + + /** + * The nesting of DO statements has exceeded the value specified in the DO suboption + * of the MAXNEST compiler option. + * (see page 61) + */ + IBM2426I: { + "code": "IBM2426I", + "severity": "E", + "message": "Maximum nesting of DO statements has been exceeded.", + "fullCode": "IBM2426IE" + } as SimplePLICode, + + /** + * The nesting of IF statements has exceeded the value specified in the IF suboption + * of the MAXNEST compiler option. + * (see page 61) + */ + IBM2427I: { + "code": "IBM2427I", + "severity": "E", + "message": "Maximum nesting of IF statements has been exceeded.", + "fullCode": "IBM2427IE" + } as SimplePLICode, + + /** + * The nesting of PROC and BEGIN statements has exceeded the value specified in the + * BLOCK suboption of the MAXNEST compiler option. + * (see page 61) + */ + IBM2428I: { + "code": "IBM2428I", + "severity": "E", + "message": "Maximum nesting of PROC and BEGIN statements has been exceeded.", + "fullCode": "IBM2428IE" + } as SimplePLICode, + + /** + * The use of the CMPAT(V3) option with LIMITS(FIXEDBIN(31,31)) is not supported. Since + * CMPAT(V3) will cause various built-in functions (such as HBOUND) to return a FIXED + * BIN(63) result, at least the second value in the FIXEDBIN suboption of LIMITS must + * be 63 (i.e. LIMITS(FIXEDBIN(31,63)) or LIMITS(FIXEDBIN(63,63)) must be in effect) + * . + * (see page 61) + */ + IBM2429I: { + "code": "IBM2429I", + "severity": "E", + "message": "CMPAT(V3) requires that 8-byte integers be allowed. The second value in the FIXEDBIN suboption of the LIMITS option will be set to 63.", + "fullCode": "IBM2429IE" + } as SimplePLICode, + + /** + * If the file has F format and is not a PRINT file, then the LINESIZE must be no greater + * than the RECSIZE. If the file has F format and is a PRINT file, then the LINESIZE + * must be less than the RECSIZE. If the file has V format and is not a PRINT file, + * then the LINESIZE must be no greater than the RECSIZE-4. If the file has V format + * and is a PRINT file, then the LINESIZE must be less than the RECSIZE-4. + * (see page 61) + */ + IBM2430I: { + "code": "IBM2430I", + "severity": "E", + "message": (filename: string) => `The LINESIZE value specified in the OPEN of file ${filename} is not compatible with the RECSIZE specified in its declare.`, + "fullCode": "IBM2430IE" + } as ParametricPLICode, + + /** + * The specified option is not permitted with the GOFF option, and the GOFF option will + * be turned off so that 61 the compile may proceed. This applies, for example, to + * the NOWRITABLE(PRV) and COMMON options. + * (see page 61) + */ + IBM2431I: { + "code": "IBM2431I", + "severity": "E", + "message": (option: string) => `The ${option} option conflicts with the GOFF option. NOGOFF will be used instead.`, + "fullCode": "IBM2431IE" + } as ParametricPLICode, + + /** + * The INITIAL attribute, for example, is invalid with parameters (since their storage + * will have been allocated elsewhere). + * ```pli + * dcl a fixed bin parameter initial( 0 ); + * ``` + * (see page 62) + */ + IBM2432I: { + "code": "IBM2432I", + "severity": "E", + "message": (character: string) => `The attribute ${character} is invalid with parameters and is ignored.`, + "fullCode": "IBM2432IE" + } as ParametricPLICode, + + /** + * The INITIAL attribute, for example, is invalid with DEFINED variables (since their + * storage will have been allocated elsewhere). + * ```pli + * dcl b char(1) initial( '' ) defined(a); + * ``` + * (see page 62) + */ + IBM2433I: { + "code": "IBM2433I", + "severity": "E", + "message": (attribute: string) => `The attribute ${attribute} is invalid with DEFINED and is ignored.`, + "fullCode": "IBM2433IE" + } as ParametricPLICode, + + /** + * Under RULES(NOLAXENTRY), all ENTRY declares must be prototyped. If the ENTRY should + * have no parameters, it should be declared as ENTRY() rather than as simply ENTRY + * . + * (see page 62) + */ + IBM2434I: { + "code": "IBM2434I", + "severity": "E", + "message": (name: string) => `RULES(NOLAXENTRY) violation: ${name} does not specify a parameter list.`, + "fullCode": "IBM2434IE" + } as ParametricPLICode, + + /** + * Under RULES(NOLAXSCALE), scale factors must be nonnegative, and the compiler flags + * the statement below. + * ```pli + * dcl a fixed dec(15,-2); + * ``` + * (see page 62) + */ + IBM2435I: { + "code": "IBM2435I", + "severity": "E", + "message": "RULES(NOLAXSCALE) violation: scale factor is less than 0.", + "fullCode": "IBM2435IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXSCALE), scale factors must be no larger than the precision, + * ```pli + * dcl a fixed dec(15,17); + * ``` + * (see page 62) + */ + IBM2436I: { + "code": "IBM2436I", + "severity": "E", + "message": "RULES(NOLAXSCALE) violation: scale factor is larger than the precision.", + "fullCode": "IBM2436IE" + } as SimplePLICode, + + /** + * If the SQL preprocessor is invoked more than once without INCONLY as its suboption, + * then the DBRM library member created for the compile will be empty. It is best to + * invoke the SQL preprocessor either only once or once with INCONLY as its only suboption + * and then only once more. + * (see page 62) + */ + IBM2437I: { + "code": "IBM2437I", + "severity": "E", + "message": "SQL preprocessor invoked more than once without INCONLY.", + "fullCode": "IBM2437IE" + } as SimplePLICode, + + /** + * Under RULES(NOSTOP), there should be no STOP and no EXIT statements in your source + * program. + * (see page 62) + */ + IBM2438I: { + "code": "IBM2438I", + "severity": "E", + "message": "STOP and EXIT statements are not allowed.", + "fullCode": "IBM2438IE" + } as SimplePLICode, + + /** + * Under RULES(NOPROCENDONLY), the END statement for a PROCEDURE must not consist of + * simply the END keyword and a semicolon. It must also include the name of the PROCEDURE + * it is closing. + * (see page 62) + */ + IBM2439I: { + "code": "IBM2439I", + "severity": "E", + "message": "RULES(NOPROCENDONLY) violation: END statement for a PROCEDURE must include the name of the PROCEDURE.", + "fullCode": "IBM2439IE" + } as SimplePLICode, + + /** + * Under the option RULES(NOLAXQUAL), all structure elements should be qualified with + * the name of their outermost parent. + * (see page 62) + */ + IBM2440I: { + "code": "IBM2440I", + "severity": "E", + "message": (identifier: string) => `RULES(NOLAXQUAL) violation: structure element ${identifier} is not qualified with the name of its containing level 1 structure.`, + "fullCode": "IBM2440IE" + } as ParametricPLICode, + + /** + * Under RULES(NOGOTO(LOOSE)) and RULES(NOGOTO(LOOSEFORWARD)), there should be no GOTO + * statements in your source program except 62 for those that exit an ON-unit and + * those that goto a label in the current block. + * (see page 62) + */ + IBM2441I: { + "code": "IBM2441I", + "severity": "E", + "message": "RULES(NOGOTO) violation: GOTO exits the current block.", + "fullCode": "IBM2441IE" + } as SimplePLICode, + + /** + * Under RULES(NOPADDING), structures should contain no padding. + * (see page 63) + */ + IBM2442I: { + "code": "IBM2442I", + "severity": "E", + "message": (identifier: string) => `RULES(NOPADDING) violation: structure ${identifier} contains padding.`, + "fullCode": "IBM2442IE" + } as ParametricPLICode, + + /** + * Under RULES(NOGLOBALDO), in a DO loop of the form DO x = .., x must be declared in + * the same block as the DO loop. + * (see page 63) + */ + IBM2443I: { + "code": "IBM2443I", + "severity": "E", + "message": "RULES(NOGLOBALDO) violation: control variable in DO statement belongs to a parent block.", + "fullCode": "IBM2443IE" + } as SimplePLICode, + + /** + * The named built-in function was specified in the BUILTIN suboption of the DEPRECATE + * option, and so any explicit or contextual declaration of it is flagged. + * (see page 63) + */ + IBM2444I: { + "code": "IBM2444I", + "severity": "E", + "message": (builtin: string) => `The built-in function ${builtin} has been deprecated.`, + "fullCode": "IBM2444IE" + } as ParametricPLICode, + + /** + * The named INCLUDE file was specified in the INCLUDE suboption of the DEPRECATE option, + * and so any attempt to include it is flagged. + * (see page 63) + */ + IBM2445I: { + "code": "IBM2445I", + "severity": "E", + "message": (filename: string) => `The INCLUDE file ${filename} has been deprecated.`, + "fullCode": "IBM2445IE" + } as ParametricPLICode, + + /** + * The named ENTRY was specified in the ENTRY suboption of the DEPRECATE option, and + * so any explicit or contextual declaration of it is flagged. + * (see page 63) + */ + IBM2446I: { + "code": "IBM2446I", + "severity": "E", + "message": (variable: string) => `The ENTRY named ${variable} has been deprecated.`, + "fullCode": "IBM2446IE" + } as ParametricPLICode, + + /** + * The named VARIABLE was specified in the VARIABLE suboption of the DEPRECATE option, + * and so any explicit or contextual declaration of it is flagged. + * (see page 63) + */ + IBM2447I: { + "code": "IBM2447I", + "severity": "E", + "message": (variable: string) => `The VARIABLE named ${variable} has been deprecated.`, + "fullCode": "IBM2447IE" + } as ParametricPLICode, + + /** + * If the CICS preprocessor were invoked more than once, then the second invocation + * would cause duplicate declarations to be inserted in the outermost procedure. The + * CICS preprocessor must be invoked only once. The compiler ignores any excess invocations + * . + * (see page 63) + */ + IBM2448I: { + "code": "IBM2448I", + "severity": "E", + "message": "CICS preprocessor invoked more than once.", + "fullCode": "IBM2448IE" + } as SimplePLICode, + + /** + * Under RULES(NOSELFASSIGN), the source and target in an assignment must be different + * . + * (see page 63) + */ + IBM2449I: { + "code": "IBM2449I", + "severity": "E", + "message": "RULES(NOSELFASSIGN) violation: source and target in assignment are identical.", + "fullCode": "IBM2449IE" + } as SimplePLICode, + + /** + * The argument to the named built-in function is too short. For example, the argument + * to the Y4DATE built-in function should have the form YYMMDD with possibly some trailing + * blanks, and hence the length of that argument should be greater than or equal to + * 6. + * (see page 63) + */ + IBM2450I: { + "code": "IBM2450I", + "severity": "E", + "message": (BUILTINname: string, length: string) => `First argument to ${BUILTINname} built-in function should have length greater than or equal to ${length} .`, + "fullCode": "IBM2450IE" + } as ParametricPLICode, + + /** + * Under RULES(NOLAXIF), if the target in an assignment is not BIT(1), the assignment + * is flagged if the source is a Boolean. So, for example, the first assignment below + * is correct, but RULES(NOLAXIF) flags the second assignment since the third assignment + * might be what was intended. + * ```pli + * x = (y = z); + * x = y = z; + * x, y = z; + * ``` + * (see page 63) + */ + IBM2451I: { + "code": "IBM2451I", + "severity": "E", + "message": "RULES(NOLAXIF) violation: source in the assignment is a Boolean, but the target is not BIT(1).", + "fullCode": "IBM2451IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXSCALE), scale factors must be nonnegative. The compiler flags the + * first statement below, but not the second one (which is a possible replacement for + * the first). 63 + * ```pli + * b = round( c, -1 ); + * b = 10 * round( c\/ 10, 0 ); + * ``` + * (see page 63) + */ + IBM2452I: { + "code": "IBM2452I", + "severity": "E", + "message": "RULES(NOLAXSCALE) violation: scale factor is less than 0.", + "fullCode": "IBM2452IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXNESTED), all executable code in a procedure must come in one group + * of statements with all nested subprocedures and nested BEGIN blocks surrounding + * that group of statements. + * (see page 64) + */ + IBM2453I: { + "code": "IBM2453I", + "severity": "E", + "message": "RULES(NOLAXNESTED) violation: code should come in one group of statements with no intervening procedures or BEGIN blocks.", + "fullCode": "IBM2453IE" + } as SimplePLICode, + + /** + * The named statement was specified in the STMT suboption of the DEPRECATE option, + * and so any use of that statement is flagged. + * (see page 64) + */ + IBM2454I: { + "code": "IBM2454I", + "severity": "E", + "message": (builtin: string) => `The ${builtin} statement has been deprecated.`, + "fullCode": "IBM2454IE" + } as ParametricPLICode, + + /** + * The named keyword does not follow the case rules specified in the KEYWORD suboption + * of the CASERULES option. + * (see page 64) + */ + IBM2455I: { + "code": "IBM2455I", + "severity": "E", + "message": (builtin: string) => `The ${builtin} keyword does not conform to the CASERULES option.`, + "fullCode": "IBM2455IE" + } as ParametricPLICode, + + /** + * Under RULES(NORECURSIVE), the RECURSIVE attribute should not be used and procedures + * should not call themselves. + * (see page 64) + */ + IBM2456I: { + "code": "IBM2456I", + "severity": "E", + "message": "RULES(NORECURSIVE) violation: RECURSIVE PROCEDUREs are not allowed under RULES(NORECURSIVE).", + "fullCode": "IBM2456IE" + } as SimplePLICode, + + /** + * If you want to use DFT(RECURSIVE), then RULES(RECURSIVE) should also be used. If + * RULES(NORECURSIVE) is more important, then DFT(NONRECURSIVE) should be used. + * (see page 64) + */ + IBM2457I: { + "code": "IBM2457I", + "severity": "E", + "message": "RULES(NORECURSIVE) conflicts with DFT(RECURSIVE). The compiler will apply RULES(RECURSIVE) instead.", + "fullCode": "IBM2457IE" + } as SimplePLICode, + + /** + * Under RULES(NOCONTROLLED), the CONTROLLED attribute must not be used. + * (see page 64) + */ + IBM2458I: { + "code": "IBM2458I", + "severity": "E", + "message": "The CONTROLLED attribute is not allowed under RULES(NOCONTROLLED).", + "fullCode": "IBM2458IE" + } as SimplePLICode, + + /** + * Under the ENCODING(UTF8) option, the characters specified in the OR, NOT, QUOTE, + * and BLANK compiler options must all be one-byte UTF-8 characters. + * (see page 64) + */ + IBM2459I: { + "code": "IBM2459I", + "severity": "E", + "message": (option: string) => `The characters specified in the ${option} option must all have hexadecimal values less than 80.`, + "fullCode": "IBM2459IE" + } as ParametricPLICode, + + /** + * The specified options conflict and cannot be used together. The ENCODING(UTF8) option + * cannot be used with the SOSI, DBCS or GRAPHIC options. + * (see page 64) + */ + IBM2460I: { + "code": "IBM2460I", + "severity": "E", + "message": (option: string) => `The ${option} option conflicts with the ENCODING(UTF8) option. ENCODING(ASCII) will be assumed.`, + "fullCode": "IBM2460IE" + } as ParametricPLICode, + + /** + * Under the ENCODING(UTF8) option, the MARGINI option must be a one-character UTF-8 + * string. If not, a blank will be used instead. + * (see page 64) + */ + IBM2461I: { + "code": "IBM2461I", + "severity": "E", + "message": "The MARGINI option must specify a valid UTF-8 string consisting of one UTF-8 character.", + "fullCode": "IBM2461IE" + } as SimplePLICode, + + /** + * Attributes must be consistent. + * ```pli + * dcl a parameter static; + * ``` + * (see page 64) + */ + IBM2462I: { + "code": "IBM2462I", + "severity": "E", + "message": (character: string, character2: string) => `The attribute ${character} conflicts with the attribute ${character2} and is ignored.`, + "fullCode": "IBM2462IE" + } as ParametricPLICode, + + /** + * Under 64-bit, only the OPTLINK linkage is supported for PL\/I procedures + * (see page 64) + */ + IBM2463I: { + "code": "IBM2463I", + "severity": "E", + "message": "LINKAGE(SYSTEM) is not supported for PL/I PROCEDUREs, and LINKAGE(OPTLINK) will be assumed instead.", + "fullCode": "IBM2463IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXSTMT), there should be only one statement per line. + * (see page 65) + */ + IBM2464I: { + "code": "IBM2464I", + "severity": "E", + "message": "RULES(NOLAXSTMT) violation: line contains more than one statement.", + "fullCode": "IBM2464IE" + } as SimplePLICode, + + /** + * Under DEFAULT(NULLSTRPTR(STRICT)), such assignments are invalid. + * (see page 65) + */ + IBM2465I: { + "code": "IBM2465I", + "severity": "E", + "message": "Assignment of a null string to a pointer is invalid.", + "fullCode": "IBM2465IE" + } as SimplePLICode, + + /** + * Under DEFAULT(NULLSTRPTR(STRICT)), such comparisons are invalid. + * (see page 65) + */ + IBM2466I: { + "code": "IBM2466I", + "severity": "E", + "message": "Comparison of a null string to a pointer is invalid.", + "fullCode": "IBM2466IE" + } as SimplePLICode, + + /** + * Under RULES(NOYY), the use of date patterns with a 2-digit year is invalid. + * (see page 65) + */ + IBM2467I: { + "code": "IBM2467I", + "severity": "E", + "message": "RULES(NOYY) conflicts with use of a date pattern with a 2-digit year.", + "fullCode": "IBM2467IE" + } as SimplePLICode, + + /** + * Under RULES(NOYY), the use of date patterns with a ZY is invalid. + * (see page 65) + */ + IBM2468I: { + "code": "IBM2468I", + "severity": "E", + "message": "RULES(NOYY) conflicts with use of a date pattern with a ZY.", + "fullCode": "IBM2468IE" + } as SimplePLICode, + + /** + * Under RULES(NOYY), the use of the DATE attribute without a pattern is invalid since + * it implies a pattern of YYMMDD. + * (see page 65) + */ + IBM2469I: { + "code": "IBM2469I", + "severity": "E", + "message": "RULES(NOYY) conflicts with use of the DATE attribute without a pattern.", + "fullCode": "IBM2469IE" + } as SimplePLICode, + + /** + * Under RULES(NOYY), the use of any of the Y4 date built-in functions is invalid. + * (see page 65) + */ + IBM2470I: { + "code": "IBM2470I", + "severity": "E", + "message": (BUILTINname: string) => `RULES(NOYY) conflicts with use of the ${BUILTINname} built-in function.`, + "fullCode": "IBM2470IE" + } as ParametricPLICode, + + /** + * Under RULES(NOYY), the use of any date built-in function with a window argument is + * invalid. + * (see page 65) + */ + IBM2471I: { + "code": "IBM2471I", + "severity": "E", + "message": (BUILTINname: string) => `RULES(NOYY) conflicts with use of the ${BUILTINname} built-in function with a window argument.`, + "fullCode": "IBM2471IE" + } as ParametricPLICode, + + /** + * Under RULES(NOYY), the use of the DATE built-in functions is invalid since it will + * return a 2-digit year. + * (see page 65) + */ + IBM2472I: { + "code": "IBM2472I", + "severity": "E", + "message": "RULES(NOYY) conflicts with use of the DATE built-in function.", + "fullCode": "IBM2472IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXINTERFACE), if there is a PACKAGE statement, then every external + * PROCEDURE other than MAIN must be declared. + * (see page 65) + */ + IBM2473I: { + "code": "IBM2473I", + "severity": "E", + "message": (procname: string) => `RULES(NOLAXINTERFACE) violation: ${procname} has not been explicitly declared.`, + "fullCode": "IBM2473IE" + } as ParametricPLICode, + + /** + * Under RULES(NOGOTO(LOOSEFORWARD)), there should be no GOTO statements in your source + * program except for those that exit an ON-unit and those that goto a label on a later + * line in the current block. + * (see page 65) + */ + IBM2474I: { + "code": "IBM2474I", + "severity": "E", + "message": "RULES(NOGOTO) violation: GOTO jumps to a previous line in the current block.", + "fullCode": "IBM2474IE" + } as SimplePLICode, + + /** + * Under RULES(NOMULTISEMI), there should be only one semicolon on a line. + * (see page 65) + */ + IBM2475I: { + "code": "IBM2475I", + "severity": "E", + "message": "RULES(NOMULTISEMI) violation: line contains too many semicolons.", + "fullCode": "IBM2475IE" + } as SimplePLICode, + + /** + * The indicated element of the options list is invalid for ON-unit BEGIN blocks (although + * it may be valid for other BEGIN blocks). 65 + * ```pli + * on zdiv begin options( inline ); + * ``` + * (see page 65) + */ + IBM2476I: { + "code": "IBM2476I", + "severity": "E", + "message": "Item in OPTIONS list is invalid for ON-unit BEGIN blocks. ${option name } is ignored.", + "fullCode": "IBM2476IE" + } as SimplePLICode, + + /** + * Under RULES(NOCOMPLEX), the COMPLEX attributes, the COMPLEX built-in function, and + * \"imaginary\" constants (such as 1i) must not be used. + * (see page 66) + */ + IBM2478I: { + "code": "IBM2478I", + "severity": "E", + "message": "Under RULES(NOCOMPLEX), the COMPLEX attribute, the COMPLEX built-in function, and constants ending with the I suffix are not allowed.", + "fullCode": "IBM2478IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXPACKAGE), every compilation unti must contain a PACKAGE statement + * . + * (see page 66) + */ + IBM2479I: { + "code": "IBM2479I", + "severity": "E", + "message": "RULES(NOLAXPACKAGE) violation: compilation unit does not contain a PACKAGE statement.", + "fullCode": "IBM2479IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXEXPORTS), every PACKAGE that contains procedures must have an EXPORTS + * clause that names the routines it exports. + * (see page 66) + */ + IBM2480I: { + "code": "IBM2480I", + "severity": "E", + "message": "RULES(NOLAXEXPORTS) violation: package contains PROCEDUREs but no EXPORTS clause naming specifically which PROCEDUREs are exported.", + "fullCode": "IBM2480IE" + } as SimplePLICode, + + /** + * Under RULES(NOLAXSCALE(STRICT)), scale factors for FIXED BIN must be zero. The compiler + * uses other messages to flag negative scale factors and scale factors greater than + * the precision, but it uses this message to flag all other positive scale factors + * such as in the statement below. + * ```pli + * dcl a fixed bin(15,2); + * ``` + * (see page 66) + */ + IBM2481I: { + "code": "IBM2481I", + "severity": "E", + "message": "RULES(NOLAXSCALE) violation: scale factor is greater than 0.", + "fullCode": "IBM2481IE" + } as SimplePLICode, + + /** + * If the RULES(NOLAXPARMS) option is in effect, The compiler will issue this message + * for any level-1 paramter declared without specifying if it is an input, an output + * or both. + * (see page 66) + */ + IBM2482I: { + "code": "IBM2482I", + "severity": "E", + "message": (variable: string) => `RULES(NOLAXPARMS) violation: Parameter ${variable} is declared without INONLY, OUTONLY, or INOUT.`, + "fullCode": "IBM2482IE" + } as ParametricPLICode, + + /** + * Under RULES(NOPADDING(STRICT)), structures should contain no hang. + * (see page 66) + */ + IBM2483I: { + "code": "IBM2483I", + "severity": "E", + "message": (identifier: string, count: string, count2: string) => `RULES(NOPADDING) violation: the structure ${identifier} is ${count} -byte aligned, but does not have a multiple of ${count2} bytes before its first element with that alignment.`, + "fullCode": "IBM2483IE" + } as ParametricPLICode, + + /** + * Under RULES(NOPADDING(STRICT)), structures should contain no hang. + * (see page 66) + */ + IBM2484I: { + "code": "IBM2484I", + "severity": "E", + "message": (identifier: string) => `RULES(NOPADDING) violation: the structure ${identifier} does not have a multiple of 8 bits before its first element with byte (or greater) alignment.`, + "fullCode": "IBM2484IE" + } as ParametricPLICode, + + /** + * Under RULES(NOPADDING(STRICT)), structures should contain no padding. + * (see page 66) + */ + IBM2485I: { + "code": "IBM2485I", + "severity": "E", + "message": (identifier: string) => `RULES(NOPADDING) violation: the size of the structure ${identifier} is not a multiple of its alignment.`, + "fullCode": "IBM2485IE" + } as ParametricPLICode, + + /** + * Under RULES(NOPADDING(STRICT)), structures should contain no hang. + * (see page 66) + */ + IBM2486I: { + "code": "IBM2486I", + "severity": "E", + "message": (identifier: string) => `RULES(NOPADDING) violation: the structure ${identifier} does not have a multiple of 8 bits after its last element with byte (or greater) alignment.`, + "fullCode": "IBM2486IE" + } as ParametricPLICode, + + /** + * Under RULES(NOPADDING(STRICT)), structures should contain no hang. + * (see page 66) + */ + IBM2487I: { + "code": "IBM2487I", + "severity": "E", + "message": (identifier: string) => `RULES(NOPADDING) violation: the structure ${identifier} does not contain a multiple of 8 bits.`, + "fullCode": "IBM2487IE" + } as ParametricPLICode, + + /** + * Under RULES(IBM), when an arithmetic operation has an operand that is FIXED BIN and + * an operand that is FIXED DEC with a non-zero scale factor, then the FIXED DEC operand + * will be converted to FIXED BIN. Under RULES(NOLAXSCALE(STRICT)), this is flagged + * as an error. + * (see page 66) + */ + IBM2489I: { + "code": "IBM2489I", + "severity": "E", + "message": (sourceprecision: string, sourcescale: string, targetprecision: string, targetscale: string, resultprecision: string, resultscale: string) => `RULES(NOLAXSCALE) violation: FIXED DEC( ${sourceprecision} , ${sourcescale} ) operand 66 will be converted to FIXED BIN( ${targetprecision} , ${targetscale} ). This introduces a non-zero scale factor into an integer operation and will produce a result with the attributes FIXED BIN( ${resultprecision} , ${resultscale} ).`, + "fullCode": "IBM2489IE" + } as ParametricPLICode, + + /** + * When assigning to a target with the VALUERANGE attribute, the source must have a + * value in that range. + * (see page 67) + */ + IBM2490I: { + "code": "IBM2490I", + "severity": "E", + "message": "Source in assignment does not fit in the the VALUERANGE of the target.", + "fullCode": "IBM2490IE" + } as SimplePLICode, + + /** + * When assigning to a target with the VALUELIST attribute, the source must have a value + * in that list. + * (see page 67) + */ + IBM2491I: { + "code": "IBM2491I", + "severity": "E", + "message": "Source in assignment does not occur in the the VALUELIST of the target.", + "fullCode": "IBM2491IE" + } as SimplePLICode, + + /** + * If the RULES(NOGLOBAL) option is in effect, the compiler will issue this message + * for variables that are used in a procedure that is nested inside the procedure in + * which they were declared. + * (see page 67) + */ + IBM2492I: { + "code": "IBM2492I", + "severity": "E", + "message": (variable: string) => `RULES(NOGLOBAL) violation: Variable ${variable} is used inside a nested PROCEDURE.`, + "fullCode": "IBM2492IE" + } as ParametricPLICode, + + /** + * If the RULES(NOLAXOPTIONAL) option is in effect, the compiler will enforce the rule + * that arguments to the PRESENT or OMITTED built-in functions should have the OPTIONAL + * attribute. + * (see page 67) + */ + IBM2493I: { + "code": "IBM2493I", + "severity": "E", + "message": (variable: string, BUILTINname: string) => `RULES(NOLAXOPTIONAL) violation: Variable ${variable} is used as an argument to the ${BUILTINname} function, but does not have the OPTIONAL attribute.`, + "fullCode": "IBM2493IE" + } as ParametricPLICode, + + /** + * Under the option RULES(NOLAXQUAL(FULL)), all structure elements should be qualified + * with the names of all their parents. + * (see page 67) + */ + IBM2494I: { + "code": "IBM2494I", + "severity": "E", + "message": (identifier: string) => `RULES(NOLAXQUAL) violation: Structure element ${identifier} is not fully qualified.`, + "fullCode": "IBM2494IE" + } as ParametricPLICode, + + /** + * Given SUBTO(x,i,j), then j >= (i-1) must be true. Otherwise the STRINGRANGE condition + * would be raised. + * (see page 67) + */ + IBM2495I: { + "code": "IBM2495I", + "severity": "E", + "message": (BUILTINname: string) => `Third argument in ${BUILTINname} reference is too small. It will be replaced by the value of the second argument minus 1.`, + "fullCode": "IBM2495IE" + } as ParametricPLICode, + + /** + * It would be better to replace an IF expression of the form ( a = y1 | a = y2 | ... + * | a = yn ) with the expression INLIST( a, y1, y2, ..., yn ). This would be less + * likely to contain errors and more likely to be optimized. + * (see page 67) + */ + IBM2499I: { + "code": "IBM2499I", + "severity": "E", + "message": (count: string) => `MAXRUNONIF limit exceeded: IF statement tests an expression that consists of ${count} comparisons of the same reference against a series of constant values. The expression could be replaced by one INLIST reference.`, + "fullCode": "IBM2499IE" + } as ParametricPLICode, + + /** + * It would be better to replace an IF expression of the form ( a = y1 | a = y2 | ... + * | a = yn ) with the expression SELECT( a ); WHEN( y1, y2, ..., yn ) ... This would + * be less likely to contain errors and more likely to be optimized. + * (see page 67) + */ + IBM2500I: { + "code": "IBM2500I", + "severity": "E", + "message": (count: string) => `MAXRUNONIF limit exceeded: IF statement tests an expression that consists of ${count} comparisons of the same reference against a series of constant values. The statement could be replaced by a SELECT statement containing one large WHEN statement.`, + "fullCode": "IBM2500IE" + } as ParametricPLICode, + + /** + * The only supported ALIGNED values are 1, 2, 4, and 8. 67 + * ```pli + * dcl a char(256) aligned(32); + * ``` + * (see page 67) + */ + IBM2501I: { + "code": "IBM2501I", + "severity": "E", + "message": "Alignment value is invalid and will be ignored.", + "fullCode": "IBM2501IE" + } as SimplePLICode, + + /** + * If the CMPAT compiler option specifies, for example, V2, then the CMPAT suboption + * in the OPTIONS attribute on the PROCEDURE must also specify V2. + * (see page 68) + */ + IBM2502I: { + "code": "IBM2502I", + "severity": "E", + "message": (optionvalue: string, suboptionvalue: string) => `The compiler option CMPAT specifies V ${optionvalue} but the CMPAT suboption in the OPTIONS attribute specifies V ${suboptionvalue} . These values should match.`, + "fullCode": "IBM2502IE" + } as ParametricPLICode, + + /** + * Under RULES(NOLAXENTRY), all ENTRY declares must be prototyped. If the ENTRY should + * have no parameters, it should be declared as ENTRY() rather than as simply ENTRY + * . + * (see page 68) + */ + IBM2503I: { + "code": "IBM2503I", + "severity": "E", + "message": (name: string) => `RULES(NOLAXENTRY) violation: ${name} has a parameter with the ENTRY attribute but which does not specify a parameter list.`, + "fullCode": "IBM2503IE" + } as ParametricPLICode, + + /** + * %PROCINC statements must have a file name and a semicolon on the same line as the + * %PROCINC keyword. + * (see page 68) + */ + IBM2504I: { + "code": "IBM2504I", + "severity": "E", + "message": "PROCINC syntax is invalid.", + "fullCode": "IBM2504IE" + } as SimplePLICode, + + /** + * %PROCINC files must not contain any blank lines or any code. + * (see page 68) + */ + IBM2505I: { + "code": "IBM2505I", + "severity": "E", + "message": "PROCINC files must include only PROCESS and PROCINC statements.", + "fullCode": "IBM2505IE" + } as SimplePLICode, + + /** + * Unless an ENTRY has the LIMITED attribute, it must be passed BYADDR. + * (see page 68) + */ + IBM2506I: { + "code": "IBM2506I", + "severity": "E", + "message": "Only LIMITED ENTRY may be passed BYVALUE. All other ENTRY must be passed BYADDR.", + "fullCode": "IBM2506IE" + } as SimplePLICode, + + /** + * You should recode such statements to avoid this restriction. The compiler will not + * support for the use of the BINARY built-in function in the following code. It would + * accept this code if the DECIMAL built-in function was used instead. + * ```pli + * dcl (x,y) fixed bin(15,0); + * put list( bin(x,31,2) ); + * ``` + * (see page 68) + */ + IBM2507I: { + "code": "IBM2507I", + "severity": "E", + "message": (BUILTINname: string, precision: string, scalefactor: string) => `Tne result of the ${BUILTINname} built-in would have the attributes FIXED BIN( ${precision} , ${scalefactor} ), but FIXED BIN scale factors must be between zero and the specified precision. The scale factor will be adjusted to fit.`, + "fullCode": "IBM2507IE" + } as ParametricPLICode, + + /** + * FIXED BIN declares with a negative scale factor or with a scale factor greater than + * the precision are invalid. The scale factor will be changed to fit. + * (see page 68) + */ + IBM2508I: { + "code": "IBM2508I", + "severity": "E", + "message": "In FIXED BIN(p,q) declares q must be between 0 and p (inclusive).", + "fullCode": "IBM2508IE" + } as SimplePLICode, + + /** + * The ROUND and similar built-in functions must not be applied to FIXED BIN (or BIT) + * arguments. + * (see page 68) + */ + IBM2509I: { + "code": "IBM2509I", + "severity": "E", + "message": "Support for ROUND of fixed binary expressions is deprecated and will be withdrawn in the next release.", + "fullCode": "IBM2509IE" + } as SimplePLICode, + + /** + * CEIL, FLOOR, and TRUNC of an expression x that has the attributes FIXED BIN is somewhat + * meaningless except when either x has a positive scale factor or x is a quotient + * (y\/z) where y is unscaled FIXED BIN and z is unscaled FIXED. + * (see page 68) + */ + IBM2510I: { + "code": "IBM2510I", + "severity": "E", + "message": (BUILTINname: string) => `In ${BUILTINname} of FIXED BIN(p,q), q should be greater than 0.`, + "fullCode": "IBM2510IE" + } as ParametricPLICode, + + /** + * This message can occur in a multiply of x by y if the sum of the scale factors of + * x and y is too large. To eliminate this message, the PRECISION built-in function + * could be used to reduce the scale factor of one of the operands or the MULTIPLY + * built-in function could be used to override the default attributes for the result + * . + * (see page 68) + */ + IBM2511I: { + "code": "IBM2511I", + "severity": "E", + "message": (operandattributes: string, operandattributes2: string, resultattributes: string) => `The operands in a multiplication operation have the attributes ${operandattributes} and ${operandattributes2} which will produce a result with the attributes ${resultattributes} . This means that its scale factor is greater than its precision! That may lead to the loss of significant digits and unexpected results. You may be able to avoid this problem by reducing the the scale factor of 68 one of the operands or by using the MULTIPLY built-in function.`, + "fullCode": "IBM2511IE" + } as ParametricPLICode, + + /** + * This message can occur in a divide of x by y if the scale factor of y is greater + * than the scale factor of x, for example if x has the attributes FIXED BIN(31,0) + * and y is a FIXED DEC with a factional part. To eliminate this message, the PRECISION + * built-in function could be used to change the scale factor of the operands or the + * DIVIDE built-in function could be used to override the default attributes for the + * result. + * (see page 69) + */ + IBM2512I: { + "code": "IBM2512I", + "severity": "E", + "message": (operandattributes: string, operandattributes2: string, resultattributes: string) => `The operands in a division operation have the attributes ${operandattributes} and ${operandattributes2} which will produce a result with the attributes ${resultattributes} . This means that its scale factor is negative! That may lead to the loss of significant digits and unexpected results. You may be able to avoid this problem by changing the the scale factor of the divisor (for example, if the divisor is the constant 100.0, by changing it to 100) or by using the DIVIDE built-in function.`, + "fullCode": "IBM2512IE" + } as ParametricPLICode +}; + +export const Severe = { + + /** + * An argument must have a type that can be converted to the corresponding parameter's + * type. + * (see page 71) + */ + IBM1500I: { + "code": "IBM1500I", + "severity": "S", + "message": (argumentnumber: string, ENTRYname: string, sourcetype: string, targettype: string) => `Argument number ${argumentnumber} in ENTRY reference ${ENTRYname} has type ${sourcetype} , which is invalid for a parameter with type ${targettype} .`, + "fullCode": "IBM1500IS" + } as ParametricPLICode, + + /** + * If a parameter is strongly typed, any argument passed to it must have the same type + * . + * (see page 71) + */ + IBM1501I: { + "code": "IBM1501I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } has a different strong type than the corresponding parameter.", + "fullCode": "IBM1501IS" + } as SimplePLICode, + + /** + * An argument must have a type that can be converted to the corresponding parameter's + * type. + * (see page 71) + */ + IBM1502I: { + "code": "IBM1502I", + "severity": "S", + "message": (argumentnumber: string, ENTRYname: string, sourcetype: string, targettype: string) => `Argument number ${argumentnumber} in ENTRY reference ${ENTRYname} has type ${sourcetype} , which is invalid for a parameter with type ${targettype} . If the ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1502IS" + } as ParametricPLICode, + + /** + * Only an EXTERNAL ENTRY CONSTANT, an ENTRY CONSTANT representing a non-nested PROCEDURE, + * or an ENTRY VARIABLE with the LIMITED attribute can be passed to a LIMITED ENTRY + * parameter. + * (see page 71) + */ + IBM1503I: { + "code": "IBM1503I", + "severity": "S", + "message": (argumentnumber: string, ENTRYname: string, sourcetype: string) => `Argument number ${argumentnumber} in ENTRY reference ${ENTRYname} has type ${sourcetype} , which is invalid for a parameter with type LIMITED ENTRY.`, + "fullCode": "IBM1503IS" + } as ParametricPLICode, + + /** + * POINTER expressions can be converted to OFFSET only if the OFFSET is declared with + * an AREA qualifier. + * (see page 71) + */ + IBM1504I: { + "code": "IBM1504I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } has type POINTER, which is invalid for an OFFSET parameter without an AREA qualifier.", + "fullCode": "IBM1504IS" + } as SimplePLICode, + + /** + * OFFSET variables can be converted to POINTER only if the OFFSET is declared with + * an AREA qualifier. + * (see page 71) + */ + IBM1505I: { + "code": "IBM1505I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } has type POINTER, which is invalid for a POINTER parameter since the OFFSET argument is not an OFFSET variable declared with an AREA qualifier.", + "fullCode": "IBM1505IS" + } as SimplePLICode, + + /** + * ORDINALs cannot be passed to other ORDINALs having different ORDINAL types. + * (see page 71) + */ + IBM1506I: { + "code": "IBM1506I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } has a different ORDINAL type than the corresponding parameter.", + "fullCode": "IBM1506IS" + } as SimplePLICode, + + /** + * The array can be assigned to an array of LABEL variables, and that array can be passed + * . + * ```pli + * lx(1): ... ; + * lx(2): ... ; + * call x( lx ); + * ``` + * (see page 71) + */ + IBM1507I: { + "code": "IBM1507I", + "severity": "S", + "message": "Arrays of label constants may not be passed as arguments.", + "fullCode": "IBM1507IS" + } as SimplePLICode, + + /** + * The number of arguments must match the number of parameters in the ENTRY declaration + * . + * (see page 71) + */ + IBM1508I: { + "code": "IBM1508I", + "severity": "S", + "message": "Too few arguments have been specified for the ENTRY ${ENTRY name } .", + "fullCode": "IBM1508IS" + } as SimplePLICode, + + /** + * The target in an assignment through a pseudovariable must not have the NONASSIGNABLE + * attribute. + * ```pli + * dcl a static nonasgn char(7) + * init('example'); + * unspec(a) = ''b; + * ``` + * (see page 71) + */ + IBM1509I: { + "code": "IBM1509I", + "severity": "S", + "message": (variablename: string) => `Argument to ${variablename} pseudovariable must be ASSIGNABLE.`, + "fullCode": "IBM1509IS" + } as ParametricPLICode, + + /** + * The target in an assignment through a pseudovariable must not have the NONASSIGNABLE + * attribute. + * ```pli + * dcl a static nonasgn char(7) + * init('example'); + * substr(a,1,2) = 'tr'; + * ``` + * (see page 72) + */ + IBM1510I: { + "code": "IBM1510I", + "severity": "S", + "message": "First argument to ${variable name } pseudovariable must be ASSIGNABLE.", + "fullCode": "IBM1510IS" + } as SimplePLICode, + + /** + * Scalars cannot be converted to aggregates. + * ```pli + * dcl a entry( fixed bin ), b(10) fixed bin; + * call a( b ); + * ``` + * (see page 72) + */ + IBM1511I: { + "code": "IBM1511I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is an aggregate, but the parameter description specifies a scalar.", + "fullCode": "IBM1511IS" + } as SimplePLICode, + + /** + * Dummy aggregate arguments are not supported except when passing a non-AREA scalar + * to a non- CONTROLLED array of scalars, and the array must have no bounds specified + * as *. The scalar can be assigned to an aggregate, and that aggregate can be passed + * . + * ```pli + * dcl a entry( 1, 2 fixed bin, 2 fixed bin ); + * call a( 0 ); + * ``` + * (see page 72) + */ + IBM1512I: { + "code": "IBM1512I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is a scalar, but the parameter description specifies an aggregate to which it cannot be passed.", + "fullCode": "IBM1512IS" + } as SimplePLICode, + + /** + * Dummy aggregate arguments are not supported. If an entry description describes an + * aggregate parameter, then any argument passed must match that parameter's description + * . + * (see page 72) + */ + IBM1513I: { + "code": "IBM1513I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is an aggregate that does not exactly match the corresponding parameter description.", + "fullCode": "IBM1513IS" + } as SimplePLICode, + + /** + * Dummy aggregate arguments are not supported. If an entry description describes an + * aggregate parameter, then any argument passed must match that parameter's description + * . + * (see page 72) + */ + IBM1514I: { + "code": "IBM1514I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is an aggregate with more members than its corresponding parameter description.", + "fullCode": "IBM1514IS" + } as SimplePLICode, + + /** + * Dummy aggregate arguments are not supported. If an entry description describes an + * aggregate parameter, then any argument passed must match that parameter's description + * . + * (see page 72) + */ + IBM1515I: { + "code": "IBM1515I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is an aggregate with fewer members than its corresponding parameter description.", + "fullCode": "IBM1515IS" + } as SimplePLICode, + + /** + * Dummy aggregate arguments are not supported. If an entry description describes an + * aggregate parameter, then any argument passed must match that parameter's description + * . + * (see page 72) + */ + IBM1516I: { + "code": "IBM1516I", + "severity": "S", + "message": (argumentnumber: string, ENTRYname: string) => `The number of dimensions in the subelements of argument number ${argumentnumber} in ENTRY reference ${ENTRYname} and in its corresponding parameter description do not match.`, + "fullCode": "IBM1516IS" + } as ParametricPLICode, + + /** + * Dummy aggregate arguments are not supported. If an entry description describes an + * aggregate parameter, then any argument passed must match that parameter's description + * . + * (see page 72) + */ + IBM1517I: { + "code": "IBM1517I", + "severity": "S", + "message": (argumentnumber: string, ENTRYname: string) => `The upper and lower bounds in the subelements of argument number ${argumentnumber} in 72 ENTRY reference ${ENTRYname} and in its corresponding parameter description do not match.`, + "fullCode": "IBM1517IS" + } as ParametricPLICode, + + /** + * Array arguments and parameters must have the same number of dimensions. + * ```pli + * dcl a entry( (*,*) fixed bin ), b (10) + * fixed bin; + * call a( b ); + * ``` + * (see page 73) + */ + IBM1518I: { + "code": "IBM1518I", + "severity": "S", + "message": "The number of dimensions for argument number ${argument number } in ENTRY reference ${ENTRY name } and in its corresponding parameter description do not match.", + "fullCode": "IBM1518IS" + } as SimplePLICode, + + /** + * Array arguments and parameters must have the same lower and upper bounds. + * ```pli + * dcl a entry( (0:10) fixed bin ), b (10) + * fixed bin; + * call a( b ); + * ``` + * (see page 73) + */ + IBM1519I: { + "code": "IBM1519I", + "severity": "S", + "message": "The upper and lower bounds for argument number ${argument number } in ENTRY reference ${ENTRY name } and in its corresponding parameter description do not match.", + "fullCode": "IBM1519IS" + } as SimplePLICode, + + /** + * Charset 48 is no longer supported. The source code must be converted to charset 60 + * . + * (see page 73) + */ + IBM1520I: { + "code": "IBM1520I", + "severity": "S", + "message": "Charset 48 is not supported.", + "fullCode": "IBM1520IS" + } as SimplePLICode, + + /** + * The compilation requires more virtual memory than is available. It may help to specify + * one or more of the following compiler options: NOTEST, NOXREF, NOATTRIBUTES, and + * NOAGGREGATE. + * (see page 73) + */ + IBM1521I: { + "code": "IBM1521I", + "severity": "S", + "message": "Not enough virtual memory is available to continue the compilation.", + "fullCode": "IBM1521IS" + } as SimplePLICode, + + /** + * If an offset variable is declared without an AREA reference, it cannot be set in + * an ALLOCATE or LOCATE statement unless an IN clause names an AREA reference. + * (see page 73) + */ + IBM1522I: { + "code": "IBM1522I", + "severity": "S", + "message": (variable: string) => `${variable} cannot be SET unless an IN clause is specified.`, + "fullCode": "IBM1522IS" + } as ParametricPLICode, + + /** + * The built-in function AVAILABLEAREA is defined only for AREAs. + * (see page 73) + */ + IBM1523I: { + "code": "IBM1523I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built- in function must be an AREA reference.`, + "fullCode": "IBM1523IS" + } as ParametricPLICode, + + /** + * An expression contains the built-in function ASIN or ACOS applied to a restricted + * expression that evaluated to a number outside the domain of that function. + * (see page 73) + */ + IBM1524I: { + "code": "IBM1524I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} (x) is undefined if ABS(x) > 1.`, + "fullCode": "IBM1524IS" + } as ParametricPLICode, + + /** + * An expression contains the built-in function ATANH applied to a restricted expression + * that evaluated to a number outside the domain of that function. + * (see page 73) + */ + IBM1525I: { + "code": "IBM1525I", + "severity": "S", + "message": "ATANH(x) is undefined if x is REAL and ABS(x) >= 1.", + "fullCode": "IBM1525IS" + } as SimplePLICode, + + /** + * An expression contains the named built-in function with an argument having mode COMPLEX + * . + * (see page 73) + */ + IBM1526I: { + "code": "IBM1526I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} must have derived mode REAL.`, + "fullCode": "IBM1526IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with its first argument having + * neither type POINTER nor OFFSET. + * (see page 73) + */ + IBM1527I: { + "code": "IBM1527I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have locator type.`, + "fullCode": "IBM1527IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with its first argument having + * mode COMPLEX. This message applies, for example, to the ATAN and ATAND built-in + * functions when two arguments are given. + * (see page 74) + */ + IBM1528I: { + "code": "IBM1528I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have derived mode REAL.`, + "fullCode": "IBM1528IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function, with its second argument having + * mode COMPLEX. This message applies, for example, to the ATAN and ATAND built-in + * functions when two arguments are given. + * (see page 74) + */ + IBM1530I: { + "code": "IBM1530I", + "severity": "S", + "message": "Second argument to ${BUILTIN name } built-in function must have derived mode REAL.", + "fullCode": "IBM1530IS" + } as SimplePLICode, + + /** + * An expression contains the reference BINARYVALUE(x) where x has a type other than + * POINTER, OFFSET or ORDINAL. + * (see page 74) + */ + IBM1531I: { + "code": "IBM1531I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument has invalid type.`, + "fullCode": "IBM1531IS" + } as ParametricPLICode, + + /** + * Any other linkage is invalid. + * (see page 74) + */ + IBM1532I: { + "code": "IBM1532I", + "severity": "S", + "message": "E35 sort exit routines must use a 32-bit linkage.", + "fullCode": "IBM1532IS" + } as SimplePLICode, + + /** + * An expression contains the named built-in function with an argument that has neither + * string nor numeric type. + * (see page 74) + */ + IBM1533I: { + "code": "IBM1533I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have computational type.`, + "fullCode": "IBM1533IS" + } as ParametricPLICode, + + /** + * The result of the REPEAT or COPY built-in function must not be longer than the maximum + * allowed for the base string type. + * (see page 74) + */ + IBM1534I: { + "code": "IBM1534I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} result would be too long.`, + "fullCode": "IBM1534IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with an argument having type other + * than REAL FLOAT. This message applies, for instance, to the floating- point inquiry + * built-in functions such as HUGE and RADIX, and to the floating-point manipulation + * built-in functions such as EXPONENT and SUCC. + * (see page 74) + */ + IBM1535I: { + "code": "IBM1535I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have type REAL FLOAT.`, + "fullCode": "IBM1535IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with an argument that is not a + * reference. + * (see page 74) + */ + IBM1536I: { + "code": "IBM1536I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must be a reference.`, + "fullCode": "IBM1536IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with an argument that is not an + * array expression. This message applies, for example, to the built-in functions ALL, + * ANY, SUM and PROD. + * (see page 74) + */ + IBM1537I: { + "code": "IBM1537I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must be an array expression.`, + "fullCode": "IBM1537IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with an argument that is not a + * FILE. This message applies, for example, to the I\/O built-in functions such as + * LINENO and PAGENO. + * (see page 74) + */ + IBM1538I: { + "code": "IBM1538I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must be a FILE reference.`, + "fullCode": "IBM1538IS" + } as ParametricPLICode, + + /** + * A value must be specified as an argument to a BUILTIN function unless the argument + * is optional. + * ```pli + * dcl a float; + * a = sqrt(*); + * ``` + * (see page 74) + */ + IBM1539I: { + "code": "IBM1539I", + "severity": "S", + "message": "* is invalid as a built-in function argument.", + "fullCode": "IBM1539IS" + } as SimplePLICode, + + /** + * An expression contains the named built-in function with the specified argument having + * mode COMPLEX. 74 This message applies to the MAX and MIN built-in functions. + * (see page 74) + */ + IBM1540I: { + "code": "IBM1540I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function must have derived mode REAL.`, + "fullCode": "IBM1540IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with the specified argument having + * noncomputational type. This message applies to the MAX and MIN built- in functions + * . + * (see page 75) + */ + IBM1541I: { + "code": "IBM1541I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function must have computational type.`, + "fullCode": "IBM1541IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with a first argument that has + * neither string nor numeric type. + * (see page 75) + */ + IBM1542I: { + "code": "IBM1542I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have computational type.`, + "fullCode": "IBM1542IS" + } as ParametricPLICode, + + /** + * This applies to the RANK built-in function. + * (see page 75) + */ + IBM1543I: { + "code": "IBM1543I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built- in function must have type CHARACTER(1) NONVARYING.`, + "fullCode": "IBM1543IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with a first argument that is + * not an array. This message applies, for instance, to the DIMENSION, HBOUND, and + * LBOUND built-in functions. + * (see page 75) + */ + IBM1545I: { + "code": "IBM1545I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must be an array.`, + "fullCode": "IBM1545IS" + } as ParametricPLICode, + + /** + * This applies to the PLIFILL built-in subroutine. + * (see page 75) + */ + IBM1546I: { + "code": "IBM1546I", + "severity": "S", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function must have type CHARACTER(1) NONVARYING.`, + "fullCode": "IBM1546IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with a second argument that has + * neither string nor numeric type. + * (see page 75) + */ + IBM1547I: { + "code": "IBM1547I", + "severity": "S", + "message": "Second argument to ${BUILTIN name } built-in function must have computational type.", + "fullCode": "IBM1547IS" + } as SimplePLICode, + + /** + * The PLISTSIZE built-in functions may be used only in procedures. + * (see page 75) + */ + IBM1548I: { + "code": "IBM1548I", + "severity": "S", + "message": (BUILTINfunction: string) => `${BUILTINfunction} may not be used inside a BEGIN block.`, + "fullCode": "IBM1548IS" + } as ParametricPLICode, + + /** + * The PLISTSIZE built-in function may not be used in procedures with any of the linkages + * OPTLINK, PASCAL, etc. + * (see page 75) + */ + IBM1549I: { + "code": "IBM1549I", + "severity": "S", + "message": (BUILTINfunction: string) => `${BUILTINfunction} may be used only in PROCEDUREs with LINKAGE(SYSTEM).`, + "fullCode": "IBM1549IS" + } as ParametricPLICode, + + /** + * This message applies to the COMPLETION and STATUS pseudovariables. + * (see page 75) + */ + IBM1550I: { + "code": "IBM1550I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to the ${BUILTINname} pseudovariable must be an EVENT variable.`, + "fullCode": "IBM1550IS" + } as ParametricPLICode, + + /** + * This message applies to the PRIORITY pseudovariable. + * (see page 75) + */ + IBM1551I: { + "code": "IBM1551I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to the ${BUILTINname} pseudovariable must be a TASK variable.`, + "fullCode": "IBM1551IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with a third argument that has + * neither string nor numeric type. This message applies, for example, to the SUBSTR + * and CENTER built-in functions. + * (see page 75) + */ + IBM1552I: { + "code": "IBM1552I", + "severity": "S", + "message": (BUILTINname: string) => `Third argument to ${BUILTINname} built-in function must have computational type.`, + "fullCode": "IBM1552IS" + } as ParametricPLICode, + + /** + * The ALL and ANY built-in functions are restricted to two types of array expressions: + * an array expression that is a NONVARYING BIT array reference or an array expression + * that has known length. The first 75 five examples below meet these restrictions, + * but the remaining examples do not. + * ```pli + * dcl a(10) bit(16) varying; + * dcl b(10) bit(16); + * if all( b ) then ... + * if any( a <> ''b ) then ... + * if all( a = b & a ) then ... + * if any( ''b <> b ) then ... + * if all( a = ''b | b = ''b ) then ... + * if any( a ) then ... + * if all( substr(b,1,n) ) then ... + * ``` + * (see page 75) + */ + IBM1554I: { + "code": "IBM1554I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built- in function must be either a NONVARYING BIT array reference or else an array expression with known length.`, + "fullCode": "IBM1554IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with a second argument that has + * neither string nor numeric type. + * (see page 76) + */ + IBM1555I: { + "code": "IBM1555I", + "severity": "S", + "message": "Second argument to ${BUILTIN name } built-in function must have computational type.", + "fullCode": "IBM1555IS" + } as SimplePLICode, + + /** + * If a third argument is given for one of the built-in functions INDEX, SEARCH, VERIFYR, + * or SCRUBOUT, it must be positive. If a third argument is given for one of the built-in + * functions SEARCHR and VERIFYR, it must be nonnegative. If a fourth argument is given + * for the built-in function REPLACE, it must be positive. + * (see page 76) + */ + IBM1556I: { + "code": "IBM1556I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function would force STRINGRANGE.`, + "fullCode": "IBM1556IS" + } as ParametricPLICode, + + /** + * The second argument for the built-in functions CENTER, LEFT and RIGHT must not be + * zero or negative. + * (see page 76) + */ + IBM1557I: { + "code": "IBM1557I", + "severity": "S", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function must be positive.`, + "fullCode": "IBM1557IS" + } as ParametricPLICode, + + /** + * The argument to the VALID built-in function must have exactly the indicated attributes. + * It is not sufficient that it can be converted to these attributes. + * (see page 76) + */ + IBM1558I: { + "code": "IBM1558I", + "severity": "S", + "message": "Argument to VALID built-in function must have the attributes FIXED DECIMAL or PICTURE.", + "fullCode": "IBM1558IS" + } as SimplePLICode, + + /** + * An expression contains the BUILTIN function SQRT applied to a restricted expression + * that evaluated to a number outside the domain of that function. + * (see page 76) + */ + IBM1559I: { + "code": "IBM1559I", + "severity": "S", + "message": "SQRT(x) is undefined if x is REAL and negative.", + "fullCode": "IBM1559IS" + } as SimplePLICode, + + /** + * An expression contains the named built-in function applied to a restricted expression + * that evaluated to a number outside the domain of that function. This message applies, + * for instance, to the LOG, LOG2, and LOG10 built-in functions. + * (see page 76) + */ + IBM1560I: { + "code": "IBM1560I", + "severity": "S", + "message": (BUILTINfunction: string) => `${BUILTINfunction} (x) is undefined if x is REAL and not positive.`, + "fullCode": "IBM1560IS" + } as ParametricPLICode, + + /** + * The argument to the HANDLE built-in must be a structure type, and conversely the + * argument to the TYPE built-in must be a handle. + * (see page 76) + */ + IBM1562I: { + "code": "IBM1562I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built-in function has invalid type.`, + "fullCode": "IBM1562IS" + } as ParametricPLICode, + + /** + * The second argument for the built-in functions CHARACTER, BIT, and GRAPHIC must be + * zero or greater. + * (see page 76) + */ + IBM1563I: { + "code": "IBM1563I", + "severity": "S", + "message": "Second argument to ${BUILTIN name } built-in function must be nonnegative.", + "fullCode": "IBM1563IS" + } as SimplePLICode, + + /** + * Supply the minimum number of arguments required. + * (see page 76) + */ + IBM1564I: { + "code": "IBM1564I", + "severity": "S", + "message": (BUILTINname: string) => `Too few arguments have been specified for the ${BUILTINname} built-in function.`, + "fullCode": "IBM1564IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function applied to a restricted expression + * that evaluated to a number outside the supported domain of that function. + * (see page 76) + */ + IBM1566I: { + "code": "IBM1566I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} (x) is undefined for x outside the supported domain.`, + "fullCode": "IBM1566IS" + } as ParametricPLICode, + + /** + * An expression contains the built-in function ATAN or ATAND applied to a restricted + * expression that 76 evaluated to a number outside the domain of that function. + * (see page 76) + */ + IBM1568I: { + "code": "IBM1568I", + "severity": "S", + "message": (BUILTINfunction: string) => `${BUILTINfunction} (x,y) is undefined if x and y are both zero.`, + "fullCode": "IBM1568IS" + } as ParametricPLICode, + + /** + * The argument to the named built-in function must be a reference (for example, not + * an expression or a literal), and that reference must be CONNECTED. + * (see page 77) + */ + IBM1569I: { + "code": "IBM1569I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must be a CONNECTED reference.`, + "fullCode": "IBM1569IS" + } as ParametricPLICode, + + /** + * The ALLOCATION built-in function cannot be used with structure members or with non-CONTROLLED + * variables. + * (see page 77) + */ + IBM1570I: { + "code": "IBM1570I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must be a reference to a level 1 CONTROLLED variable.`, + "fullCode": "IBM1570IS" + } as ParametricPLICode, + + /** + * The OMITTED built-in function cannot be used with BYVALUE parameters, structure members, + * or non- parameters. + * (see page 77) + */ + IBM1571I: { + "code": "IBM1571I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must be a reference to a level 1 BYADDR parameter.`, + "fullCode": "IBM1571IS" + } as ParametricPLICode, + + /** + * Add the OPTIONAL attribute to the entry declaration or replace the * by an actual + * argument. + * (see page 77) + */ + IBM1573I: { + "code": "IBM1573I", + "severity": "S", + "message": "The use of * as an argument is permitted only for parameters declared with the OPTIONAL attribute.", + "fullCode": "IBM1573IS" + } as SimplePLICode, + + /** + * The indicated argument to built-in functions such as PLIMOVE and COMPARE must be + * a locator. + * (see page 77) + */ + IBM1575I: { + "code": "IBM1575I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function must have type POINTER or OFFSET.`, + "fullCode": "IBM1575IS" + } as ParametricPLICode, + + /** + * This applies to HEXIMAGE, CENTER, LEFT, RIGHT, MEMSQUEEZE, etc. + * (see page 77) + */ + IBM1576I: { + "code": "IBM1576I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built- in function must have type CHARACTER(1) NONVARYING.`, + "fullCode": "IBM1576IS" + } as ParametricPLICode, + + /** + * This applies to the OFFSET built-in function. + * (see page 77) + */ + IBM1577I: { + "code": "IBM1577I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type POINTER.`, + "fullCode": "IBM1577IS" + } as ParametricPLICode, + + /** + * This applies to the POINTER built-in function. + * (see page 77) + */ + IBM1578I: { + "code": "IBM1578I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type OFFSET.`, + "fullCode": "IBM1578IS" + } as ParametricPLICode, + + /** + * This applies to the OFFSET and POINTER built-in functions. + * (see page 77) + */ + IBM1579I: { + "code": "IBM1579I", + "severity": "S", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function must have type AREA.`, + "fullCode": "IBM1579IS" + } as ParametricPLICode, + + /** + * If the first argument to built-in functions such as PLIMOVE and COMPARE has the attribute + * OFFSET, it must be an OFFSET reference not an OFFSET value. + * (see page 77) + */ + IBM1580I: { + "code": "IBM1580I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function is an OFFSET value.`, + "fullCode": "IBM1580IS" + } as ParametricPLICode, + + /** + * If the first argument to built-in functions such as PLIMOVE and COMPARE is an OFFSET + * variable, that OFFSET variable must be declared with an AREA qualifier so that the + * offset can be converted to an address. + * (see page 77) + */ + IBM1581I: { + "code": "IBM1581I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function is an OFFSET variable declared without an AREA qualifier.`, + "fullCode": "IBM1581IS" + } as ParametricPLICode, + + /** + * If the indicated argument to built-in functions such as PLIMOVE and COMPARE has the + * attribute OFFSET, it must be an OFFSET reference not an OFFSET value. + * (see page 77) + */ + IBM1582I: { + "code": "IBM1582I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function is an OFFSET value.`, + "fullCode": "IBM1582IS" + } as ParametricPLICode, + + /** + * If the indicated argument to built-in functions such as PLIMOVE and COMPARE is an + * OFFSET variable, that OFFSET variable must be declared with an AREA qualifier so + * that the offset can be converted to an address. + * (see page 78) + */ + IBM1583I: { + "code": "IBM1583I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built- in function is an OFFSET variable declared without an AREA qualifier.`, + "fullCode": "IBM1583IS" + } as ParametricPLICode, + + /** + * This applies to the OFFSETDIFF built-in function. + * (see page 78) + */ + IBM1584I: { + "code": "IBM1584I", + "severity": "S", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function must have type OFFSET.`, + "fullCode": "IBM1584IS" + } as ParametricPLICode, + + /** + * This applies to the POINTERDIFF built-in function. + * (see page 78) + */ + IBM1585I: { + "code": "IBM1585I", + "severity": "S", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function must have type POINTER.`, + "fullCode": "IBM1585IS" + } as ParametricPLICode, + + /** + * The STRING built-in function and pseudovariable cannot be applied to discontiguous + * array cross- sections or to array parameters not declared with the CONNECTED attribute + * . + * (see page 78) + */ + IBM1586I: { + "code": "IBM1586I", + "severity": "S", + "message": "Argument to the STRING built-in function must be CONNECTED.", + "fullCode": "IBM1586IS" + } as SimplePLICode, + + /** + * Any other argument type is invalid. This message applies to the PLISRTx built-in + * functions. + * (see page 78) + */ + IBM1587I: { + "code": "IBM1587I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function must have the ENTRY attribute.`, + "fullCode": "IBM1587IS" + } as ParametricPLICode, + + /** + * This applies to the CHARGRAPHIC built-in function. For instance, in the following + * example, g should be declared as graphic, not as char. + * ```pli + * dcl c char(10); + * dcl g char(5); + * c = charg( g ); + * ``` + * (see page 78) + */ + IBM1588I: { + "code": "IBM1588I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type GRAPHIC.`, + "fullCode": "IBM1588IS" + } as ParametricPLICode, + + /** + * The LOCATION and BITLOCATION built-in functions cannot be applied to subscripted + * references. + * (see page 78) + */ + IBM1589I: { + "code": "IBM1589I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must not have any subscripts.`, + "fullCode": "IBM1589IS" + } as ParametricPLICode, + + /** + * The STRING built-in function and pseudovariable cannot be applied to UNIONs or to + * structures containing UNIONs. + * (see page 78) + */ + IBM1590I: { + "code": "IBM1590I", + "severity": "S", + "message": "Argument to the STRING built-in function must not be a UNION and must not contain a UNION.", + "fullCode": "IBM1590IS" + } as SimplePLICode, + + /** + * The STRING built-in function and pseudovariable cannot be applied to structures or + * arrays containing elements with the ALIGNED attribute. + * (see page 78) + */ + IBM1591I: { + "code": "IBM1591I", + "severity": "S", + "message": "All members of an argument to the STRING built-in function must have the UNALIGNED attribute.", + "fullCode": "IBM1591IS" + } as SimplePLICode, + + /** + * The STRING built-in function and pseudovariable cannot be applied to structures or + * arrays containing VARYING strings. + * (see page 78) + */ + IBM1592I: { + "code": "IBM1592I", + "severity": "S", + "message": "All members of an argument to the STRING built-in function must have the NONVARYING attribute.", + "fullCode": "IBM1592IS" + } as SimplePLICode, + + /** + * The STRING built-in function and pseudovariable cannot be applied to structures or + * arrays containing noncomputational types or arithmetic types other than pictures + * . + * (see page 78) + */ + IBM1593I: { + "code": "IBM1593I", + "severity": "S", + "message": "All members of an argument to the STRING built-in function must have string type.", + "fullCode": "IBM1593IS" + } as SimplePLICode, + + /** + * The STRING built-in function and pseudovariable cannot be applied to structures or + * arrays containing different string types, for example, BIT and CHARACTER strings + * . + * (see page 79) + */ + IBM1594I: { + "code": "IBM1594I", + "severity": "S", + "message": "All members of an argument to the STRING built-in function must have the same string type.", + "fullCode": "IBM1594IS" + } as SimplePLICode, + + /** + * This applies to the floating-point inquiry and manipulation built-in functions such + * as HUGE and EXPONENT. + * (see page 79) + */ + IBM1595I: { + "code": "IBM1595I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type REAL FLOAT.`, + "fullCode": "IBM1595IS" + } as ParametricPLICode, + + /** + * This applies to the EDIT built-in function. + * (see page 79) + */ + IBM1596I: { + "code": "IBM1596I", + "severity": "S", + "message": (BUILTINname: string) => `Second argument to ${BUILTINname} built-in function must have type CHARACTER.`, + "fullCode": "IBM1596IS" + } as ParametricPLICode, + + /** + * This applies to the PRIORITY built-in function. + * (see page 79) + */ + IBM1597I: { + "code": "IBM1597I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have type TASK.`, + "fullCode": "IBM1597IS" + } as ParametricPLICode, + + /** + * This applies to the COMPLETION and STATUS built-in functions. + * (see page 79) + */ + IBM1598I: { + "code": "IBM1598I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have type EVENT.`, + "fullCode": "IBM1598IS" + } as ParametricPLICode, + + /** + * The named built-in function is not a pseudovariable and may not be used as one. + * (see page 79) + */ + IBM1599I: { + "code": "IBM1599I", + "severity": "S", + "message": "The built-in function ${variable name } may not be used as a pseudovariable.", + "fullCode": "IBM1599IS" + } as SimplePLICode, + + /** + * It is invalid to assign an array, structure, or union to one of the built-in functions + * ONCHAR, ONSOURCE, or ONGSOURCE. + * (see page 79) + */ + IBM1600I: { + "code": "IBM1600I", + "severity": "S", + "message": (BUILTINname: string) => `Source to ${BUILTINname} pseudovariable must be scalar.`, + "fullCode": "IBM1600IS" + } as ParametricPLICode, + + /** + * The BUILTIN attribute can be applied only to identifiers that are the names of built-in + * functions or subroutines. + * (see page 79) + */ + IBM1601I: { + "code": "IBM1601I", + "severity": "S", + "message": (identifier: string) => `The identifier ${identifier} is not the name of a built-in function. Any use of it is unsupported.`, + "fullCode": "IBM1601IS" + } as ParametricPLICode, + + /** + * This applies to the PLISRTx built-in functions. For instance, in the following example, + * rc should be declared as fixed bin(31), not fixed bin(15). + * ```pli + * dcl rc fixed bin(15); + * call plisrta( 'SORT FIELDS=(1,80,CH,A) ', + * 'RECORD TYPE=F,LENGTH=(80) ', + * 256000, + * rc ); + * ``` + * (see page 79) + */ + IBM1602I: { + "code": "IBM1602I", + "severity": "S", + "message": (BUILTINname: string) => `Fourth argument to ${BUILTINname} built-in function must have the attributes REAL FIXED BIN(31,0).`, + "fullCode": "IBM1602IS" + } as ParametricPLICode, + + /** + * This applies to the ADDR and similar built-in functions. It is invalid, for instance, + * to apply the ADDR built-in function to a label constant. + * (see page 79) + */ + IBM1603I: { + "code": "IBM1603I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must not have the CONSTANT attribute.`, + "fullCode": "IBM1603IS" + } as ParametricPLICode, + + /** + * The argument for the built-in functions LOW and HIGH must be zero or greater. + * (see page 79) + */ + IBM1604I: { + "code": "IBM1604I", + "severity": "S", + "message": (BUILTINfunction: string) => `${BUILTINfunction} argument must be nonnegative.`, + "fullCode": "IBM1604IS" + } as ParametricPLICode, + + /** + * The ENTRYADDR built-in function cannot be applied to non-ENTRYs or to INTERNAL ENTRY + * constants. + * (see page 79) + */ + IBM1605I: { + "code": "IBM1605I", + "severity": "S", + "message": "Argument to ENTRYADDR built- in function must be an ENTRY variable or an EXTERNAL ENTRY constant.", + "fullCode": "IBM1605IS" + } as SimplePLICode, + + /** + * Pseudovariables cannot be applied to expressions. + * ```pli + * unspec( 12 ) = '00'b4; + * ``` + * (see page 80) + */ + IBM1606I: { + "code": "IBM1606I", + "severity": "S", + "message": (variablename: string) => `Argument to ${variablename} pseudovariable must be a reference.`, + "fullCode": "IBM1606IS" + } as ParametricPLICode, + + /** + * The SUBSTR pseudovariable cannot be applied to expressions. + * ```pli + * substr( 'nope', 1, 1 ) = 'd'; + * ``` + * (see page 80) + */ + IBM1607I: { + "code": "IBM1607I", + "severity": "S", + "message": "First argument to ${variable name } pseudovariable must be a reference.", + "fullCode": "IBM1607IS" + } as SimplePLICode, + + /** + * The compiler does not support the named pseudovariable applied to arrays, structures, + * or unions. + * (see page 80) + */ + IBM1608I: { + "code": "IBM1608I", + "severity": "S", + "message": (variablename: string) => `Argument to ${variablename} pseudovariable must be a scalar.`, + "fullCode": "IBM1608IS" + } as ParametricPLICode, + + /** + * The compiler does not support the named pseudovariable applied to arrays, structures, + * or unions. + * (see page 80) + */ + IBM1609I: { + "code": "IBM1609I", + "severity": "S", + "message": (variablename: string) => `First argument to ${variablename} pseudovariable must be a scalar.`, + "fullCode": "IBM1609IS" + } as ParametricPLICode, + + /** + * The REAL and IMAG pseudovariable can be applied only to COMPLEX arithmetic variables + * . + * (see page 80) + */ + IBM1610I: { + "code": "IBM1610I", + "severity": "S", + "message": (variablename: string) => `Argument to ${variablename} pseudovariable must be COMPLEX.`, + "fullCode": "IBM1610IS" + } as ParametricPLICode, + + /** + * The SUBSTR pseudovariable cannot be applied to numeric variables or to noncomputational + * values. + * (see page 80) + */ + IBM1611I: { + "code": "IBM1611I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} pseudovariable must have string type.`, + "fullCode": "IBM1611IS" + } as ParametricPLICode, + + /** + * The ENTRYADDR pseudovariable can be applied only to ENTRY variables. + * (see page 80) + */ + IBM1612I: { + "code": "IBM1612I", + "severity": "S", + "message": "Argument to the ENTRYADDR pseudovariable must be an ENTRY variable.", + "fullCode": "IBM1612IS" + } as SimplePLICode, + + /** + * The indicated built-in function cannot be applied to file constants with attributes + * that conflict with the indicated attribute. + * (see page 80) + */ + IBM1613I: { + "code": "IBM1613I", + "severity": "S", + "message": (BUILTINname: string, fileattribute: string) => `Argument to ${BUILTINname} built- in function has attributes that conflict with ${fileattribute} .`, + "fullCode": "IBM1613IS" + } as ParametricPLICode, + + /** + * The indicated built-in function cannot be applied to non-STREAM files. + * (see page 80) + */ + IBM1614I: { + "code": "IBM1614I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built- in function has attributes that conflict with STREAM.`, + "fullCode": "IBM1614IS" + } as ParametricPLICode, + + /** + * The indicated built-in function cannot be applied to non-PRINT files. + * (see page 80) + */ + IBM1615I: { + "code": "IBM1615I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built- in function has attributes that conflict with PRINT.`, + "fullCode": "IBM1615IS" + } as ParametricPLICode, + + /** + * Specified file attributes and ENVIRONMENT options on a declaration statement are + * in conflict. The following DECLARE statement is an example of this type of conflict + * : + * ```pli + * dcl file f1 direct env(consecutive); + * ``` + * (see page 80) + */ + IBM1616I: { + "code": "IBM1616I", + "severity": "S", + "message": (filename: string) => `Attributes and ENVIRONMENT options for file ${filename} conflict.`, + "fullCode": "IBM1616IS" + } as ParametricPLICode, + + /** + * Use of the DIRECT file attribute needs an ENVIRONMENT option specification of INDEXED, + * REGIONAL, RELATIVE, or VSAM. + * ```pli + * dcl file f1 direct env(relative); + * ``` + * (see page 80) + */ + IBM1617I: { + "code": "IBM1617I", + "severity": "S", + "message": "DIRECT attribute for file ${file name } needs ENVIRONMENT option specification of INDEXED, REGIONAL, RELATIVE, or VSAM.", + "fullCode": "IBM1617IS" + } as SimplePLICode, + + /** + * %INCLUDE must be followed by a name and either a semicolon or else a second name + * in parenthesis and then a semicolon. + * (see page 81) + */ + IBM1618I: { + "code": "IBM1618I", + "severity": "S", + "message": "Syntax of the INCLUDE statement is incorrect.", + "fullCode": "IBM1618IS" + } as SimplePLICode, + + /** + * The maximum length of the file specification is 8 characters. + * (see page 81) + */ + IBM1619I: { + "code": "IBM1619I", + "severity": "S", + "message": "File specification after INCLUDE is too long.", + "fullCode": "IBM1619IS" + } as SimplePLICode, + + /** + * %INCLUDE must be followed by a file name, not just a semicolon. + * (see page 81) + */ + IBM1620I: { + "code": "IBM1620I", + "severity": "S", + "message": "File specification missing after INCLUDE.", + "fullCode": "IBM1620IS" + } as SimplePLICode, + + /** + * If a parameter is an unaligned bit string or an array or structure consisting entirely + * of unaligned bit strings, then OPTIONS(NODESCRIPTOR) must not be specified or implied + * . + * (see page 81) + */ + IBM1621I: { + "code": "IBM1621I", + "severity": "S", + "message": "NODESCRIPTOR attribute is invalid if any parameters have bit alignment.", + "fullCode": "IBM1621IS" + } as SimplePLICode, + + /** + * Aggregates with more than 131071 elements and dimension specifications would require + * descriptors that would require too much storage. + * (see page 81) + */ + IBM1622I: { + "code": "IBM1622I", + "severity": "S", + "message": "The number of elements and dimension specifications in an aggregate must not exceed 131071.", + "fullCode": "IBM1622IS" + } as SimplePLICode, + + /** + * The named reference is not a member of any structure or union declared in the block + * in which it is referenced or declared in any block containing that block. + * (see page 81) + */ + IBM1623I: { + "code": "IBM1623I", + "severity": "S", + "message": (referencename: string) => `The dot-qualified reference ${referencename} is unknown.`, + "fullCode": "IBM1623IS" + } as ParametricPLICode, + + /** + * An expression specifying an array bound, a string length or an AREA size must not + * be a reference to an array, a structure, or a union. + * (see page 81) + */ + IBM1625I: { + "code": "IBM1625I", + "severity": "S", + "message": "Extent must be a scalar.", + "fullCode": "IBM1625IS" + } as SimplePLICode, + + /** + * An expression specifying an array bound, a string length, or an AREA size must have + * numeric or string type. + * (see page 81) + */ + IBM1626I: { + "code": "IBM1626I", + "severity": "S", + "message": "Extent must have computational type.", + "fullCode": "IBM1626IS" + } as SimplePLICode, + + /** + * An expression used as a subscript must not be an array, structure, or union reference + * . + * (see page 81) + */ + IBM1627I: { + "code": "IBM1627I", + "severity": "S", + "message": "Subscript expressions must be scalars.", + "fullCode": "IBM1627IS" + } as SimplePLICode, + + /** + * Only expressions having numeric or string type may be used as subscripts. + * (see page 81) + */ + IBM1628I: { + "code": "IBM1628I", + "severity": "S", + "message": (indexnumber: string, variablename: string) => `Index number ${indexnumber} into the array ${variablename} must have computational type.`, + "fullCode": "IBM1628IS" + } as ParametricPLICode, + + /** + * Array bounds, string lengths, and AREA sizes in STATIC variables must evaluate at + * compile-time to constants. + * (see page 81) + */ + IBM1629I: { + "code": "IBM1629I", + "severity": "S", + "message": "Extents for STATIC variable are not constant.", + "fullCode": "IBM1629IS" + } as SimplePLICode, + + /** + * In the assignment of one array to another, the two arrays must have the same number + * of dimensions. + * (see page 81) + */ + IBM1630I: { + "code": "IBM1630I", + "severity": "S", + "message": "Number of dimensions in arrays do not match.", + "fullCode": "IBM1630IS" + } as SimplePLICode, + + /** + * In the assignment of one array to another, the two arrays must have the same lower + * and upper bound in each dimension. + * (see page 81) + */ + IBM1631I: { + "code": "IBM1631I", + "severity": "S", + "message": "Upper and lower bounds in arrays do not match.", + "fullCode": "IBM1631IS" + } as SimplePLICode, + + /** + * Executing such a program would most likely cause a protection exception. + * ```pli + * dcl a(5:10) fixed bin(31); + * a(1) = 0; + * ``` + * (see page 82) + */ + IBM1632I: { + "code": "IBM1632I", + "severity": "S", + "message": (indexnumber: string, variablename: string) => `Index number ${indexnumber} into the variable ${variablename} is less than the lower bound for that dimension.`, + "fullCode": "IBM1632IS" + } as ParametricPLICode, + + /** + * Executing such a program would most likely cause a protection exception. + * ```pli + * dcl a(5:10) fixed bin(31); + * a(20) = 0; + * ``` + * (see page 82) + */ + IBM1633I: { + "code": "IBM1633I", + "severity": "S", + "message": (indexnumber: string, variablename: string) => `Index number ${indexnumber} into the variable ${variablename} is greater than the upper bound for that dimension.`, + "fullCode": "IBM1633IS" + } as ParametricPLICode, + + /** + * In structure assignments and structure expressions, all subelements that are arrays + * must have the same number of dimensions. + * ```pli + * dcl + * 1 a, + * 2 b(8) fixed bin, + * 2 c char(10); + * dcl + * 1 x, + * 2 y(8,9) fixed bin, + * 2 z char(10); + * a = x; + * ``` + * (see page 82) + */ + IBM1634I: { + "code": "IBM1634I", + "severity": "S", + "message": "Number of dimensions in subelements of structures do not match.", + "fullCode": "IBM1634IS" + } as SimplePLICode, + + /** + * In structure assignments and structure expressions, all subelements that are arrays + * must have the same bounds. + * ```pli + * dcl + * 1 a, + * 2 b(8) fixed bin, + * 2 c char(10); + * dcl + * 1 x, + * 2 y(9) fixed bin, + * 2 z char(10); + * a = x; + * ``` + * (see page 82) + */ + IBM1635I: { + "code": "IBM1635I", + "severity": "S", + "message": "Upper and lower bounds in subelements of structures do not match.", + "fullCode": "IBM1635IS" + } as SimplePLICode, + + /** + * In structure assignments and structure expressions, if any element of one structure + * is itself a structure, then the corresponding element in all the other structures + * must also be a similar structure. + * (see page 82) + */ + IBM1636I: { + "code": "IBM1636I", + "severity": "S", + "message": "Substructuring in subelements of structures do not match.", + "fullCode": "IBM1636IS" + } as SimplePLICode, + + /** + * In structure assignments and structure expressions, all structures must have the + * same number of elements. + * (see page 82) + */ + IBM1637I: { + "code": "IBM1637I", + "severity": "S", + "message": "Number of subelements in structures do not match.", + "fullCode": "IBM1637IS" + } as SimplePLICode, + + /** + * Only scalars and arrays of scalars are permitted in GENERIC descriptions. + * (see page 82) + */ + IBM1638I: { + "code": "IBM1638I", + "severity": "S", + "message": "Structures and unions are not permitted in GENERIC descriptions.", + "fullCode": "IBM1638IS" + } as SimplePLICode, + + /** + * Aggregates containing no strings or arithmetic variables cannot be used in PUT or + * GET statements. + * (see page 82) + */ + IBM1639I: { + "code": "IBM1639I", + "severity": "S", + "message": (aggregatename: string) => `The aggregate ${aggregatename} contains only noncomputational values. The aggregate will be ignored.`, + "fullCode": "IBM1639IS" + } as ParametricPLICode, + + /** + * Aggregates containing one or more UNION statements cannot be used in PUT or GET statements + * . + * (see page 83) + */ + IBM1640I: { + "code": "IBM1640I", + "severity": "S", + "message": (aggregatename: string) => `The aggregate ${aggregatename} contains one or more unions and cannot be used in stream I/O.`, + "fullCode": "IBM1640IS" + } as ParametricPLICode, + + /** + * An array of structures must be referenced in its entirety or element by element. + * ```pli + * dcl + * 1 a(8,9), + * 2 b fixed bin, + * 2 c char(10); + * a(2,*) = 0; + * ``` + * (see page 83) + */ + IBM1641I: { + "code": "IBM1641I", + "severity": "S", + "message": (structurename: string) => `References to slices of the array of structures ${structurename} are not permitted.`, + "fullCode": "IBM1641IS" + } as ParametricPLICode, + + /** + * An array of unions must be referenced in its entirety or element by element. + * ```pli + * dcl + * 1 a(8,9) union, + * 2 b fixed bin, + * 2 c char(10); + * a(2,*) = 0; + * ``` + * (see page 83) + */ + IBM1642I: { + "code": "IBM1642I", + "severity": "S", + "message": (unionname: string) => `References to slices of the array of unions ${unionname} are not permitted.`, + "fullCode": "IBM1642IS" + } as ParametricPLICode, + + /** + * It must be possible to compute the value of the DIMENSION built-in function for an + * array. In DECLARE x(x:y), ( y-x+1) must be less than 214748648. + * (see page 83) + */ + IBM1643I: { + "code": "IBM1643I", + "severity": "S", + "message": "Each dimension of an array must contain no more than 2147483647 elements.", + "fullCode": "IBM1643IS" + } as SimplePLICode, + + /** + * The maximum physical level allowed is 255, but the maximum logical level is 15. + * (see page 83) + */ + IBM1644I: { + "code": "IBM1644I", + "severity": "S", + "message": "Aggregate contains more than 15 logical levels.", + "fullCode": "IBM1644IS" + } as SimplePLICode, + + /** + * Aggregates containing unaligned bits must be less than 2**28 bytes in size while + * all other aggregates must be less than 2**31. + * (see page 83) + */ + IBM1645I: { + "code": "IBM1645I", + "severity": "S", + "message": "Data aggregate exceeds the maximum length.", + "fullCode": "IBM1645IS" + } as SimplePLICode, + + /** + * If the TO value is bigger than the maximum value that a FIXED or PICTURE variable + * can hold, then a loop dominated by that variable would cause SIZE to be raised. + * For example, in the first code fragment below, x can not be assigned a value bigger + * than 99. In the second code fragment below, y can not be assigned a value bigger + * than 32767. + * ```pli + * dcl x pic'99'; + * do x = 1 to 100; + * put skip list( x ); + * end; + * dcl y fixed bin(15); + * do y = 1 to 32768; + * put skip list( y ); + * end; + * ``` + * (see page 83) + */ + IBM1646I: { + "code": "IBM1646I", + "severity": "S", + "message": "SIZE would be raised in assigning TO value to control variable.", + "fullCode": "IBM1646IS" + } as SimplePLICode, + + /** + * The number of subscripts given for a variable must match that variable's number of + * dimensions + * (see page 83) + */ + IBM1647I: { + "code": "IBM1647I", + "severity": "S", + "message": (variablename: string) => `Too few subscripts specified for the variable ${variablename} .`, + "fullCode": "IBM1647IS" + } as ParametricPLICode, + + /** + * The number of subscripts given for a variable must match that variable's number of + * dimensions + * (see page 83) + */ + IBM1648I: { + "code": "IBM1648I", + "severity": "S", + "message": (variablename: string) => `Too many subscripts specified for the variable ${variablename} .`, + "fullCode": "IBM1648IS" + } as ParametricPLICode, + + /** + * Arrays with more than 15 dimensions are not supported. + * ```pli + * ``` 83 + * ```pli + * dcl + * 1 dim7(2,3,4,5,6,7,8), + * 2 dim7more(2,3,4,5,6,7,8) + * 3 dim2many(2,3) fixed bin, + * 3 * fixed bin, + * 2 * char(10); + * ``` + * (see page 83) + */ + IBM1649I: { + "code": "IBM1649I", + "severity": "S", + "message": "The number of inherited dimensions plus the number of member dimensions exceeds 15.", + "fullCode": "IBM1649IS" + } as SimplePLICode, + + /** + * The LIKE reference cannot be a scalar or an array of scalars. + * ```pli + * dcl + * a fixed bin, + * 1 b like a; + * ``` + * (see page 84) + */ + IBM1650I: { + "code": "IBM1650I", + "severity": "S", + "message": "The LIKE reference is neither a structure nor a union.", + "fullCode": "IBM1650IS" + } as SimplePLICode, + + /** + * The LIKE reference needs enough qualification to be unique. This message also applies + * to INDFOR and VALUELISTFROM. + * ```pli + * dcl + * 1 x like b, + * 1 a, + * 2 b, + * 3 c, + * 3 d, + * 2 e, + * 3 f, + * 3 g, + * 1 h, + * 2 b, + * 3 j, + * 3 k; + * ``` + * (see page 84) + */ + IBM1651I: { + "code": "IBM1651I", + "severity": "S", + "message": (keywordname: string) => `The ${keywordname} reference is ambiguous.`, + "fullCode": "IBM1651IS" + } as ParametricPLICode, + + /** + * LIKE from LIKE is not supported. + * ```pli + * dcl + * 1 a, + * 2 b1 like c, + * 2 b2 like c, + * 1 c, + * 2 d fixed bin, + * 2 e fixed bin; + * dcl + * 1 x like a; + * ``` + * (see page 84) + */ + IBM1652I: { + "code": "IBM1652I", + "severity": "S", + "message": "Neither the LIKE reference nor any of its substructures can be declared with the LIKE attribute.", + "fullCode": "IBM1652IS" + } as SimplePLICode, + + /** + * LIKE definitions must not be recursive. + * ```pli + * dcl + * 1 a based, + * 2 b1 fixed bin(31), + * 2 b2 fixed bin(31), + * 2 b3, + * 3 c limited entry( like a ); + * ``` + * (see page 84) + */ + IBM1653I: { + "code": "IBM1653I", + "severity": "S", + "message": "A LIKE reference in an ENTRY declaration must not be a member of a structure or union containing that ENTRY declaration.", + "fullCode": "IBM1653IS" + } as SimplePLICode, + + /** + * The LIKE reference must be known in the block containing the LIKE attribute specification. + * This message also applies to INDFOR and VALUELISTFROM. + * (see page 84) + */ + IBM1654I: { + "code": "IBM1654I", + "severity": "S", + "message": (keywordname: string) => `The ${keywordname} reference is unknown.`, + "fullCode": "IBM1654IS" + } as ParametricPLICode, + + /** + * If a parameter is declared as controlled, non- controlled variables and expressions + * with operators cannot be passed to it. + * ```pli + * dcl c char(20); + * call a(c); + * a: proc( b ); + * dcl b controlled char(*); + * ``` + * (see page 84) + */ + IBM1655I: { + "code": "IBM1655I", + "severity": "S", + "message": "Only CONTROLLED variables can be passed to CONTROLLED parameters.", + "fullCode": "IBM1655IS" + } as SimplePLICode, + + /** + * Differences in any arithmetic attributes are not permitted. The following example + * will emit this message. + * ```pli + * dcl x fixed bin(15) controlled; + * call a(x); + * ``` 84 + * ```pli + * a: proc( b ); + * dcl b controlled fixed bin(31); + * ``` + * (see page 84) + */ + IBM1656I: { + "code": "IBM1656I", + "severity": "S", + "message": "A CONTROLLED variable passed to a CONTROLLED parameter must have the same attributes as that parameter.", + "fullCode": "IBM1656IS" + } as SimplePLICode, + + /** + * Subscripts are permitted only in array element references. + * (see page 85) + */ + IBM1657I: { + "code": "IBM1657I", + "severity": "S", + "message": "A subscript has been specified for the non-array variable ${variable name } .", + "fullCode": "IBM1657IS" + } as SimplePLICode, + + /** + * Temporary arrays of strings are supported only if the string length is known. + * ```pli + * dcl a entry, (b(10),c(10)) char(20) var; + * call a( b || c ); + * ``` + * (see page 85) + */ + IBM1658I: { + "code": "IBM1658I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is an array expression requiring a temporary array with strings of unknown length.", + "fullCode": "IBM1658IS" + } as SimplePLICode, + + /** + * The total number of logical levels after LIKE expansion must not exceed 15. + * (see page 85) + */ + IBM1659I: { + "code": "IBM1659I", + "severity": "S", + "message": "After LIKE expansion, aggregate would contain more than 15 logical levels.", + "fullCode": "IBM1659IS" + } as SimplePLICode, + + /** + * Execution of the statement would raise the RECORD condition. + * ```pli + * dcl datei file record output + * env( fb recsize (80) + * total ) ; + * dcl satzaus char (100); + * write file(datei) from(satzaus); + * ``` + * (see page 85) + */ + IBM1660I: { + "code": "IBM1660I", + "severity": "S", + "message": (recordsize: string, recsize: string) => `The size ( ${recordsize} ) of the record conflicts with the RECSIZE ( ${recsize} ) specified in the ENVIRONMENT attribute.`, + "fullCode": "IBM1660IS" + } as ParametricPLICode, + + /** + * Only scalars can be assigned to scalars. + * (see page 85) + */ + IBM1661I: { + "code": "IBM1661I", + "severity": "S", + "message": "Aggregates cannot be assigned to scalars.", + "fullCode": "IBM1661IS" + } as SimplePLICode, + + /** + * Unions and structures containing unions may not be used in expressions except when + * used as an argument to a built-in function such as ADDR or UNSPEC. + * (see page 85) + */ + IBM1662I: { + "code": "IBM1662I", + "severity": "S", + "message": "Unsupported use of union or structure containing a union.", + "fullCode": "IBM1662IS" + } as SimplePLICode, + + /** + * Structure expressions may not, for instance, be assigned to arrays of scalars. + * (see page 85) + */ + IBM1663I: { + "code": "IBM1663I", + "severity": "S", + "message": "Unsupported or invalid use of structure expression.", + "fullCode": "IBM1663IS" + } as SimplePLICode, + + /** + * Array expressions may not, for instance, be assigned to structures or scalars. + * (see page 85) + */ + IBM1664I: { + "code": "IBM1664I", + "severity": "S", + "message": "Array expressions cannot be assigned to non-arrays.", + "fullCode": "IBM1664IS" + } as SimplePLICode, + + /** + * An E15 sort exit have the RETURNS attribute since it will be invoked as a function + * by the sort library routine. + * (see page 85) + */ + IBM1665I: { + "code": "IBM1665I", + "severity": "S", + "message": "E15 sort exit routines must have the RETURNS attribute.", + "fullCode": "IBM1665IS" + } as SimplePLICode, + + /** + * An E15 sort exit may return a NONVARYING, VARYING or VARYINGZ CHARACTER string, but + * it must be a character string. + * (see page 85) + */ + IBM1666I: { + "code": "IBM1666I", + "severity": "S", + "message": "E15 sort exit routines must return a CHARACTER string.", + "fullCode": "IBM1666IS" + } as SimplePLICode, + + /** + * The target in an assignment statement must not have the NONASSIGNABLE attribute. + * (see page 85) + */ + IBM1667I: { + "code": "IBM1667I", + "severity": "S", + "message": "Target in assignment is NONASSIGNABLE.", + "fullCode": "IBM1667IS" + } as SimplePLICode, + + /** + * The target of an assignment statement must be an array, structure, union or scalar + * reference. Function references are not permitted as target of assignments. + * (see page 85) + */ + IBM1668I: { + "code": "IBM1668I", + "severity": "S", + "message": "Target in assignment is a function reference.", + "fullCode": "IBM1668IS" + } as SimplePLICode, + + /** + * Assignments to UNIONs or structures containing UNIONs are restricted. Compound assignment + * operators are not supported, the source must be a similar structure that contains + * matching UNIONs, both the source and target must have extents known at compile time, + * and all UNIONs involved must occupy a whole number of bytes. + * (see page 86) + */ + IBM1669I: { + "code": "IBM1669I", + "severity": "S", + "message": "Unsupported assignment to a target containing a UNION.", + "fullCode": "IBM1669IS" + } as SimplePLICode, + + /** + * In a PROCEDURE containing ENTRY statements, if the PROCEDURE and ENTRY statements + * do not all have the same RETURNS attributes, then all values must be returned BYADDR. + * You can compile with DFT(RETURNS(BYADDR)) to force this, or you can add the BYADDR + * attribute to each set of RETURNS attribute. For example, you must either compile + * the following program with DFT(RETURNS(BYADDR)) or change the \"fixed bin\" to \"fixed + * bin byaddr\". + * ```pli + * a: proc; + * return; + * b: entry returns( fixed bin ); + * return( 1729 ); + * end; + * ``` + * (see page 86) + */ + IBM1670I: { + "code": "IBM1670I", + "severity": "S", + "message": "A PROCEDURE containing ENTRY statements with differing RETURNS attributes must return values BYADDR.", + "fullCode": "IBM1670IS" + } as SimplePLICode, + + /** + * The source in a structure assignment cannot be an array of scalars or a structure + * that does not match the target. + * (see page 86) + */ + IBM1671I: { + "code": "IBM1671I", + "severity": "S", + "message": "The source in a structure assignment must be a scalar expression or a matching structure.", + "fullCode": "IBM1671IS" + } as SimplePLICode, + + /** + * A BY NAME assignment may have not have a mixture of array and non-array targets. + * ```pli + * dcl 1 a, 2 a1 fixed bin, 2 a2 fixed bin; + * dcl 1 b(3), 2 a1 fixed bin, 2 a2 fixed bin; + * dcl 1 c, 2 a1 fixed bin, 2 a2 fixed bin; + * a,b = c, by name; + * ``` + * (see page 86) + */ + IBM1672I: { + "code": "IBM1672I", + "severity": "S", + "message": "In multiple BY NAME assignments, if one target is an array of structures, then all must be.", + "fullCode": "IBM1672IS" + } as SimplePLICode, + + /** + * Only the simple assignment operator can be used to assign to a NONVARYING string + * . + * (see page 86) + */ + IBM1673I: { + "code": "IBM1673I", + "severity": "S", + "message": "The target in a compound concatenate and assign must be a VARYING or VARYINGZ string.", + "fullCode": "IBM1673IS" + } as SimplePLICode, + + /** + * The target in an assignment must not contain any UNIONs. + * (see page 86) + */ + IBM1674I: { + "code": "IBM1674I", + "severity": "S", + "message": "Target in assignment contains UNIONs.", + "fullCode": "IBM1674IS" + } as SimplePLICode, + + /** + * These two options are mutually exclusive. + * (see page 86) + */ + IBM1675I: { + "code": "IBM1675I", + "severity": "S", + "message": "FROMALIEN option cannot be used with MAIN.", + "fullCode": "IBM1675IS" + } as SimplePLICode, + + /** + * ENTRY constants representing nested procedures and ENTRY variables not declared with + * the LIMITED attribute cannot be assigned to variables with the attributes LIMITED + * ENTRY. + * (see page 86) + */ + IBM1676I: { + "code": "IBM1676I", + "severity": "S", + "message": "Source in assignment to LIMITED ENTRY must be either a non- nested ENTRY constant or another LIMITED ENTRY.", + "fullCode": "IBM1676IS" + } as SimplePLICode, + + /** + * An ENTRY constant or variable without an argument list will not be invoked and hence + * can be assigned only to an ENTRY variable. + * (see page 86) + */ + IBM1677I: { + "code": "IBM1677I", + "severity": "S", + "message": "Assignment of ENTRY to ${target type } is invalid. If the ENTRY should be invoked, an argument list must be provided.", + "fullCode": "IBM1677IS" + } as SimplePLICode, + + /** + * The target attributes conflict with the source attributes. + * (see page 87) + */ + IBM1678I: { + "code": "IBM1678I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Assignment of ${sourcetype} to ${targettype} is invalid.`, + "fullCode": "IBM1678IS" + } as ParametricPLICode, + + /** + * POINTER expressions can be converted to OFFSET only if the OFFSET is declared with + * an AREA qualifier. + * (see page 87) + */ + IBM1679I: { + "code": "IBM1679I", + "severity": "S", + "message": "Assignment of POINTER to OFFSET is invalid unless the OFFSET is declared with an AREA qualifier.", + "fullCode": "IBM1679IS" + } as SimplePLICode, + + /** + * OFFSET variables can be converted to POINTER only if the OFFSET is declared with + * an AREA qualifier. + * (see page 87) + */ + IBM1680I: { + "code": "IBM1680I", + "severity": "S", + "message": "Assignment of OFFSET to POINTER is invalid unless the OFFSET is declared with an AREA qualifier.", + "fullCode": "IBM1680IS" + } as SimplePLICode, + + /** + * A maximum of 25 preprocessor invocations can be specified in the PP option or in + * combination with the MACRO option. + * (see page 87) + */ + IBM1681I: { + "code": "IBM1681I", + "severity": "S", + "message": "The number of preprocessor invocations specified exceeds the maximum number (25) allowed.", + "fullCode": "IBM1681IS" + } as SimplePLICode, + + /** + * The target in a BY NAME assignment cannot be an array or a scalar. + * (see page 87) + */ + IBM1682I: { + "code": "IBM1682I", + "severity": "S", + "message": "The target in a BY NAME assignment must be a structure.", + "fullCode": "IBM1682IS" + } as SimplePLICode, + + /** + * For instance, in the assignment, x = y, by name, if both x and y immediately contain + * a member z, then either both x.z and y.z are structures or neither x.z and y.z is + * a structure. + * (see page 87) + */ + IBM1683I: { + "code": "IBM1683I", + "severity": "S", + "message": "Set of matching names in the expansion of BY NAME assignment must contain either all structures or no structures.", + "fullCode": "IBM1683IS" + } as SimplePLICode, + + /** + * In a BY NAME assignment, arrays with matching names must have the same number of + * dimensions. + * ```pli + * dcl + * 1 a, + * 2 b(4,5) bin(31,0), + * 2 c bin(31,0); + * dcl + * 1 x, + * 2 b(4) bin(31,0), + * 2 c bin(31,0); + * a = x, by name; + * ``` + * (see page 87) + */ + IBM1684I: { + "code": "IBM1684I", + "severity": "S", + "message": (variablename: string, variablename2: string) => `Number of dimensions in the BY NAME corresponding elements ${variablename} and ${variablename2} do not match.`, + "fullCode": "IBM1684IS" + } as ParametricPLICode, + + /** + * In a BY NAME assignment, arrays with matching names must have the same lower and + * upper bounds. + * ```pli + * dcl + * 1 a, + * 2 b(1:5) bin(31,0), + * 2 c bin(31,0); + * dcl + * 1 x, + * 2 b(0:4) bin(31,0), + * 2 c bin(31,0); + * a = x, by name; + * ``` + * (see page 87) + */ + IBM1685I: { + "code": "IBM1685I", + "severity": "S", + "message": (variablename: string, variablename2: string) => `Upper and lower bounds in BY NAME corresponding elements ${variablename} and ${variablename2} do not match.`, + "fullCode": "IBM1685IS" + } as ParametricPLICode, + + /** + * The target structure in a BY NAME assignment must not contain any UNIONs even if + * no names in those UNIONs match names in the source. The source expression also must + * contain any unions or structures containing unions. + * (see page 87) + */ + IBM1686I: { + "code": "IBM1686I", + "severity": "S", + "message": "BY NAME assignment contains UNIONs.", + "fullCode": "IBM1686IS" + } as SimplePLICode, + + /** + * If the DLI compiler option is specified, PLITDLI cannot be declared with any OPTIONS + * other than OPTIONS(ASM). + * (see page 87) + */ + IBM1687I: { + "code": "IBM1687I", + "severity": "S", + "message": (reservedname: string) => `${reservedname} cannot be declared with OPTIONS other than ASM.`, + "fullCode": "IBM1687IS" + } as ParametricPLICode, + + /** + * If the DLI compiler option is specified, PLITDLI cannot be declared with an entry + * description list. + * (see page 88) + */ + IBM1688I: { + "code": "IBM1688I", + "severity": "S", + "message": (reservedname: string) => `${reservedname} cannot be declared with an entry description list.`, + "fullCode": "IBM1688IS" + } as ParametricPLICode, + + /** + * If the DLI compiler option is specified, PLITDLI cannot be declared as a function + * . + * (see page 88) + */ + IBM1689I: { + "code": "IBM1689I", + "severity": "S", + "message": (reservedname: string) => `${reservedname} cannot be declared as a function.`, + "fullCode": "IBM1689IS" + } as ParametricPLICode, + + /** + * Functions, i.e. entrys declared with the RETURNS attribute, cannot be declared with + * OPTIONS(ASM) or OPTIONS(COBOL). + * (see page 88) + */ + IBM1690I: { + "code": "IBM1690I", + "severity": "S", + "message": (languagename: string) => `OPTIONS( ${languagename} ) is not supported for functions.`, + "fullCode": "IBM1690IS" + } as ParametricPLICode, + + /** + * In ENTRY descriptors, each array bound, string length and AREA size must be specified + * either with an asterisk or with a restricted expression that has computational type + * . + * (see page 88) + */ + IBM1691I: { + "code": "IBM1691I", + "severity": "S", + "message": "Extents in ENTRY descriptors must be asterisks or restricted expressions with computational type.", + "fullCode": "IBM1691IS" + } as SimplePLICode, + + /** + * There is no default RETURNS attribute. + * ```pli + * dcl e entry; + * a = e(); + * ``` + * (see page 88) + */ + IBM1692I: { + "code": "IBM1692I", + "severity": "S", + "message": "An ENTRY invoked as a function must have the RETURNS attribute.", + "fullCode": "IBM1692IS" + } as SimplePLICode, + + /** + * The TASK, EVENT and PRIORITY options may be specified only once in any CALL statement + * . + * (see page 88) + */ + IBM1693I: { + "code": "IBM1693I", + "severity": "S", + "message": (calloption: string) => `${calloption} option repeated in CALL statement.`, + "fullCode": "IBM1693IS" + } as ParametricPLICode, + + /** + * CALL x is invalid unless x is a built-in subroutine, an ENTRY constant, or an ENTRY + * variable. Built-in functions are not built-in references. For example, \"Call SQRT(x)\" + * is invalid. + * (see page 88) + */ + IBM1694I: { + "code": "IBM1694I", + "severity": "S", + "message": "Reference in CALL statement must not be a built-in function.", + "fullCode": "IBM1694IS" + } as SimplePLICode, + + /** + * CALL x is invalid unless x is a built-in subroutine, an ENTRY constant, or an ENTRY + * variable. + * (see page 88) + */ + IBM1695I: { + "code": "IBM1695I", + "severity": "S", + "message": "Reference in CALL statement must either be a built-in subroutine or have type ENTRY.", + "fullCode": "IBM1695IS" + } as SimplePLICode, + + /** + * All RETURN statements inside functions must specify a value to be returned. + * ```pli + * a: proc returns( fixed bin ); + * return; + * ``` + * (see page 88) + */ + IBM1696I: { + "code": "IBM1696I", + "severity": "S", + "message": "RETURN statement without an expression is invalid inside a nested PROCEDURE that specified the RETURNS attribute.", + "fullCode": "IBM1696IS" + } as SimplePLICode, + + /** + * A statement of the form RETURN(x) is valid inside only PROCEDUREs that are defined + * with a RETURNS attribute. + * (see page 88) + */ + IBM1697I: { + "code": "IBM1697I", + "severity": "S", + "message": "RETURN statement is invalid inside a PROCEDURE that did not specify the RETURNS attribute.", + "fullCode": "IBM1697IS" + } as SimplePLICode, + + /** + * A statement of the form RETURN(x) is valid inside a BEGIN block only if the PROCEDURE + * enclosing that BEGIN block has the RETURNS(BYADDR) attribute explicitly or by default + * . + * (see page 88) + */ + IBM1698I: { + "code": "IBM1698I", + "severity": "S", + "message": "RETURN statement with an expression is invalid inside a BEGIN in a PROCEDURE that does not have the RETURNS(BYADDR) attribute.", + "fullCode": "IBM1698IS" + } as SimplePLICode, + + /** + * Arrays, structures, and unions cannot be passed BYVALUE. + * (see page 88) + */ + IBM1699I: { + "code": "IBM1699I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is an aggregate. This conflicts with the BYVALUE option.", + "fullCode": "IBM1699IS" + } as SimplePLICode, + + /** + * Even AREA variables with constant size must be passed BYADDR. + * (see page 89) + */ + IBM1700I: { + "code": "IBM1700I", + "severity": "S", + "message": (attribute: string) => `${attribute} must be passed BYADDR.`, + "fullCode": "IBM1700IS" + } as ParametricPLICode, + + /** + * Only strings with constant size can be passed BYVALUE. + * (see page 89) + */ + IBM1701I: { + "code": "IBM1701I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${ENTRY name } is a string with unknown size. This conflicts with the BYVALUE option.", + "fullCode": "IBM1701IS" + } as SimplePLICode, + + /** + * Structures and union may not be returned. The following code example is invalid: + * ```pli + * dcl a entry returns( 1 union, 2 ptr, 2 ptr ); + * ``` + * (see page 89) + */ + IBM1702I: { + "code": "IBM1702I", + "severity": "S", + "message": (attributekeyword: string) => `The ${attributekeyword} attribute is invalid as a RETURNS subattribute.`, + "fullCode": "IBM1702IS" + } as ParametricPLICode, + + /** + * CALL references must be scalars. + * ```pli + * dcl ea(10) entry; + * call ea; + * ``` + * (see page 89) + */ + IBM1703I: { + "code": "IBM1703I", + "severity": "S", + "message": "Reference in CALL statement must not be an aggregate reference.", + "fullCode": "IBM1703IS" + } as SimplePLICode, + + /** + * A function can have only one argument list unless it returns an ENTRY, in which case + * it can have only two argument lists unless the returned ENTRY returns an ENTRY, + * and so on. + * (see page 89) + */ + IBM1704I: { + "code": "IBM1704I", + "severity": "S", + "message": (variablename: string) => `Too many argument lists have been specified for the variable ${variablename} .`, + "fullCode": "IBM1704IS" + } as ParametricPLICode, + + /** + * The RETURN expression must have a type that can be converted to the type indicated + * in the RETURNS option. + * ```pli + * a: proc returns( pointer ) + * return( 0 ); + * end; + * ``` + * (see page 89) + */ + IBM1705I: { + "code": "IBM1705I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `RETURN expression with attribute ${sourcetype} is invalid for RETURNS options specifying the attribute ${targettype} .`, + "fullCode": "IBM1705IS" + } as ParametricPLICode, + + /** + * The RETURN expression must have a type that can be converted to the type indicated + * in the RETURNS option. + * ```pli + * a: proc returns( pointer ) + * dcl f entry returns( pointer ); + * return( f ); + * end; + * ``` + * (see page 89) + */ + IBM1706I: { + "code": "IBM1706I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `RETURN expression with attribute ${sourcetype} is invalid for RETURNS options specifying the attribute ${targettype} . If the ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1706IS" + } as ParametricPLICode, + + /** + * Only an EXTERNAL ENTRY CONSTANT, an ENTRY CONSTANT representing a non-nested PROCEDURE, + * or an ENTRY VARIABLE with the LIMITED attribute can be specified as the RETURNS + * expression in a function that returns a LIMITED ENTRY. + * (see page 89) + */ + IBM1707I: { + "code": "IBM1707I", + "severity": "S", + "message": (sourcetype: string) => `RETURN expression with attribute ${sourcetype} is invalid for RETURNS options specifying the attribute LIMITED ENTRY.`, + "fullCode": "IBM1707IS" + } as ParametricPLICode, + + /** + * POINTER expressions can be converted to OFFSET only if the offset is declared with + * an AREA qualifier. + * (see page 89) + */ + IBM1708I: { + "code": "IBM1708I", + "severity": "S", + "message": "RETURN expression with attribute POINTER is invalid for RETURNS options specifying the attribute OFFSET since the OFFSET attribute is not declared with an AREA qualifier.", + "fullCode": "IBM1708IS" + } as SimplePLICode, + + /** + * OFFSET variables can be converted to POINTER only if the OFFSET is declared with + * an AREA qualifier. + * (see page 90) + */ + IBM1709I: { + "code": "IBM1709I", + "severity": "S", + "message": "RETURN expression with attribute OFFSET is invalid for RETURNS options specifying the attribute POINTER since the OFFSET expression is not an OFFSET variable declared with an AREA qualifier.", + "fullCode": "IBM1709IS" + } as SimplePLICode, + + /** + * In a function that returns an ordinal, the ORDINAL type in any RETURN expression + * must be the same as returned by the function. + * ```pli + * a: proc returns( ordinal color ); + * dcl i ordinal intensity; + * return( i ); + * end; + * ``` + * (see page 90) + */ + IBM1710I: { + "code": "IBM1710I", + "severity": "S", + "message": "ORDINAL type in RETURN expression and RETURNS option must match.", + "fullCode": "IBM1710IS" + } as SimplePLICode, + + /** + * The expression in a RETURN statement must not be an array, a structure, or a union + * . + * (see page 90) + */ + IBM1711I: { + "code": "IBM1711I", + "severity": "S", + "message": "Expression in RETURN statement must be scalar.", + "fullCode": "IBM1711IS" + } as SimplePLICode, + + /** + * EXTERNAL('') is invalid. + * (see page 90) + */ + IBM1712I: { + "code": "IBM1712I", + "severity": "S", + "message": "External name specification must be a non-null string.", + "fullCode": "IBM1712IS" + } as SimplePLICode, + + /** + * Functions must contain at least one RETURN statement. + * (see page 90) + */ + IBM1713I: { + "code": "IBM1713I", + "severity": "S", + "message": (functionname: string) => `Function ${functionname} contains no RETURN statement.`, + "fullCode": "IBM1713IS" + } as ParametricPLICode, + + /** + * In RETURNS descriptors, each array bound, string length, and AREA size must be specified + * with a restricted expression that has computational type. Unlike ENTRY descriptors, + * asterisks are not permitted. + * (see page 90) + */ + IBM1714I: { + "code": "IBM1714I", + "severity": "S", + "message": "Extents in RETURNS descriptors must be constants.", + "fullCode": "IBM1714IS" + } as SimplePLICode, + + /** + * RETURN statements are not permitted in an ON-unit or any of its contained BEGIN blocks + * unless the contained block is also contained in a procedure defined in the ON-unit + * . + * (see page 90) + */ + IBM1715I: { + "code": "IBM1715I", + "severity": "S", + "message": "Exit from an ON-unit via RETURN is invalid.", + "fullCode": "IBM1715IS" + } as SimplePLICode, + + /** + * Expressions in FORMAT lists, including SKIP clauses, must represent scalar values + * . + * (see page 90) + */ + IBM1716I: { + "code": "IBM1716I", + "severity": "S", + "message": "FORMAT expression must be a scalar value.", + "fullCode": "IBM1716IS" + } as SimplePLICode, + + /** + * Expressions in FORMAT lists, including SKIP clauses, must have computational type + * so that the expression can be converted to FIXED BIN(31). + * (see page 90) + */ + IBM1717I: { + "code": "IBM1717I", + "severity": "S", + "message": "FORMAT expression must have computational type.", + "fullCode": "IBM1717IS" + } as SimplePLICode, + + /** + * The expression in an IF, WHILE, UNTIL, SELECT, or WHEN clause must have computational + * type so that it can be converted to BIT(1). + * (see page 90) + */ + IBM1718I: { + "code": "IBM1718I", + "severity": "S", + "message": (sourcetype: string) => `${sourcetype} is invalid as a Boolean expression.`, + "fullCode": "IBM1718IS" + } as ParametricPLICode, + + /** + * The expression in an IF, WHILE, UNTIL, SELECT, or WHEN clause must have computational + * type so that it can be converted to BIT(1). An ENTRY cannot be used as a Boolean + * expression. If the ENTRY is a function which should be invoked, an argument list, + * even if it consists only of a left and right parenthesis, must be provided. + * (see page 90) + */ + IBM1719I: { + "code": "IBM1719I", + "severity": "S", + "message": "ENTRY is invalid as a Boolean expression. If an ENTRY should be invoked, an argument list must be provided.", + "fullCode": "IBM1719IS" + } as SimplePLICode, + + /** + * An expression used in calculating the size of a variable must not depend on any values + * that the variable may have because those values do not exist until storage can be + * allocated for the variable. + * (see page 90) + */ + IBM1720I: { + "code": "IBM1720I", + "severity": "S", + "message": "Expression for calculating size of variable with adjustable extents is 90 too complicated. Variable may be defined in terms of itself.", + "fullCode": "IBM1720IS" + } as SimplePLICode, + + /** + * The compiler's space for evaluating expressions has been exhausted. Rewrite the expression + * in terms of simpler expressions. + * (see page 91) + */ + IBM1721I: { + "code": "IBM1721I", + "severity": "S", + "message": "Expression contains too many nested subexpressions.", + "fullCode": "IBM1721IS" + } as SimplePLICode, + + /** + * Compilation will terminate when the number of messages has exceeded the limit set + * in the MAXMSG compiler option. + * (see page 91) + */ + IBM1722I: { + "code": "IBM1722I", + "severity": "S", + "message": "The number of error messages allowed by the MAXMSG option has been exceeded.", + "fullCode": "IBM1722IS" + } as SimplePLICode, + + /** + * The length of the string literal produced by concatenating two string literals must + * not be greater than the maximum allowed for a literal with the derived string type + * . + * (see page 91) + */ + IBM1723I: { + "code": "IBM1723I", + "severity": "S", + "message": "Result of concatenating two literals is too long.", + "fullCode": "IBM1723IS" + } as SimplePLICode, + + /** + * One of the operands in an addition must be computational and the other must be either + * computational or a locator. + * (see page 91) + */ + IBM1724I: { + "code": "IBM1724I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Addition of ${sourcetype} and ${targettype} is invalid.`, + "fullCode": "IBM1724IS" + } as ParametricPLICode, + + /** + * An ENTRY cannot be used as an arithmetic operand. If the ENTRY is a function which + * should be invoked, an argument list, even if it consists only of a left and right + * parenthesis, must be provided. + * (see page 91) + */ + IBM1725I: { + "code": "IBM1725I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Addition of ${sourcetype} and ${targettype} is invalid. If an ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1725IS" + } as ParametricPLICode, + + /** + * The first operand in a subtraction must be computational or a locator. The second + * operand can be a locator only if the first is a locator. Otherwise, the second operand + * must be computational. + * (see page 91) + */ + IBM1726I: { + "code": "IBM1726I", + "severity": "S", + "message": (targettype: string, sourcetype: string) => `Subtraction of ${targettype} from ${sourcetype} is invalid.`, + "fullCode": "IBM1726IS" + } as ParametricPLICode, + + /** + * An ENTRY cannot be used as an arithmetic operand. If the ENTRY is a function which + * should be invoked, an argument list, even if it consists only of a left and right + * parenthesis, must be provided. + * (see page 91) + */ + IBM1727I: { + "code": "IBM1727I", + "severity": "S", + "message": (targettype: string, sourcetype: string) => `Subtraction of ${targettype} from ${sourcetype} is invalid. If an ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1727IS" + } as ParametricPLICode, + + /** + * Both operands in a multiplication must be computational. + * (see page 91) + */ + IBM1728I: { + "code": "IBM1728I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Multiplication of ${sourcetype} by ${targettype} is invalid.`, + "fullCode": "IBM1728IS" + } as ParametricPLICode, + + /** + * An ENTRY cannot be used as an arithmetic operand. If the ENTRY is a function which + * should be invoked, an argument list, even if it consists only of a left and right + * parenthesis, must be provided. + * (see page 91) + */ + IBM1729I: { + "code": "IBM1729I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Multiplication of ${sourcetype} by ${targettype} is invalid. If an ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1729IS" + } as ParametricPLICode, + + /** + * Both operands in a division must be computational. + * (see page 91) + */ + IBM1730I: { + "code": "IBM1730I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Division of ${sourcetype} by ${targettype} is invalid.`, + "fullCode": "IBM1730IS" + } as ParametricPLICode, + + /** + * An ENTRY cannot be used as an arithmetic operand. If the ENTRY is a function which + * should be invoked, an argument list, even if it consists only of a left and right + * parenthesis, must be provided. + * (see page 91) + */ + IBM1731I: { + "code": "IBM1731I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Division of ${sourcetype} by ${targettype} is invalid. If an ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1731IS" + } as ParametricPLICode, + + /** + * Aggregate expressions are supported only as the source in an assignment statement + * and, with some limitations, as an argument to the ANY or ALL built-in functions + * . + * (see page 92) + */ + IBM1732I: { + "code": "IBM1732I", + "severity": "S", + "message": "Unsupported use of aggregate expression.", + "fullCode": "IBM1732IS" + } as SimplePLICode, + + /** + * Only expressions having string or numeric type may be concatenated. + * (see page 92) + */ + IBM1733I: { + "code": "IBM1733I", + "severity": "S", + "message": "Concatenate operands must have computational type.", + "fullCode": "IBM1733IS" + } as SimplePLICode, + + /** + * The prefix operators (plus, minus, and logical not) may be applied only to expressions + * having string or numeric type. + * (see page 92) + */ + IBM1734I: { + "code": "IBM1734I", + "severity": "S", + "message": "Operand in a prefix expression is not computational.", + "fullCode": "IBM1734IS" + } as SimplePLICode, + + /** + * No relational operations are defined for AREA variables. + * (see page 92) + */ + IBM1735I: { + "code": "IBM1735I", + "severity": "S", + "message": "AREA variables may not be compared.", + "fullCode": "IBM1735IS" + } as SimplePLICode, + + /** + * Computational types can be compared only with other computational types, and non-computational + * types can be compared only with like non-computational types. + * (see page 92) + */ + IBM1736I: { + "code": "IBM1736I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `Comparison of ${sourcetype} to ${targettype} is invalid.`, + "fullCode": "IBM1736IS" + } as ParametricPLICode, + + /** + * ENTRYs can be compared only with other ENTRYs. If the ENTRY is a function which should + * be invoked, an argument list, even if it consists only of a left and right parenthesis, + * must be provided. + * (see page 92) + */ + IBM1737I: { + "code": "IBM1737I", + "severity": "S", + "message": "Comparison of ENTRY to ${target type } is invalid. If the ENTRY should be invoked, an argument list must be provided.", + "fullCode": "IBM1737IS" + } as SimplePLICode, + + /** + * ENTRYs can be compared only with other ENTRYs. If the ENTRY is a function which should + * be invoked, an argument list, even if it consists only of a left and right parenthesis, + * must be provided. + * (see page 92) + */ + IBM1738I: { + "code": "IBM1738I", + "severity": "S", + "message": (sourcetype: string) => `Comparison of ${sourcetype} to ENTRY is invalid. If the ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1738IS" + } as ParametricPLICode, + + /** + * No relational operations are defined for TASK variables. + * (see page 92) + */ + IBM1739I: { + "code": "IBM1739I", + "severity": "S", + "message": "TASK variables may not be compared.", + "fullCode": "IBM1739IS" + } as SimplePLICode, + + /** + * An OFFSET can be compared with a POINTER as long as the OFFSET can be converted to + * a POINTER. This requires that the OFFSET is declared with an AREA qualifier. + * (see page 92) + */ + IBM1740I: { + "code": "IBM1740I", + "severity": "S", + "message": "Comparison of an OFFSET to a POINTER is invalid since the OFFSET comparand is not an OFFSET variable declared with an AREA qualifier.", + "fullCode": "IBM1740IS" + } as SimplePLICode, + + /** + * Comparisons of strongly-typed variables are invalid unless both have the same type + * . + * ```pli + * dcl hp handle point; + * dcl hr handle rectangle; + * if hp = hr then + * ... + * ``` + * (see page 92) + */ + IBM1741I: { + "code": "IBM1741I", + "severity": "S", + "message": "Operands in comparison have differing strong types.", + "fullCode": "IBM1741IS" + } as SimplePLICode, + + /** + * ORDINALs cannot be compared with other ORDINALs having a different ORDINAL type. + * (see page 92) + */ + IBM1742I: { + "code": "IBM1742I", + "severity": "S", + "message": "Compared ORDINALs must have the same ORDINAL type.", + "fullCode": "IBM1742IS" + } as SimplePLICode, + + /** + * Assignments of strongly-typed variables are invalid unless both have the same type + * . + * (see page 92) + */ + IBM1743I: { + "code": "IBM1743I", + "severity": "S", + "message": "Source and target in assignment have differing strong types.", + "fullCode": "IBM1743IS" + } as SimplePLICode, + + /** + * ORDINALs cannot be assigned to other ORDINALs having different ORDINAL type. + * (see page 93) + */ + IBM1744I: { + "code": "IBM1744I", + "severity": "S", + "message": "Conversion of ORDINALs is invalid unless both have the same ORDINAL type.", + "fullCode": "IBM1744IS" + } as SimplePLICode, + + /** + * For instance, in a function that returns a typed structure, any RETURN expression + * must have the same structure type. + * (see page 93) + */ + IBM1745I: { + "code": "IBM1745I", + "severity": "S", + "message": "In a function that returns a strong type, the type in any RETURN expression must be the same as that returned by the function.", + "fullCode": "IBM1745IS" + } as SimplePLICode, + + /** + * These expressions must be reducible to a constant at compile-time. + * ```pli + * dcl a fixed bin static nonassignable + * init(0); + * dcl m fixed bin value( a ); + * dcl n fixed bin static init( a ); + * ``` + * (see page 93) + */ + IBM1746I: { + "code": "IBM1746I", + "severity": "S", + "message": "VALUE, VALUELIST, VALUERANGE, and STATIC INITIAL expressions must be constant.", + "fullCode": "IBM1746IS" + } as SimplePLICode, + + /** + * This is a compiler restriction. Reorder the declarations and blocks in your program. + * For example, the following declarations should be in reverse order. + * ```pli + * dcl a char( csize( x, y ) ); + * dcl csize entry( char(2), fixed bin ) + * returns( fixed bin ); + * ``` + * (see page 93) + */ + IBM1747I: { + "code": "IBM1747I", + "severity": "S", + "message": "Function cannot be used before the function's descriptor list has been scanned.", + "fullCode": "IBM1747IS" + } as SimplePLICode, + + /** + * Reorder the declarations in your program. For example, the following declarations + * should be in reverse order. + * ```pli + * dcl a char( length(b) ) auto; + * dcl b char( 10 ) auto; + * ``` + * (see page 93) + */ + IBM1748I: { + "code": "IBM1748I", + "severity": "S", + "message": "Extents of automatic variables must not depend on the extents of automatic variables declared later in the same block.", + "fullCode": "IBM1748IS" + } as SimplePLICode, + + /** + * Aggregate expressions are not valid as INITIAL and VALUE expressions. + * (see page 93) + */ + IBM1749I: { + "code": "IBM1749I", + "severity": "S", + "message": "VALUE and INITIAL expressions must be scalars.", + "fullCode": "IBM1749IS" + } as SimplePLICode, + + /** + * The INITIAL attribute is supported for a STATIC LABEL variable only if the variable + * is a scalar or an array of scalars. + * (see page 93) + */ + IBM1750I: { + "code": "IBM1750I", + "severity": "S", + "message": "INITIAL attribute is invalid for the STATIC LABEL variable ${variable name } since it has the MEMBER attribute.", + "fullCode": "IBM1750IS" + } as SimplePLICode, + + /** + * ENTRY variables that don't have the LIMITED attribute require block activation information, + * and hence they cannot be initialized at compile-time. + * (see page 93) + */ + IBM1751I: { + "code": "IBM1751I", + "severity": "S", + "message": "INITIAL attribute is valid for the STATIC ENTRY variable ${variable name } only if it has the LIMITED attribute.", + "fullCode": "IBM1751IS" + } as SimplePLICode, + + /** + * FORMAT variables require block activation information, and hence they cannot be initialized + * at compile-time. If the variable were not a member of a structure, the storage class + * would be changed to AUTOMATIC and an error message would be issued instead. + * (see page 93) + */ + IBM1753I: { + "code": "IBM1753I", + "severity": "S", + "message": "INITIAL attribute is invalid for the STATIC FORMAT variable ${variable name } .", + "fullCode": "IBM1753IS" + } as SimplePLICode, + + /** + * Since an asterisk iteration factor completes the initialization of a variable, it + * cannot be followed by more initial values. + * ```pli + * dcl a(10) fixed bin init( 1, 2, (*) 0, + * 8 ); + * ``` + * (see page 93) + */ + IBM1754I: { + "code": "IBM1754I", + "severity": "S", + "message": (variablename: string) => `An asterisk iteration factor can be applied only to the last expression in the INITIAL item list for ${variablename} .`, + "fullCode": "IBM1754IS" + } as ParametricPLICode, + + /** + * An asterisk iteration can be used only in a non-nested INITIAL item list. The following + * example is invalid. + * ```pli + * dcl a(20) fixed bin init( (2) ( 1, (*) + * 2 ) ); + * ``` + * (see page 94) + */ + IBM1755I: { + "code": "IBM1755I", + "severity": "S", + "message": (variablename: string) => `An asterisk iteration factor cannot be used in the nested INITIAL item list for ${variablename} .`, + "fullCode": "IBM1755IS" + } as ParametricPLICode, + + /** + * Only arrays can have an INITIAL list with more than one element. + * ```pli + * dcl a fixed bin init( 1, 2 ); + * ``` + * (see page 94) + */ + IBM1756I: { + "code": "IBM1756I", + "severity": "S", + "message": (variablename: string) => `The scalar variable ${variablename} has an INITIAL list with more than one item.`, + "fullCode": "IBM1756IS" + } as ParametricPLICode, + + /** + * Change the storage class to AUTOMATIC. + * ```pli + * lx:; + * subproc: proc; + * dcl la static label init( lx ); + * end; + * ``` + * (see page 94) + */ + IBM1757I: { + "code": "IBM1757I", + "severity": "S", + "message": (variablename: string) => `LABEL constant in STATIC INITIAL for the variable ${variablename} must be in the same block as the LABEL being initialized.`, + "fullCode": "IBM1757IS" + } as ParametricPLICode, + + /** + * If more than one element in a STATIC UNION had an INITIAL value, it would not be + * clear which should take precedence. + * ```pli + * dcl + * 1 a union static, + * 2 b fixed bin(31) init( 17 ), + * 2 c fixed bin(15) init( 19 ); + * ``` + * (see page 94) + */ + IBM1758I: { + "code": "IBM1758I", + "severity": "S", + "message": (variablename: string) => `Only one element in the STATIC UNION ${variablename} may have the INITIAL attribute.`, + "fullCode": "IBM1758IS" + } as ParametricPLICode, + + /** + * The only supported INITIAL values for a STATIC UNALIGNED BIT variable with inherited + * dimensions are bit strings equal to ''b. + * ```pli + * dcl + * 1 a(10,2) static, + * 2 b1 bit(1) init( (20) '1'b ), + * 2 b2 bit(1) init( (20) '0'b ); + * ``` + * (see page 94) + */ + IBM1759I: { + "code": "IBM1759I", + "severity": "S", + "message": "Non-null INITIAL values are not supported for the STATIC NONCONNECTED array ${variable name } since it has the attributes UNALIGNED BIT.", + "fullCode": "IBM1759IS" + } as SimplePLICode, + + /** + * Replace the subscripted LABEL with an unsubscripted one or change the storage class + * to AUTOMATIC. + * ```pli + * lx(1):; + * lx(2):; + * dcl la(2) static label init( lx(2), + * lx(1) ); + * ``` + * (see page 94) + */ + IBM1760I: { + "code": "IBM1760I", + "severity": "S", + "message": (variablename: string) => `LABEL constant in the STATIC INITIAL list for ${variablename} must not be an element of a LABEL CONSTANT array.`, + "fullCode": "IBM1760IS" + } as ParametricPLICode, + + /** + * The variable y in DCL x ENTRY LIMITED INIT(y) must not be FETCHABLE; y must not be + * used in a FETCH or RELEASE statement, and y must not have the OPTIONS(FETCHABLE) + * attribute. + * (see page 94) + */ + IBM1761I: { + "code": "IBM1761I", + "severity": "S", + "message": (variablename: string) => `ENTRY reference in INITIAL clause for the STATIC ENTRY variable ${variablename} must not be FETCHABLE.`, + "fullCode": "IBM1761IS" + } as ParametricPLICode, + + /** + * Iteration factors in INITIAL lists must have numeric or string types. + * (see page 95) + */ + IBM1762I: { + "code": "IBM1762I", + "severity": "S", + "message": "INITIAL iteration factor must have computational type.", + "fullCode": "IBM1762IS" + } as SimplePLICode, + + /** + * An iteration factor in an INITIAL list must not be an array, structure, or union + * . + * (see page 95) + */ + IBM1763I: { + "code": "IBM1763I", + "severity": "S", + "message": "INITIAL iteration factor must be a scalar.", + "fullCode": "IBM1763IS" + } as SimplePLICode, + + /** + * Strings with nonconstant length must be passed and received by address. + * ```pli + * a: proc( x ); + * dcl x char(*) byvalue; + * ``` + * (see page 95) + */ + IBM1764I: { + "code": "IBM1764I", + "severity": "S", + "message": "The BYVALUE attribute is invalid for strings of nonconstant length.", + "fullCode": "IBM1764IS" + } as SimplePLICode, + + /** + * Named strings must have a constant length or a length determined from their VALUE + * . + * ```pli + * dcl a fixed bin automatic; + * dcl s char(a) value('variable length'); + * ``` + * (see page 95) + */ + IBM1765I: { + "code": "IBM1765I", + "severity": "S", + "message": "Length of string with the VALUE attribute must be a constant or an asterisk.", + "fullCode": "IBM1765IS" + } as SimplePLICode, + + /** + * Named constants must be evaluated before they are used. Reorder the declarations + * so that each named constant is declared before its first use. + * ```pli + * dcl a char(n) static init( 'tooSoon' ); + * dcl n fixed bin value( 7 ); + * ``` + * (see page 95) + */ + IBM1766I: { + "code": "IBM1766I", + "severity": "S", + "message": (variablename: string) => `VALUE for ${variablename} must be evaluated before its first use.`, + "fullCode": "IBM1766IS" + } as ParametricPLICode, + + /** + * Named constants may not be used as control variables in DO loops. + * ```pli + * dcl n fixed bin value( 7 ); + * do n = 1 to 5; + * ``` + * (see page 95) + */ + IBM1767I: { + "code": "IBM1767I", + "severity": "S", + "message": "Control variable in DO statement must not be a named constant.", + "fullCode": "IBM1767IS" + } as SimplePLICode, + + /** + * Constants may not be used as control variables in DO loops. + * ```pli + * dcl ex external entry, (ev1, ev2) entry; + * do ex = ev1, ev2; + * ``` + * (see page 95) + */ + IBM1768I: { + "code": "IBM1768I", + "severity": "S", + "message": "Control variable in DO statement must have VARIABLE attribute.", + "fullCode": "IBM1768IS" + } as SimplePLICode, + + /** + * If the control variable in a DO loop has POINTER type, the TO expression must have + * POINTER type. Implicit conversion from OFFSET to POINTER is not supported in this + * context. + * (see page 95) + */ + IBM1769I: { + "code": "IBM1769I", + "severity": "S", + "message": "Control variable has type POINTER, but TO expression does not.", + "fullCode": "IBM1769IS" + } as SimplePLICode, + + /** + * In a DO loop with a TO clause, the control variable must have a type that allows + * a comparison of less than and greater than. This is possible only for computational + * and locator types. + * (see page 95) + */ + IBM1770I: { + "code": "IBM1770I", + "severity": "S", + "message": "Control variable in loop with TO clause must have computational or locator type.", + "fullCode": "IBM1770IS" + } as SimplePLICode, + + /** + * SUBSTR and UNSPEC may be used as pseudovariables in DO-loops only if their derived + * length is known at compile time. + * (see page 95) + */ + IBM1771I: { + "code": "IBM1771I", + "severity": "S", + "message": (variablename: string) => `The ${variablename} built-in function may be used as a pseudovariable in a DO-loop only if the length of the pseudovariable reference is known at compile time.`, + "fullCode": "IBM1771IS" + } as ParametricPLICode, + + /** + * In a DO loop of the form DO a = b TO c, b must be a scalar. + * (see page 95) + */ + IBM1772I: { + "code": "IBM1772I", + "severity": "S", + "message": "Source in DO loop initialization must be scalar.", + "fullCode": "IBM1772IS" + } as SimplePLICode, + + /** + * In a DO loop of the form DO x = .., x must be a scalar. + * (see page 96) + */ + IBM1773I: { + "code": "IBM1773I", + "severity": "S", + "message": "Control variable in DO statement must be a scalar.", + "fullCode": "IBM1773IS" + } as SimplePLICode, + + /** + * In a DO loop of the form DO x = .., if x is a string or an area, then it must have + * constant size or must be static, automatic, or defined. + * (see page 96) + */ + IBM1774I: { + "code": "IBM1774I", + "severity": "S", + "message": "Compiler restriction: control variable in DO statement must not be a BASED or CONTROLLED string or area that has non-constant extent.", + "fullCode": "IBM1774IS" + } as SimplePLICode, + + /** + * The expression in the BY clause of a DO loop must have a string or numeric type. + * It cannot have a locator type because it must be comparable to zero. + * (see page 96) + */ + IBM1775I: { + "code": "IBM1775I", + "severity": "S", + "message": "BY expression must have computational type.", + "fullCode": "IBM1775IS" + } as SimplePLICode, + + /** + * The expression in the BY clause of a DO loop must be REAL. + * ```pli + * dcl z cplx float; + * do jx = 1 to 10 by z; + * ``` + * (see page 96) + */ + IBM1776I: { + "code": "IBM1776I", + "severity": "S", + "message": "BY expression must not be COMPLEX.", + "fullCode": "IBM1776IS" + } as SimplePLICode, + + /** + * The expression in the TO clause of a DO loop must be REAL + * ```pli + * dcl z cplx float; + * do jx = 1 to z; + * ``` + * (see page 96) + */ + IBM1777I: { + "code": "IBM1777I", + "severity": "S", + "message": "TO expression must not be COMPLEX.", + "fullCode": "IBM1777IS" + } as SimplePLICode, + + /** + * In a DO loop with a TO clause, the control variable must have a type that allows + * a comparison of less than and greater than. This is possible for numeric types only + * if the numeric type is REAL. + * (see page 96) + */ + IBM1778I: { + "code": "IBM1778I", + "severity": "S", + "message": "Control variable in loop with TO clause must not be COMPLEX.", + "fullCode": "IBM1778IS" + } as SimplePLICode, + + /** + * The expression in the TO clause of a DO loop must have a string or numeric type. + * (see page 96) + */ + IBM1779I: { + "code": "IBM1779I", + "severity": "S", + "message": "TO expression must have computational type.", + "fullCode": "IBM1779IS" + } as SimplePLICode, + + /** + * ON ANYCONDITION may be used to trap conditions not otherwise trapped, but ANYCONDITION + * may not be signalled. + * (see page 96) + */ + IBM1780I: { + "code": "IBM1780I", + "severity": "S", + "message": "SIGNAL ANYCONDITION is invalid.", + "fullCode": "IBM1780IS" + } as SimplePLICode, + + /** + * Bitwise operands must have a computational type. + * (see page 96) + */ + IBM1781I: { + "code": "IBM1781I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `And, or and exclusive-or of ${sourcetype} and ${targettype} is invalid.`, + "fullCode": "IBM1781IS" + } as ParametricPLICode, + + /** + * An ENTRY cannot be used as a bitwise operand. If the ENTRY is a function which should + * be invoked, an argument list, even if it consists only of a left and right parenthesis, + * must be provided. + * (see page 96) + */ + IBM1782I: { + "code": "IBM1782I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `And, or and exclusive-or of ${sourcetype} and ${targettype} is invalid. If an ENTRY should be invoked, an argument list must be provided.`, + "fullCode": "IBM1782IS" + } as ParametricPLICode, + + /** + * A variable declared as BASED instead of as BASED( reference ) must always be explicitly + * qualified. This is necessary even when the variable is an argument to built-in functions + * such as STORAGE. + * (see page 96) + */ + IBM1783I: { + "code": "IBM1783I", + "severity": "S", + "message": "BASED variable without an implicit qualifier must be explicitly qualified.", + "fullCode": "IBM1783IS" + } as SimplePLICode, + + /** + * Functions, but not subprocedures, can be used as locator qualifiers (and then only + * if they return a locator). + * (see page 96) + */ + IBM1784I: { + "code": "IBM1784I", + "severity": "S", + "message": (variablename: string) => `The ENTRY ${variablename} may not be used as a locator qualifier since it does not have the RETURNS attribute.`, + "fullCode": "IBM1784IS" + } as ParametricPLICode, + + /** + * Only scalars can be used as locator qualifiers. + * (see page 97) + */ + IBM1785I: { + "code": "IBM1785I", + "severity": "S", + "message": (variablename: string) => `The variable ${variablename} is used as a locator qualifier, but it is not a scalar.`, + "fullCode": "IBM1785IS" + } as ParametricPLICode, + + /** + * The named built-in function cannot be used as a locator qualifier since it does not + * return a POINTER. + * (see page 97) + */ + IBM1786I: { + "code": "IBM1786I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} built-in function may not be used as a locator qualifier.`, + "fullCode": "IBM1786IS" + } as ParametricPLICode, + + /** + * x(...)->y is invalid unless x returns a POINTER or an OFFSET declared with a qualifying + * AREA. + * (see page 97) + */ + IBM1787I: { + "code": "IBM1787I", + "severity": "S", + "message": (variablename: string) => `The ENTRY ${variablename} may not be used as a locator qualifier.`, + "fullCode": "IBM1787IS" + } as ParametricPLICode, + + /** + * Only POINTERs and OFFSETs declared with a qualifying AREA can be used as locator + * qualifiers. + * (see page 97) + */ + IBM1789I: { + "code": "IBM1789I", + "severity": "S", + "message": (variablename: string) => `The qualifier ${variablename} does not have locator type.`, + "fullCode": "IBM1789IS" + } as ParametricPLICode, + + /** + * Locator qualification is valid only for BASED variables. + * (see page 97) + */ + IBM1790I: { + "code": "IBM1790I", + "severity": "S", + "message": (variablename: string) => `Locator qualification is invalid for ${variablename} .`, + "fullCode": "IBM1790IS" + } as ParametricPLICode, + + /** + * All references must be unambiguous. + * (see page 97) + */ + IBM1791I: { + "code": "IBM1791I", + "severity": "S", + "message": (referencename: string) => `The locator qualified reference ${referencename} is ambiguous.`, + "fullCode": "IBM1791IS" + } as ParametricPLICode, + + /** + * Locator qualified references must be explicitly declared. BASED variables may not + * be implicitly declared. + * (see page 97) + */ + IBM1792I: { + "code": "IBM1792I", + "severity": "S", + "message": (referencename: string) => `The locator qualified reference ${referencename} is unknown.`, + "fullCode": "IBM1792IS" + } as ParametricPLICode, + + /** + * Only IMAG, REAL, SUBSTR and UNSPEC may be used as pseudovariables in DO loops. + * (see page 97) + */ + IBM1793I: { + "code": "IBM1793I", + "severity": "S", + "message": (variablename: string) => `The ${variablename} built-in function may not be used as a pseudovariable in a DO-loop.`, + "fullCode": "IBM1793IS" + } as ParametricPLICode, + + /** + * An implicitly qualified variable must require no more than 15 qualifiers to be completely + * qualified. If it requires more, this may indicate its qualifiers are too interdependent + * . + * ```pli + * dcl a pointer based(b); + * dcl b pointer based(a); + * a = null(); + * ``` + * (see page 97) + */ + IBM1794I: { + "code": "IBM1794I", + "severity": "S", + "message": "Too many implicit locators are needed to resolve the qualification for a variable. Variable may be based on itself.", + "fullCode": "IBM1794IS" + } as SimplePLICode, + + /** + * An OFFSET variable can be used as a locator qualifier only if it can be converted + * to a pointer value. This requires that the offset be declared with an AREA qualification + * . + * (see page 97) + */ + IBM1795I: { + "code": "IBM1795I", + "severity": "S", + "message": "The OFFSET variable ${variable name } may not be used as a locator qualifier since it was not declared with an AREA specification.", + "fullCode": "IBM1795IS" + } as SimplePLICode, + + /** + * Arrays, structures, and unions may not be used as locator qualifiers. + * (see page 97) + */ + IBM1796I: { + "code": "IBM1796I", + "severity": "S", + "message": "Qualifier must be a scalar.", + "fullCode": "IBM1796IS" + } as SimplePLICode, + + /** + * The REFER option cannot be used in a BASED variable which also has an extent that + * is set by a non-constant expression. + * (see page 97) + */ + IBM1797I: { + "code": "IBM1797I", + "severity": "S", + "message": "BASED variables may not contain extents with nonconstant values if other extents use the REFER option.", + "fullCode": "IBM1797IS" + } as SimplePLICode, + + /** + * The picture character F specifies a picture scaling factor for fixed-point decimal + * numbers. The number of digits following the V picture character, minus the integer + * specified with F, must be between -128 and 127. + * (see page 97) + */ + IBM1798I: { + "code": "IBM1798I", + "severity": "S", + "message": "Invalid scale factor in PICTURE specification.", + "fullCode": "IBM1798IS" + } as SimplePLICode, + + /** + * The picture specification can contain only A X 9 for the Character Data, and only + * 9 V Z * , . \/ B S + - $ CR DB Y K E F < > for the Numeric Data. The characters + * between the insertion characters < > are not affected by this rule. + * (see page 98) + */ + IBM1799I: { + "code": "IBM1799I", + "severity": "S", + "message": "Invalid characters in PICTURE specification.", + "fullCode": "IBM1799IS" + } as SimplePLICode, + + /** + * The picture character F specifies a picture scaling factor for fixed-point decimal + * numbers. The format is F(n) where n can be any signed integer between -128 and 127 + * inclusively. + * (see page 98) + */ + IBM1800I: { + "code": "IBM1800I", + "severity": "S", + "message": "Invalid characters in the F scaling factor.", + "fullCode": "IBM1800IS" + } as SimplePLICode, + + /** + * The picture specification can contain only A, X, or 9 for the character data. Other + * characters are not permitted. + * (see page 98) + */ + IBM1801I: { + "code": "IBM1801I", + "severity": "S", + "message": "A character PICTURE string may have only A, X, or 9.", + "fullCode": "IBM1801IS" + } as SimplePLICode, + + /** + * The number of digits for the precision field within a numeric data picture specification + * must be between one and the maximum allowed by the LIMITS(FIXEDDEC) option. + * (see page 98) + */ + IBM1802I: { + "code": "IBM1802I", + "severity": "S", + "message": "Invalid precision in PICTURE fixed decimal precision.", + "fullCode": "IBM1802IS" + } as SimplePLICode, + + /** + * T, I, or R are the overpunched characters in the picture specification. Only one + * overpunched character can appear in the specification for a fixed point number. + * A floating-point specification can contain two (One in the mantissa field and one + * in the exponent field). + * (see page 98) + */ + IBM1803I: { + "code": "IBM1803I", + "severity": "S", + "message": "Too many T, I, or R appear in the PICTURE specification.", + "fullCode": "IBM1803IS" + } as SimplePLICode, + + /** + * Character PICTURE specifications are not permitted in C-format items. + * (see page 98) + */ + IBM1804I: { + "code": "IBM1804I", + "severity": "S", + "message": "PICTURE specifications in C- format items must be arithmetic.", + "fullCode": "IBM1804IS" + } as SimplePLICode, + + /** + * The precision field within a numeric data picture specification must contain at least + * one digit. + * (see page 98) + */ + IBM1805I: { + "code": "IBM1805I", + "severity": "S", + "message": "Precision in numeric PICTURE must NOT be less than 1.", + "fullCode": "IBM1805IS" + } as SimplePLICode, + + /** + * The precision in the fixed decimal picture specification must not exceed that specified + * in the LIMITS compiler option. + * (see page 98) + */ + IBM1806I: { + "code": "IBM1806I", + "severity": "S", + "message": "The precision in FIXED DECIMAL PICTURE is too big.", + "fullCode": "IBM1806IS" + } as SimplePLICode, + + /** + * The precision in the float decimal picture specification is limited by the hardware + * to 18 digits. + * (see page 98) + */ + IBM1807I: { + "code": "IBM1807I", + "severity": "S", + "message": "Precision in FLOAT DECIMAL PICTURE is too big.", + "fullCode": "IBM1807IS" + } as SimplePLICode, + + /** + * Null picture strings (''P) are invalid. + * (see page 98) + */ + IBM1808I: { + "code": "IBM1808I", + "severity": "S", + "message": "PICTURE string is empty.", + "fullCode": "IBM1808IS" + } as SimplePLICode, + + /** + * The number of digits in the exponent of the float decimal picture specification is + * limited to 4. + * (see page 98) + */ + IBM1809I: { + "code": "IBM1809I", + "severity": "S", + "message": "Exponent in FLOAT PICTURE is too long. Exponent will be truncated to fit.", + "fullCode": "IBM1809IS" + } as SimplePLICode, + + /** + * The exponent in the float decimal picture specification is missing. It must be entered + * even if it is zero. + * (see page 98) + */ + IBM1810I: { + "code": "IBM1810I", + "severity": "S", + "message": "Exponent in FLOAT PICTURE has no digits.", + "fullCode": "IBM1810IS" + } as SimplePLICode, + + /** + * V specifies an implicit decimal point. Therefore, it is not permitted in the exponent + * field. + * (see page 98) + */ + IBM1811I: { + "code": "IBM1811I", + "severity": "S", + "message": "Exponent in PICTURE specification cannot contain V.", + "fullCode": "IBM1811IS" + } as SimplePLICode, + + /** + * Credit (CR), debit (DB), and scale factor (F) are only allowed in the FIXED picture + * specification. + * (see page 99) + */ + IBM1812I: { + "code": "IBM1812I", + "severity": "S", + "message": "FLOAT PICTURE cannot contain CR, DB or F.", + "fullCode": "IBM1812IS" + } as SimplePLICode, + + /** + * The compiler restrictions on the length of the picture specification are: + * ```pli + * fixed decimal: 254 + * float decimal: 253 + * character data: 511 + * ``` + * (see page 99) + */ + IBM1813I: { + "code": "IBM1813I", + "severity": "S", + "message": "PICTURE specification is too long. Excess characters are truncated on the right.", + "fullCode": "IBM1813IS" + } as SimplePLICode, + + /** + * The floating insertion string is delimited by < >. Floating is done by the > character. + * The string can contain any character with one exception: the delimiters themselves. + * In order to include the characters < and > in the floating insertion string, these + * angle brackets must be used in an escaped format. << must be used to specify the + * character <, and <> must be used to specify the character >. So, for example, ccc> + * denotes the insertion string aaaccc. + * (see page 99) + */ + IBM1814I: { + "code": "IBM1814I", + "severity": "S", + "message": "PICTURE string has an invalid floating insertion character string.", + "fullCode": "IBM1814IS" + } as SimplePLICode, + + /** + * Built-in subroutines cannot be used as functions - they can only be called. For instance, + * the following code is invalid + * ```pli + * dcl pliretc builtin; + * rc = pliretc( 16 ); + * ``` + * (see page 99) + */ + IBM1815I: { + "code": "IBM1815I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} is a built-in subroutine. It should be used only in CALL statements and not as a function.`, + "fullCode": "IBM1815IS" + } as ParametricPLICode, + + /** + * The expression must be arithmetic or string. + * ```pli + * dcl x label variable; + * put list( x ); + * ``` + * (see page 99) + */ + IBM1816I: { + "code": "IBM1816I", + "severity": "S", + "message": (keyword: string, variablename: string) => `${keyword} item ${variablename} is not computational.`, + "fullCode": "IBM1816IS" + } as ParametricPLICode, + + /** + * The KEYTO reference should have the data type character or graphic. The reference + * can also be a variable with a non-numeric picture string specification. + * (see page 99) + */ + IBM1817I: { + "code": "IBM1817I", + "severity": "S", + "message": "The KEYTO reference must be of type CHARACTER or GRAPHIC.", + "fullCode": "IBM1817IS" + } as SimplePLICode, + + /** + * An option on the I\/O statement conflicts with prior options. + * ```pli + * open file(f1) input output; + * read file(f) into(x) set(p); + * ``` + * (see page 99) + */ + IBM1818I: { + "code": "IBM1818I", + "severity": "S", + "message": "${I/Ooption } conflicts with previous options on the ${I/Ostmt } statement.", + "fullCode": "IBM1818IS" + } as SimplePLICode, + + /** + * Each option may be specified only once. + * ```pli + * read file(f1) ignore(1) ignore(2); + * ``` + * (see page 99) + */ + IBM1819I: { + "code": "IBM1819I", + "severity": "S", + "message": "The ${I/Ooption } option is multiply specified on the ${I/Ostmt } statement.", + "fullCode": "IBM1819IS" + } as SimplePLICode, + + /** + * A required statement element has not been specified. + * ```pli + * open output; + * write file(x); + * ``` + * (see page 99) + */ + IBM1820I: { + "code": "IBM1820I", + "severity": "S", + "message": "Mandatory ${I/Ooption } option not specified on the ${I/Ostmt } statement.", + "fullCode": "IBM1820IS" + } as SimplePLICode, + + /** + * An invalid scalar or aggregate reference has been specified for the FROM or INTO + * clause in a record 99 I\/O statement. The example below will cause this message + * to be issued. + * ```pli + * dcl f1 file; + * read file(f1) into(f1); + * ``` + * (see page 99) + */ + IBM1821I: { + "code": "IBM1821I", + "severity": "S", + "message": (fromintooption: string) => `Reference for ${fromintooption} is an invalid element or aggregate type.`, + "fullCode": "IBM1821IS" + } as ParametricPLICode, + + /** + * The expression in a KEY or KEYFROM record I\/O statement option must be computational + * data. + * (see page 100) + */ + IBM1822I: { + "code": "IBM1822I", + "severity": "S", + "message": (keywordtype: string) => `The ${keywordtype} expression must be computational.`, + "fullCode": "IBM1822IS" + } as ParametricPLICode, + + /** + * In the SET clause of an ALLOCATE or LOCATE statement, the reference must have the + * type POINTER or OFFSET. + * (see page 100) + */ + IBM1823I: { + "code": "IBM1823I", + "severity": "S", + "message": "SET reference must have locator type.", + "fullCode": "IBM1823IS" + } as SimplePLICode, + + /** + * The expression in the named keyword clause must be scalar. This keyword clause could + * be an IF, UNTIL, WHILE, WHEN, KEY, KEYFROM or KEYTO clause. + * ```pli + * dcl f1 file; + * dcl x char(10); + * dcl z(10) char(10); + * read file(f1) into(x) key(z); + * ``` + * (see page 100) + */ + IBM1824I: { + "code": "IBM1824I", + "severity": "S", + "message": (keyword: string) => `${keyword} expression must be scalar.`, + "fullCode": "IBM1824IS" + } as ParametricPLICode, + + /** + * The references for the KEYTO, FROM, INTO, and SET record I\/O options cannot be built-in + * functions. The example below will cause this message to be issued. + * ```pli + * dcl f1 file; + * dcl x char(10); + * read file(f1) into(hex(x)); + * ``` + * (see page 100) + */ + IBM1825I: { + "code": "IBM1825I", + "severity": "S", + "message": (keyword: string) => `The reference in the ${keyword} clause cannot be a built-in function reference.`, + "fullCode": "IBM1825IS" + } as ParametricPLICode, + + /** + * The references for the KEYTO, FROM, INTO, and SET record I\/O options cannot be entry + * . + * (see page 100) + */ + IBM1826I: { + "code": "IBM1826I", + "severity": "S", + "message": (keyword: string) => `The reference in the ${keyword} clause cannot be a function invocation.`, + "fullCode": "IBM1826IS" + } as ParametricPLICode, + + /** + * The specified reference is invalid. It must be of type character. The example below + * will cause this message to be issued. + * ```pli + * dcl p pointer; + * display ('what is your name?') reply(p); + * ``` + * (see page 100) + */ + IBM1827I: { + "code": "IBM1827I", + "severity": "S", + "message": (keyword: string) => `The reference in the ${keyword} clause must have CHARACTER type.`, + "fullCode": "IBM1827IS" + } as ParametricPLICode, + + /** + * The specified reference is invalid. It must be a scalar. The example below will cause + * this message to be issued. + * ```pli + * dcl z(10) char(10); + * display ('what is your name?') reply(z); + * ``` + * (see page 100) + */ + IBM1828I: { + "code": "IBM1828I", + "severity": "S", + "message": (keyword: string) => `The reference in the ${keyword} clause must be a scalar variable.`, + "fullCode": "IBM1828IS" + } as ParametricPLICode, + + /** + * The declared attributes conflict with their use in the statement. + * ```pli + * dcl f file stream; + * read file(f) into(x); + * ``` + * (see page 100) + */ + IBM1829I: { + "code": "IBM1829I", + "severity": "S", + "message": (clause: string) => `The attributes of the argument in the ${clause} clause conflict with its usage.`, + "fullCode": "IBM1829IS" + } as ParametricPLICode, + + /** + * The expression must be arithmetic or string. + * ```pli + * dcl p pointer; + * put list( ptradd(p,2) ); + * ``` + * (see page 100) + */ + IBM1830I: { + "code": "IBM1830I", + "severity": "S", + "message": (keyword: string) => `${keyword} expression is not computational.`, + "fullCode": "IBM1830IS" + } as ParametricPLICode, + + /** + * Provide a SET clause in the LOCATE statement. + * ```pli + * ``` 100 + * ```pli + * dcl f file; + * dcl x char(10) based; + * locate x file(f1); + * ``` + * (see page 100) + */ + IBM1831I: { + "code": "IBM1831I", + "severity": "S", + "message": "The LOCATE reference ${variable name } is not implicitly qualified and is invalid without a SET clause.", + "fullCode": "IBM1831IS" + } as SimplePLICode, + + /** + * The reference in the SET clause of a FETCH statement must have the POINTER type. + * OFFSET types are not supported in this context. + * (see page 101) + */ + IBM1832I: { + "code": "IBM1832I", + "severity": "S", + "message": "SET reference must have POINTER type.", + "fullCode": "IBM1832IS" + } as SimplePLICode, + + /** + * The specified reference in the FROM or INTO record I\/O option is invalid. The reference + * must be connected. The example below will cause this message to be issued. + * ```pli + * dcl f1 file; + * dcl 1 a(3), + * 2 b(4) char(4), + * 2 c(4) char(4); + * read file(f1) into(b); + * ``` + * (see page 101) + */ + IBM1833I: { + "code": "IBM1833I", + "severity": "S", + "message": (fromintoclause: string) => `The aggregate reference in the ${fromintoclause} clause must be CONNECTED.`, + "fullCode": "IBM1833IS" + } as ParametricPLICode, + + /** + * The specified expression in the IGNORE option of the READ statement must be computational. + * The example below will cause this message to be issued. + * ```pli + * dcl a area; + * read file(f1) ignore(a); + * ``` + * (see page 101) + */ + IBM1834I: { + "code": "IBM1834I", + "severity": "S", + "message": "The expression in IGNORE must be computational.", + "fullCode": "IBM1834IS" + } as SimplePLICode, + + /** + * The LOCATE reference may not be a structure member and must have the storage attribute + * BASED. + * (see page 101) + */ + IBM1835I: { + "code": "IBM1835I", + "severity": "S", + "message": "The LOCATE reference ${variable name } is not a level 1 BASED variable.", + "fullCode": "IBM1835IS" + } as SimplePLICode, + + /** + * The INITIAL attribute is valid only for scalars and arrays of scalars. + * (see page 101) + */ + IBM1836I: { + "code": "IBM1836I", + "severity": "S", + "message": "INITIAL attribute is invalid for structures.", + "fullCode": "IBM1836IS" + } as SimplePLICode, + + /** + * The specified reference is invalid. It cannot be a named constant. The example below + * will cause this message to be issued. + * ```pli + * dcl f1 file; + * dcl x char(2); + * dcl val fixed bin(15) value(4); + * read file(f1) into(x) keyto(val); + * ``` + * (see page 101) + */ + IBM1837I: { + "code": "IBM1837I", + "severity": "S", + "message": (keyword: string) => `The reference in the ${keyword} clause cannot be a named constant.`, + "fullCode": "IBM1837IS" + } as ParametricPLICode, + + /** + * Only AUTOMATIC, CONTROLLED, PARAMETER, STATIC and and implicitly qualified BASED + * variables are supported in data directed I\/O. + * ```pli + * dcl q based; + * put data(q); + * ``` + * (see page 101) + */ + IBM1838I: { + "code": "IBM1838I", + "severity": "S", + "message": (argumentnumber: string) => `The attributes of ${argumentnumber} conflict with its usage in data directed I/O.`, + "fullCode": "IBM1838IS" + } as ParametricPLICode, + + /** + * Use a temporary or use LIST- or EDIT directed I\/O. + * (see page 101) + */ + IBM1839I: { + "code": "IBM1839I", + "severity": "S", + "message": "DATA-directed I/O does not support references with locators.", + "fullCode": "IBM1839IS" + } as SimplePLICode, + + /** + * Use a temporary or use GET LIST or GET EDIT. + * (see page 101) + */ + IBM1840I: { + "code": "IBM1840I", + "severity": "S", + "message": "Subscripted references are not allowed in GET DATA.", + "fullCode": "IBM1840IS" + } as SimplePLICode, + + /** + * The format argument is outside the valid range. + * ```pli + * put edit('hi') (a( -1) ); + * ``` + * (see page 101) + */ + IBM1841I: { + "code": "IBM1841I", + "severity": "S", + "message": (keyword: string) => `The first argument in the ${keyword} - format item is invalid.`, + "fullCode": "IBM1841IS" + } as ParametricPLICode, + + /** + * The width specified is too small for complete processing. + * ```pli + * put edit(10190) (f(3)); + * ``` + * (see page 101) + */ + IBM1842I: { + "code": "IBM1842I", + "severity": "S", + "message": (keyword: string) => `The field width specified in the ${keyword} -format item is too small for complete input or output of the data item.`, + "fullCode": "IBM1842IS" + } as ParametricPLICode, + + /** + * The fractional number of digits must be less than or equal to the field width and + * non-negative. + * (see page 102) + */ + IBM1843I: { + "code": "IBM1843I", + "severity": "S", + "message": (keyword: string) => `The fractional digits specified in the ${keyword} -format item is invalid.`, + "fullCode": "IBM1843IS" + } as ParametricPLICode, + + /** + * The argument to the R-format item must be either a format constant or a format variable + * . + * (see page 102) + */ + IBM1844I: { + "code": "IBM1844I", + "severity": "S", + "message": "The argument in the R-format item is not a format constant or format variable.", + "fullCode": "IBM1844IS" + } as SimplePLICode, + + /** + * The number of significant digits must be greater than or equal to the number of fractional + * digits, less than or equal to the field width and non-negative. + * (see page 102) + */ + IBM1845I: { + "code": "IBM1845I", + "severity": "S", + "message": "The significant digits specified in E-format item is invalid.", + "fullCode": "IBM1845IS" + } as SimplePLICode, + + /** + * G, L, PAGE, LINE, SKIP, and COLUMN format items may not be used in GET\/PUT EDIT + * statements using the STRING option. + * (see page 102) + */ + IBM1846I: { + "code": "IBM1846I", + "severity": "S", + "message": (formatitem: string) => `The ${formatitem} format item is invalid with GET/PUT STRING.`, + "fullCode": "IBM1846IS" + } as ParametricPLICode, + + /** + * The target of a GOTO cannot be inside a DO loop unless the GOTO itself is in the + * same DO loop. + * (see page 102) + */ + IBM1847I: { + "code": "IBM1847I", + "severity": "S", + "message": "GOTO target is inside a (different) DO loop.", + "fullCode": "IBM1847IS" + } as SimplePLICode, + + /** + * The INCLUDE file could not be found or opened. + * (see page 102) + */ + IBM1848I: { + "code": "IBM1848I", + "severity": "S", + "message": "The INCLUDE file for ${includestmt arg } could not be found.", + "fullCode": "IBM1848IS" + } as SimplePLICode, + + /** + * Under CMPAT(V1), bounds must be between -32768 and 32767 inclusive. To use bounds + * outside this range, specify a different CMPAT option. + * (see page 102) + */ + IBM1849I: { + "code": "IBM1849I", + "severity": "S", + "message": "Under CMPAT(V1), bounds must not be greater than 32767.", + "fullCode": "IBM1849IS" + } as SimplePLICode, + + /** + * Under CMPAT(V1), bounds must be between -32768 and 32767 inclusive. To use bounds + * outside this range, specify a different CMPAT option. + * (see page 102) + */ + IBM1850I: { + "code": "IBM1850I", + "severity": "S", + "message": "Under CMPAT(V1), bounds must not be less than -32768.", + "fullCode": "IBM1850IS" + } as SimplePLICode, + + /** + * An unexpected error occurred while trying to open an include source file. + * (see page 102) + */ + IBM1851I: { + "code": "IBM1851I", + "severity": "S", + "message": (includefilename: string) => `The INCLUDE file ${includefilename} could not be opened.`, + "fullCode": "IBM1851IS" + } as ParametricPLICode, + + /** + * A preprocessor specified in the PP compiler option is unknown. + * (see page 102) + */ + IBM1852I: { + "code": "IBM1852I", + "severity": "S", + "message": (preprocessor: string) => `The preprocessor ${preprocessor} is not known to the compiler.`, + "fullCode": "IBM1852IS" + } as ParametricPLICode, + + /** + * The argument in the FETCH and RELEASE statements must be a FETCHABLE entry constant + * . + * (see page 102) + */ + IBM1853I: { + "code": "IBM1853I", + "severity": "S", + "message": (statement: string) => `Variable in ${statement} statement must be a FETCHABLE entry constant.`, + "fullCode": "IBM1853IS" + } as ParametricPLICode, + + /** + * The compiler's attempt to load the named preprocessor failed. + * (see page 102) + */ + IBM1854I: { + "code": "IBM1854I", + "severity": "S", + "message": (PPname: string, oncode: string) => `Fetch of the ${PPname} preprocessor failed with ONCODE= ${oncode} .`, + "fullCode": "IBM1854IS" + } as ParametricPLICode, + + /** + * A terminating error was detected in a preprocessor invoked by the compiler. + * (see page 102) + */ + IBM1855I: { + "code": "IBM1855I", + "severity": "S", + "message": (PPname: string, oncodevalue: string) => `Preprocessor ${PPname} terminated abnormally with ONCODE= ${oncodevalue} .`, + "fullCode": "IBM1855IS" + } as ParametricPLICode, + + /** + * The compiler was unable to load the user exit. + * (see page 102) + */ + IBM1856I: { + "code": "IBM1856I", + "severity": "S", + "message": (oncode: string) => `Fetch of the user exit initialization routine failed with ONCODE= ${oncode} .`, + "fullCode": "IBM1856IS" + } as ParametricPLICode, + + /** + * The compiler detected a terminating error in the user exit. + * (see page 103) + */ + IBM1857I: { + "code": "IBM1857I", + "severity": "S", + "message": (oncodevalue: string) => `User exit routine terminated abnormally with ONCODE= ${oncodevalue} .`, + "fullCode": "IBM1857IS" + } as ParametricPLICode, + + /** + * The user exit aborted the compilation by setting the return code to 16. + * (see page 103) + */ + IBM1858I: { + "code": "IBM1858I", + "severity": "S", + "message": "Compilation aborted by user exit.", + "fullCode": "IBM1858IS" + } as SimplePLICode, + + /** + * All other statements must be enclosed in a PACKAGE or PROCEDURE statement. + * (see page 103) + */ + IBM1859I: { + "code": "IBM1859I", + "severity": "S", + "message": "The first statement must be a PROCEDURE or PACKAGE statement.", + "fullCode": "IBM1859IS" + } as SimplePLICode, + + /** + * PACKAGE statements cannot follow any other statements in the program. + * (see page 103) + */ + IBM1860I: { + "code": "IBM1860I", + "severity": "S", + "message": "PACKAGE statement must be the first statement in the program.", + "fullCode": "IBM1860IS" + } as SimplePLICode, + + /** + * This message can occur, for instance, if the first PROCEDURE statement is invalid + * or if a PROCEDURE contains too many END statements. + * (see page 103) + */ + IBM1861I: { + "code": "IBM1861I", + "severity": "S", + "message": "All statements other than DECLARE, DEFAULT and PROCEDURE statements must be contained inside a PROCEDURE.", + "fullCode": "IBM1861IS" + } as SimplePLICode, + + /** + * The nesting of PROCEDURE, DO, SELECT and similar statements is greater than that + * supported by the compiler. Rewrite the program so that it is less complicated. + * (see page 103) + */ + IBM1862I: { + "code": "IBM1862I", + "severity": "S", + "message": "Statements are nested too deep.", + "fullCode": "IBM1862IS" + } as SimplePLICode, + + /** + * AUTOMATIC variables must be declared inside a PROCEDURE, and DEFINED variables declared + * outside a PROCEDURE must be defined on STATIC. + * (see page 103) + */ + IBM1863I: { + "code": "IBM1863I", + "severity": "S", + "message": "Variables declared in a PACKAGE outside of any PROCEDURE must have the storage class STATIC, BASED or CONTROLLED or must be DEFINED on STATIC.", + "fullCode": "IBM1863IS" + } as SimplePLICode, + + /** + * Support for the indicated built-in function has been discontinued. + * (see page 103) + */ + IBM1864I: { + "code": "IBM1864I", + "severity": "S", + "message": (functionname: string) => `The ${functionname} built-in function is not supported.`, + "fullCode": "IBM1864IS" + } as ParametricPLICode, + + /** + * The variable implicitly qualifying the BASED variable must be a scalar that is not + * part of an array, structure or union, and it must be a POINTER with either the AUTOMATIC + * or STATIC storage attribute. + * (see page 103) + */ + IBM1865I: { + "code": "IBM1865I", + "severity": "S", + "message": "The only BASED variables supported in data-directed i/o are those that have constant extents and that are implicitly qualified by simple variables.", + "fullCode": "IBM1865IS" + } as SimplePLICode, + + /** + * Support for the indicated statement has been discontinued. + * (see page 103) + */ + IBM1866I: { + "code": "IBM1866I", + "severity": "S", + "message": (keyword: string) => `The ${keyword} statement is not supported.`, + "fullCode": "IBM1866IS" + } as ParametricPLICode, + + /** + * Support for the indicated pseudovariable has been discontinued. + * (see page 103) + */ + IBM1867I: { + "code": "IBM1867I", + "severity": "S", + "message": (variablename: string) => `The pseudovariable ${variablename} is not supported.`, + "fullCode": "IBM1867IS" + } as ParametricPLICode, + + /** + * iSUB references are permitted only in DEFINED clauses. + * (see page 103) + */ + IBM1868I: { + "code": "IBM1868I", + "severity": "S", + "message": "Invalid use of iSUB.", + "fullCode": "IBM1868IS" + } as SimplePLICode, + + /** + * For example, neither of the following are supported. 103 + * ```pli + * allocate x(5); + * allocate y char(10); + * ``` + * (see page 103) + */ + IBM1869I: { + "code": "IBM1869I", + "severity": "S", + "message": "ALLOCATE with attribute lists is not supported.", + "fullCode": "IBM1869IS" + } as SimplePLICode, + + /** + * If the SYSTEM action is specified in an ON statement, an ON-unit may not be specified + * as well. + * ```pli + * on error system stop; + * ``` + * (see page 104) + */ + IBM1870I: { + "code": "IBM1870I", + "severity": "S", + "message": "ON statement cannot specify both SYSTEM and an ON-unit.", + "fullCode": "IBM1870IS" + } as SimplePLICode, + + /** + * x in CONDITION(x) refers to a variable that does not have the type CONDITION. + * (see page 104) + */ + IBM1871I: { + "code": "IBM1871I", + "severity": "S", + "message": "The reference in the CONDITION condition must have type CONDITION.", + "fullCode": "IBM1871IS" + } as SimplePLICode, + + /** + * The reference in the named FILE condition does not have the type FILE. + * (see page 104) + */ + IBM1872I: { + "code": "IBM1872I", + "severity": "S", + "message": "The reference in the ${condition name } condition must have type FILE.", + "fullCode": "IBM1872IS" + } as SimplePLICode, + + /** + * DO statements can be nested only 50 deep. Simplify the program. + * (see page 104) + */ + IBM1873I: { + "code": "IBM1873I", + "severity": "S", + "message": "Nesting of DO statements exceeds the maximum.", + "fullCode": "IBM1873IS" + } as SimplePLICode, + + /** + * IF statements can be nested only 50 deep. Simplify the program. + * (see page 104) + */ + IBM1874I: { + "code": "IBM1874I", + "severity": "S", + "message": "Nesting of IF statements exceeds the maximum.", + "fullCode": "IBM1874IS" + } as SimplePLICode, + + /** + * SELECT statements can be nested only 50 deep. Simplify the program. + * (see page 104) + */ + IBM1875I: { + "code": "IBM1875I", + "severity": "S", + "message": "Nesting of SELECT statements exceeds the maximum.", + "fullCode": "IBM1875IS" + } as SimplePLICode, + + /** + * Blocks may be nested only 30 deep. + * (see page 104) + */ + IBM1876I: { + "code": "IBM1876I", + "severity": "S", + "message": "Nesting of blocks exceeds the maximum.", + "fullCode": "IBM1876IS" + } as SimplePLICode, + + /** + * A reference of any other type is invalid and is invalid. + * (see page 104) + */ + IBM1878I: { + "code": "IBM1878I", + "severity": "S", + "message": "The reference in the EVENT clause must have type EVENT.", + "fullCode": "IBM1878IS" + } as SimplePLICode, + + /** + * A reference of any other type is invalid and is invalid. + * (see page 104) + */ + IBM1879I: { + "code": "IBM1879I", + "severity": "S", + "message": "The reference in the TASK clause must have type TASK.", + "fullCode": "IBM1879IS" + } as SimplePLICode, + + /** + * A file variable or constant is required. + * ```pli + * dcl x format variable; + * open file(x); + * ``` + * (see page 104) + */ + IBM1880I: { + "code": "IBM1880I", + "severity": "S", + "message": "Reference must have FILE type.", + "fullCode": "IBM1880IS" + } as SimplePLICode, + + /** + * Enough qualification must be provided to make any reference unique. + * (see page 104) + */ + IBM1881I: { + "code": "IBM1881I", + "severity": "S", + "message": (referencename: string) => `The reference ${referencename} is ambiguous.`, + "fullCode": "IBM1881IS" + } as ParametricPLICode, + + /** + * References in ALLOCATE statements must be level-1 variable names, and those variables + * must have the BASED or CONTROLLED attributes. + * (see page 104) + */ + IBM1882I: { + "code": "IBM1882I", + "severity": "S", + "message": "The ALLOCATE reference ${variable name } is not a level 1 BASED or CONTROLLED variable.", + "fullCode": "IBM1882IS" + } as SimplePLICode, + + /** + * Provide a SET clause in the ALLOCATE statement. + * ```pli + * dcl a based; + * allocate a; + * ``` 104 + * (see page 104) + */ + IBM1883I: { + "code": "IBM1883I", + "severity": "S", + "message": "The ALLOCATE reference ${variable name } is not implicitly qualified and is invalid without a SET clause.", + "fullCode": "IBM1883IS" + } as SimplePLICode, + + /** + * A reference of any other type is invalid. + * (see page 105) + */ + IBM1884I: { + "code": "IBM1884I", + "severity": "S", + "message": (variablename: string) => `The reference ${variablename} in the GENERIC attribute list is not a scalar ENTRY reference.`, + "fullCode": "IBM1884IS" + } as ParametricPLICode, + + /** + * A reference of any other type is invalid. + * (see page 105) + */ + IBM1885I: { + "code": "IBM1885I", + "severity": "S", + "message": "IN option reference must have AREA type.", + "fullCode": "IBM1885IS" + } as SimplePLICode, + + /** + * Provide enough qualification to make the name unique. + * ```pli + * dcl + * 1 a based, + * 2 b1, + * 3 c bit(8) aligned, + * 3 d char(10), + * 2 b2, + * 3 c bit(8) aligned, + * 3 d char(10), + * 2 e( n refer(c)) char(10); + * ``` + * (see page 105) + */ + IBM1886I: { + "code": "IBM1886I", + "severity": "S", + "message": "The REFER object name ${reference name } is ambiguous.", + "fullCode": "IBM1886IS" + } as SimplePLICode, + + /** + * The named REFER object cannot be declared in another structure or in the same structure, + * but after its first usage. + * (see page 105) + */ + IBM1887I: { + "code": "IBM1887I", + "severity": "S", + "message": (referencename: string) => `The REFER object ${referencename} must be an element of the same structure where it is used, and must precede its first usage in that structure.`, + "fullCode": "IBM1887IS" + } as ParametricPLICode, + + /** + * It must be possible to convert the REFER object safely to and from REAL FIXED BIN(31,0) + * . + * ```pli + * dcl + * 1 a based, + * 2 b, + * 3 c pointer, + * 3 d char(10), + * 2 e( n refer(c)) char(10); + * ``` + * (see page 105) + */ + IBM1888I: { + "code": "IBM1888I", + "severity": "S", + "message": (referencename: string) => `The REFER object ${referencename} must have computational type.`, + "fullCode": "IBM1888IS" + } as ParametricPLICode, + + /** + * The REFER object may not have any dimensions in its declaration and neither may any + * of its parents. + * ```pli + * dcl + * 1 a based, + * 2 b(8), + * 3 c fixed bin, + * 3 d char(10), + * 2 e( n refer(c)) char(10); + * ``` + * (see page 105) + */ + IBM1889I: { + "code": "IBM1889I", + "severity": "S", + "message": (referencename: string) => `The REFER object ${referencename} must be a scalar.`, + "fullCode": "IBM1889IS" + } as ParametricPLICode, + + /** + * Reorder the elements in the declaration so that all REFER objects precede the first + * level-2 element containing a REFER. + * ```pli + * dcl + * 1 a based, + * 2 b fixed bin, + * 2 c char( n refer(b) ), + * 2 d fixed bin, + * 2 e char( n refer(d) ); + * ``` + * (see page 105) + */ + IBM1890I: { + "code": "IBM1890I", + "severity": "S", + "message": (referencename: string) => `The REFER object ${referencename} must precede the first level-2 element containing a REFER.`, + "fullCode": "IBM1890IS" + } as ParametricPLICode, + + /** + * REFER can be used only in declarations of BASED variables. + * (see page 105) + */ + IBM1891I: { + "code": "IBM1891I", + "severity": "S", + "message": "REFER is not allowed on non- BASED variables.", + "fullCode": "IBM1891IS" + } as SimplePLICode, + + /** + * If a REFER object is a string, it must have constant length. + * (see page 105) + */ + IBM1892I: { + "code": "IBM1892I", + "severity": "S", + "message": (referencename: string) => `The REFER object ${referencename} must have constant length.`, + "fullCode": "IBM1892IS" + } as ParametricPLICode, + + /** + * REFER cannot be used only in declarations of scalars or arrays of scalars. + * (see page 105) + */ + IBM1893I: { + "code": "IBM1893I", + "severity": "S", + "message": "REFER is allowed only on members of structures and unions.", + "fullCode": "IBM1893IS" + } as SimplePLICode, + + /** + * In the statement REINIT x, x must not have any subscripts or arguments. + * (see page 105) + */ + IBM1894I: { + "code": "IBM1894I", + "severity": "S", + "message": "REINIT references must not be subscripted.", + "fullCode": "IBM1894IS" + } as SimplePLICode, + + /** + * If the DIRECTED(ASM) option is used, comparisons and assignments are not supported + * for ENTRYs declared with OPTIONS(ASM). Similarly, if the DIRECTED(COBOL) option + * is used, comparisons and assignments are not supported for ENTRYs declared with + * OPTIONS(COBOL). + * (see page 106) + */ + IBM1895I: { + "code": "IBM1895I", + "severity": "S", + "message": (languagename: string) => `Operations involving OPTIONS( ${languagename} ) routines are not supported if the DIRECTED option applies.`, + "fullCode": "IBM1895IS" + } as ParametricPLICode, + + /** + * If the DIRECTED(ASM) option is used, ENTRY VARIABLES may not be declared with OPTIONS(ASM). + * Similarly, if the DIRECTED(COBOL) option is used, ENTRY VARIABLES may not be declared + * with OPTIONS(COBOL). + * (see page 106) + */ + IBM1896I: { + "code": "IBM1896I", + "severity": "S", + "message": (languagename: string) => `OPTIONS( ${languagename} ) is not supported for ENTRY VARIABLEs if the DIRECTED option applies.`, + "fullCode": "IBM1896IS" + } as ParametricPLICode, + + /** + * If simple defining is not intended, specify POSITION(1) to force string defining + * . + * (see page 106) + */ + IBM1897I: { + "code": "IBM1897I", + "severity": "S", + "message": "Simple defining is supported only for scalars, for structures with constant extents matching those in the base variable, and for arrays of such scalars and structures as long as the array is not based on a controlled variable.", + "fullCode": "IBM1897IS" + } as SimplePLICode, + + /** + * You can define a variable only another user variable. + * (see page 106) + */ + IBM1898I: { + "code": "IBM1898I", + "severity": "S", + "message": "The base reference in the DEFINED attribute cannot be a built-in or type function.", + "fullCode": "IBM1898IS" + } as SimplePLICode, + + /** + * Convert the DEFINED and base variables into a UNION. + * (see page 106) + */ + IBM1899I: { + "code": "IBM1899I", + "severity": "S", + "message": "The base variable in the DEFINED attribute cannot be BASED, DEFINED or CONSTANT.", + "fullCode": "IBM1899IS" + } as SimplePLICode, + + /** + * All bounds and string lengths for DEFINED structures and unions consisting of bit + * strings must be constant. + * (see page 106) + */ + IBM1900I: { + "code": "IBM1900I", + "severity": "S", + "message": "Extents for DEFINED bit structures must be constant.", + "fullCode": "IBM1900IS" + } as SimplePLICode, + + /** + * The POSITION attribute has no meaning without DEFINED attribute. + * (see page 106) + */ + IBM1901I: { + "code": "IBM1901I", + "severity": "S", + "message": "POSITION attribute is invalid without the DEFINED attribute.", + "fullCode": "IBM1901IS" + } as SimplePLICode, + + /** + * The POSITION expression must have a numeric or string type. + * (see page 106) + */ + IBM1902I: { + "code": "IBM1902I", + "severity": "S", + "message": "The expression in the POSITION attribute must have computational type.", + "fullCode": "IBM1902IS" + } as SimplePLICode, + + /** + * The compiler must be able to evaluate the expression to an integer constant when + * it scans the POSITION attribute. + * (see page 106) + */ + IBM1903I: { + "code": "IBM1903I", + "severity": "S", + "message": "The expression in the POSITION attribute for bit string-overlay defining must be an integer constant.", + "fullCode": "IBM1903IS" + } as SimplePLICode, + + /** + * A variable that is either based or controlled should immediately follow the FREE + * keyword. + * (see page 106) + */ + IBM1904I: { + "code": "IBM1904I", + "severity": "S", + "message": (freeclause: string) => `Variable following the ${freeclause} clause must be level 1 and either BASED or CONTROLLED.`, + "fullCode": "IBM1904IS" + } as ParametricPLICode, + + /** + * An invalid option immediately follows a controlled variable in an ALLOCATE or FREE + * statement. + * (see page 106) + */ + IBM1905I: { + "code": "IBM1905I", + "severity": "S", + "message": (INorSEToption: string, ALLOCATEorFREEclause: string) => `${INorSEToption} option invalid after the CONTROLLED variable in the ${ALLOCATEorFREEclause} clause.`, + "fullCode": "IBM1905IS" + } as ParametricPLICode, + + /** + * Using the specified AREA reference to qualify an OFFSET variable is invalid. The + * reference must be scalar. The following example will issue this message. + * ```pli + * dcl a(10) area; + * dcl o offset(a); + * ``` + * (see page 106) + */ + IBM1906I: { + "code": "IBM1906I", + "severity": "S", + "message": "The reference qualifying an OFFSET attribute must be a scalar AREA reference.", + "fullCode": "IBM1906IS" + } as SimplePLICode, + + /** + * The extent specified for the controlled variable is invalid. The following example + * will emit this message. + * ```pli + * dcl c(*) char(10) controlled; + * ``` + * (see page 107) + */ + IBM1907I: { + "code": "IBM1907I", + "severity": "S", + "message": "Extents for CONTROLLED variables cannot be specified using asterisks or REFER.", + "fullCode": "IBM1907IS" + } as SimplePLICode, + + /** + * Extents for AUTOMATIC and DEFINED variables must be specified by expressions. + * (see page 107) + */ + IBM1908I: { + "code": "IBM1908I", + "severity": "S", + "message": (attribute: string) => `Extents for ${attribute} variables cannot be specified using asterisks or REFER.`, + "fullCode": "IBM1908IS" + } as ParametricPLICode, + + /** + * The named attributes, for example PARAMETER and INITIAL, are mutually exclusive. + * (see page 107) + */ + IBM1909I: { + "code": "IBM1909I", + "severity": "S", + "message": (attribute: string, attribute2: string) => `The ${attribute} attribute conflicts with the ${attribute2} attribute.`, + "fullCode": "IBM1909IS" + } as ParametricPLICode, + + /** + * Parameters can have no storage attributes other than CONTROLLED. Parameters also + * cannot have any of the attributes BUILTIN, CONDITION, CONSTANT, EXTERNAL, and GENERIC + * . + * (see page 107) + */ + IBM1910I: { + "code": "IBM1910I", + "severity": "S", + "message": (identifier: string) => `The attributes given in the declaration for ${identifier} conflict with its use as a parameter.`, + "fullCode": "IBM1910IS" + } as ParametricPLICode, + + /** + * All statement labels in any block must be unique. + * (see page 107) + */ + IBM1911I: { + "code": "IBM1911I", + "severity": "S", + "message": (character: string) => `Repeated specifications of the unsubscripted statement label ${character} are in error.`, + "fullCode": "IBM1911IS" + } as ParametricPLICode, + + /** + * All statement labels in any block must be unique. + * (see page 107) + */ + IBM1912I: { + "code": "IBM1912I", + "severity": "S", + "message": (character: string) => `Indices specified for the LABEL ${character} have already been specified.`, + "fullCode": "IBM1912IS" + } as ParametricPLICode, + + /** + * A BEGIN block or a statement associated with an ON clause may not have a label. + * (see page 107) + */ + IBM1913I: { + "code": "IBM1913I", + "severity": "S", + "message": "ON-units may not be labeled. All such labels will be ignored.", + "fullCode": "IBM1913IS" + } as SimplePLICode, + + /** + * x in GOTO x must have type LABEL. x must not have type FORMAT. + * (see page 107) + */ + IBM1914I: { + "code": "IBM1914I", + "severity": "S", + "message": "GOTO target must be a LABEL reference.", + "fullCode": "IBM1914IS" + } as SimplePLICode, + + /** + * x in GOTO x must not be an array. + * (see page 107) + */ + IBM1915I: { + "code": "IBM1915I", + "severity": "S", + "message": "GOTO target must be a scalar.", + "fullCode": "IBM1915IS" + } as SimplePLICode, + + /** + * Sister procedures must have different names. + * ```pli + * a: proc; + * b: proc; + * end; + * b: proc; + * end; + * end; + * ``` + * (see page 107) + */ + IBM1916I: { + "code": "IBM1916I", + "severity": "S", + "message": "The PROCEDURE/ENTRY ${proc name } has already been defined.", + "fullCode": "IBM1916IS" + } as SimplePLICode, + + /** + * The source contains either no statements or all statements that it contains are invalid + * . + * (see page 107) + */ + IBM1917I: { + "code": "IBM1917I", + "severity": "S", + "message": "Program contains no valid source lines.", + "fullCode": "IBM1917IS" + } as SimplePLICode, + + /** + * None of the names in an ORDINAL should have been declared elsewhere. If they are, + * perhaps the ORDINAL definition has been accidentally repeated. + * (see page 107) + */ + IBM1918I: { + "code": "IBM1918I", + "severity": "S", + "message": (ordinalname: string) => `All the names in the ORDINAL ${ordinalname} have been previously declared.`, + "fullCode": "IBM1918IS" + } as ParametricPLICode, + + /** + * Each EXTERNAL name must be used only once. So, for example, the following declares + * would be illegal since the external name Z is specified for two different names + * X and Y. + * ```pli + * dcl X fixed bin(31) ext('Z'); + * dcl Y fixed bin(31) ext('Z'); + * ``` + * (see page 108) + */ + IBM1919I: { + "code": "IBM1919I", + "severity": "S", + "message": (string: string, name: string, name2: string) => `The EXTERNAL name ${string} is specified for the differing names ${name} and ${name2} .`, + "fullCode": "IBM1919IS" + } as ParametricPLICode, + + /** + * The maximum precision of FIXED BINARY constants is set by the FIXEDBIN suboption + * of the LIMITS compiler option. + * (see page 108) + */ + IBM1920I: { + "code": "IBM1920I", + "severity": "S", + "message": "FIXED BINARY constant contains too many digits.", + "fullCode": "IBM1920IS" + } as SimplePLICode, + + /** + * The maximum precision of FIXED DECIMAL constants is set by the FIXEDDEC suboption + * of the LIMITS compiler option. + * (see page 108) + */ + IBM1921I: { + "code": "IBM1921I", + "severity": "S", + "message": "FIXED DECIMAL constant contains too many significant digits.", + "fullCode": "IBM1921IS" + } as SimplePLICode, + + /** + * The exponent in a FLOAT BINARY constant may contain no more than 5 digits. + * (see page 108) + */ + IBM1922I: { + "code": "IBM1922I", + "severity": "S", + "message": "Exponent in FLOAT BINARY constant contains more digits than the implementation maximum.", + "fullCode": "IBM1922IS" + } as SimplePLICode, + + /** + * The mantissa in a FLOAT BINARY constant may contain no more than 64 digits. + * (see page 108) + */ + IBM1923I: { + "code": "IBM1923I", + "severity": "S", + "message": "Mantissa in FLOAT BINARY constant contains more significant digits than the implementation maximum.", + "fullCode": "IBM1923IS" + } as SimplePLICode, + + /** + * The exponent in a FLOAT BINARY constant may contain no more than 4 digits. + * (see page 108) + */ + IBM1924I: { + "code": "IBM1924I", + "severity": "S", + "message": "Exponent in FLOAT DECIMAL constant contains more digits than the implementation maximum.", + "fullCode": "IBM1924IS" + } as SimplePLICode, + + /** + * The mantissa in a FLOAT DECIMAL constant may contain no more than maximum number + * of digits allowed on the platform. + * (see page 108) + */ + IBM1925I: { + "code": "IBM1925I", + "severity": "S", + "message": "Mantissa in FLOAT DECIMAL constant contains more significant digits than the implementation maximum.", + "fullCode": "IBM1925IS" + } as SimplePLICode, + + /** + * The number of bytes used to represent a constant in your program must not exceed + * 8192. This limit holds even for bit strings where the internal representation will + * consume only one-eighth the number of bytes as the external representation does + * . + * (see page 108) + */ + IBM1926I: { + "code": "IBM1926I", + "severity": "S", + "message": "Constants must not exceed 8192 bytes.", + "fullCode": "IBM1926IS" + } as SimplePLICode, + + /** + * The source value is not in the domain of the target. + * ```pli + * dcl x fixed bin(15); + * x = 172900; + * ``` + * (see page 108) + */ + IBM1927I: { + "code": "IBM1927I", + "severity": "S", + "message": (sourcevalue: string, targetattributes: string) => `SIZE condition raised by attempt to convert ${sourcevalue} to ${targetattributes}`, + "fullCode": "IBM1927IS" + } as ParametricPLICode, + + /** + * The ERROR condition was while the compiler was trying to build CEEUOPT from PLIXOPT. + * There may be an error in the LE APIs used by the compiler. Contact IBM service. + * (see page 108) + */ + IBM1928I: { + "code": "IBM1928I", + "severity": "S", + "message": "ERROR raised while building CEEUOPT from PLIXOPT.", + "fullCode": "IBM1928IS" + } as SimplePLICode, + + /** + * The compiler was unable to open the named temporary file used to communicate with + * the code generation module. Check the value of the TMP environment variable. + * (see page 108) + */ + IBM1929I: { + "code": "IBM1929I", + "severity": "S", + "message": (filename: string, procname: string, linenumber: string) => `Unable to open file ${filename} in routine ${procname} ( ${linenumber} ).`, + "fullCode": "IBM1929IS" + } as ParametricPLICode, + + /** + * The compiler was unable to write to a temporary file used to communicate with the + * code generation module. The disk to which the TMP environment variable points may + * be full. + * (see page 109) + */ + IBM1930I: { + "code": "IBM1930I", + "severity": "S", + "message": (filename: string) => `Unable to write to file ${filename} . Disk may be full.`, + "fullCode": "IBM1930IS" + } as ParametricPLICode, + + /** + * The compiler was unable to close the named temporary file used to communicate with + * the code generation module. Check the value of the TMP environment variable. + * (see page 109) + */ + IBM1932I: { + "code": "IBM1932I", + "severity": "S", + "message": (filename: string, procname: string, linenumber: string) => `Unable to close file ${filename} in routine ${procname} ( ${linenumber} ).`, + "fullCode": "IBM1932IS" + } as ParametricPLICode, + + /** + * Shorten the name of the source file or the directory specified by the TMP variable + * . + * (see page 109) + */ + IBM1933I: { + "code": "IBM1933I", + "severity": "S", + "message": "Unable to open temporary files because the path and filename are too long.", + "fullCode": "IBM1933IS" + } as SimplePLICode, + + /** + * Assign the structure to a temporary and pass the temporary, or omit the parameter + * description in the entry declaration. + * (see page 109) + */ + IBM1934I: { + "code": "IBM1934I", + "severity": "S", + "message": "If a parameter is a structure with nonconstant extents, only matching structures are supported as arguments.", + "fullCode": "IBM1934IS" + } as SimplePLICode, + + /** + * Assign the structure to a temporary and pass the temporary, or describe the parameter + * in the entry declaration. + * (see page 109) + */ + IBM1935I: { + "code": "IBM1935I", + "severity": "S", + "message": "Structure expressions as arguments are not supported for undescribed parameters.", + "fullCode": "IBM1935IS" + } as SimplePLICode, + + /** + * The back end of the compiler either could not be found or else it detected an error + * from which it could not recover. The latter problem can sometimes occur, on Intel, + * if your disk is short of free space and, on the z\/Series, if your job's region + * size is not large enough. Otherwise, report the problem to IBM. + * (see page 109) + */ + IBM1936I: { + "code": "IBM1936I", + "severity": "S", + "message": "Invocation of compiler backend ended abnormally.", + "fullCode": "IBM1936IS" + } as SimplePLICode, + + /** + * For parameters, each array bound, string length and AREA size must be specified either + * with an asterisk or with a restricted expression that has computational type. + * (see page 109) + */ + IBM1937I: { + "code": "IBM1937I", + "severity": "S", + "message": "Extents for parameters must be asterisks or restricted expressions with computational type.", + "fullCode": "IBM1937IS" + } as SimplePLICode, + + /** + * The message must be in the current directory or in one of the directories specified + * in the DPATH environment variable. + * (see page 109) + */ + IBM1938I: { + "code": "IBM1938I", + "severity": "S", + "message": (filename: string) => `Message file ${filename} not found.`, + "fullCode": "IBM1938IS" + } as ParametricPLICode, + + /** + * The operands in an exponentiation must have numeric or string type. + * (see page 109) + */ + IBM1939I: { + "code": "IBM1939I", + "severity": "S", + "message": "Exponentiation operands must have computational type.", + "fullCode": "IBM1939IS" + } as SimplePLICode, + + /** + * This message is used by %NOTE statements with a return code of 12. + * (see page 109) + */ + IBM1940I: { + "code": "IBM1940I", + "severity": "S", + "message": (note: string) => `${note}`, + "fullCode": "IBM1940IS" + } as ParametricPLICode, + + /** + * This message is used by %NOTE statements with a return code of 16. + * (see page 109) + */ + IBM1941I: { + "code": "IBM1941I", + "severity": "U", + "message": (note: string) => `${note}`, + "fullCode": "IBM1941IU" + } as ParametricPLICode, + + /** + * This applies to all the precision-handling built-in functions. + * (see page 109) + */ + IBM1942I: { + "code": "IBM1942I", + "severity": "S", + "message": (BUILTINname: string) => `The scale factor specified in ${BUILTINname} built-in function must be a restricted expression with integer type.`, + "fullCode": "IBM1942IS" + } as ParametricPLICode, + + /** + * Compilation will terminate when the number of messages has exceeded the limit set + * in the FLAG compiler option. + * (see page 109) + */ + IBM1943I: { + "code": "IBM1943I", + "severity": "S", + "message": "The number of error messages allowed by the FLAG option has been exceeded.", + "fullCode": "IBM1943IS" + } as SimplePLICode, + + /** + * This applies to all the precision-handling built-in functions. + * (see page 110) + */ + IBM1944I: { + "code": "IBM1944I", + "severity": "S", + "message": "The precision specified in ${BUILTIN name } built-in function must be a restricted expression with integer type.", + "fullCode": "IBM1944IS" + } as SimplePLICode, + + /** + * Extents in BASED variables must be either constants or specified with the REFER option + * . + * (see page 110) + */ + IBM1945I: { + "code": "IBM1945I", + "severity": "S", + "message": "Extents for BASED variable may not contain asterisks.", + "fullCode": "IBM1945IS" + } as SimplePLICode, + + /** + * The specified reference is invalid. An AREA variable is needed. + * (see page 110) + */ + IBM1946I: { + "code": "IBM1946I", + "severity": "S", + "message": "Reference must be an AREA variable.", + "fullCode": "IBM1946IS" + } as SimplePLICode, + + /** + * The argument list in a GENERIC reference must match one of the generic descriptors + * in one of that GENERIC's WHEN clauses. If an OTHERWISE clause was specified, the + * argument list must have the same number of elements as the OTHERWISE entry reference + * . + * (see page 110) + */ + IBM1947I: { + "code": "IBM1947I", + "severity": "S", + "message": (GENERICvariablename: string) => `The reference to the GENERIC variable ${GENERICvariablename} cannot be resolved.`, + "fullCode": "IBM1947IS" + } as ParametricPLICode, + + /** + * Compile-time evaluation of a restricted expression raised a condition. + * ```pli + * display( 1\/0 ); + * ``` + * (see page 110) + */ + IBM1948I: { + "code": "IBM1948I", + "severity": "S", + "message": (conditionname: string, oncodevalue: string) => `${conditionname} condition with ONCODE= ${oncodevalue} raised while evaluating restricted expression.`, + "fullCode": "IBM1948IS" + } as ParametricPLICode, + + /** + * Each identifier in a parameter list must be unique. + * ```pli + * a: proc( b, c, b ); + * ``` + * (see page 110) + */ + IBM1949I: { + "code": "IBM1949I", + "severity": "S", + "message": (identifier: string) => `Parameter name ${identifier} appears more than once in parameter list.`, + "fullCode": "IBM1949IS" + } as ParametricPLICode, + + /** + * Variables with the CONTROLLED attribute must be named, and a variable with the EXTERNAL + * attribute may not have an * instead of a name unless a name is given with the EXTERNAL + * attribute itself. + * (see page 110) + */ + IBM1951I: { + "code": "IBM1951I", + "severity": "S", + "message": (storageclass: string) => `${storageclass} variables must be named.`, + "fullCode": "IBM1951IS" + } as ParametricPLICode, + + /** + * An INITIAL CALL must be evaluated at run-time; it can be used to initialize only + * non-STATIC data. + * (see page 110) + */ + IBM1952I: { + "code": "IBM1952I", + "severity": "S", + "message": "INITIAL CALL cannot be used to initialize STATIC data.", + "fullCode": "IBM1952IS" + } as SimplePLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 110) + */ + IBM1953I: { + "code": "IBM1953I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration.`, + "fullCode": "IBM1953IS" + } as ParametricPLICode, + + /** + * Variables cannot be DEFINED on NONCONNECTED references. + * (see page 110) + */ + IBM1954I: { + "code": "IBM1954I", + "severity": "S", + "message": "The base reference in the DEFINED attribute must be CONNECTED.", + "fullCode": "IBM1954IS" + } as SimplePLICode, + + /** + * EXTERNAL FILE constants and CONDITIONs may be declared only once in a compilation + * unit. Remove all but the outermost declare. + * (see page 110) + */ + IBM1955I: { + "code": "IBM1955I", + "severity": "S", + "message": (attribute: string, variablename: string) => `Repeated declarations of the EXTERNAL ${attribute} ${variablename} are not supported.`, + "fullCode": "IBM1955IS" + } as ParametricPLICode, + + /** + * ITERATE is not valid inside type-I do groups. + * (see page 111) + */ + IBM1956I: { + "code": "IBM1956I", + "severity": "S", + "message": "ITERATE is valid only for iterative DO-groups.", + "fullCode": "IBM1956IS" + } as SimplePLICode, + + /** + * The expression representing the number of items to wait for in a WAIT statement is + * invalid. The expression must be of computational type. The following example will + * issue this message. + * ```pli + * dcl e event; + * dcl p pointer: + * wait (e) (p); + * ``` + * (see page 111) + */ + IBM1957I: { + "code": "IBM1957I", + "severity": "S", + "message": "The WAIT event number specification must be computational.", + "fullCode": "IBM1957IS" + } as SimplePLICode, + + /** + * The event reference in the WAIT statement is invalid. It must be of type EVENT. The + * following example will issue this message. + * ```pli + * dcl e entry; + * wait (e); + * ``` + * (see page 111) + */ + IBM1958I: { + "code": "IBM1958I", + "severity": "S", + "message": "References in the WAIT statement must be of type EVENT.", + "fullCode": "IBM1958IS" + } as SimplePLICode, + + /** + * References in WAIT statements can be scalars. The only valid aggregate reference + * is a simple array of events. Structures, unions, and arrays of structures or unions + * would be flagged as errors. + * (see page 111) + */ + IBM1959I: { + "code": "IBM1959I", + "severity": "S", + "message": "Invalid aggregate expression specified in WAIT statement.", + "fullCode": "IBM1959IS" + } as SimplePLICode, + + /** + * In a declare statement that specifies TYPE x, ORDINAL x, or HANDLE x, x must be a + * defined type. + * (see page 111) + */ + IBM1960I: { + "code": "IBM1960I", + "severity": "S", + "message": (typename: string) => `${typename} is not a type name.`, + "fullCode": "IBM1960IS" + } as ParametricPLICode, + + /** + * Any values specified in INITIAL clauses in an ORDINAL definition must be in strictly + * increasing order. + * (see page 111) + */ + IBM1961I: { + "code": "IBM1961I", + "severity": "S", + "message": (typetype: string, typename: string) => `INITIAL values for ${typetype} type ${typename} must be in increasing order.`, + "fullCode": "IBM1961IS" + } as ParametricPLICode, + + /** + * ORDINAL values must fit in the range of a FIXED BIN(31) variable. + * (see page 111) + */ + IBM1962I: { + "code": "IBM1962I", + "severity": "S", + "message": (typetype: string, typename: string) => `INITIAL values for ${typetype} type ${typename} must be less than 2G.`, + "fullCode": "IBM1962IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with an argument that is not an + * ORDINAL. This message applies, for example, to the ORDINALNAME, ORDINALPRED and + * ORDINALSUCC built-in functions. + * (see page 111) + */ + IBM1963I: { + "code": "IBM1963I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have ORDINAL type.`, + "fullCode": "IBM1963IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 111) + */ + IBM1964I: { + "code": "IBM1964I", + "severity": "S", + "message": (variablename: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration.`, + "fullCode": "IBM1964IS" + } as ParametricPLICode, + + /** + * All references must be unambiguous. + * (see page 111) + */ + IBM1965I: { + "code": "IBM1965I", + "severity": "S", + "message": (referencename: string, structurename: string) => `There is more than one element named ${referencename} in the class ${structurename} .`, + "fullCode": "IBM1965IS" + } as ParametricPLICode, + + /** + * HANDLE qualified references must be explicitly declared. + * (see page 111) + */ + IBM1966I: { + "code": "IBM1966I", + "severity": "S", + "message": (referencename: string, structurename: string) => `There is no element named ${referencename} in the class ${structurename} .`, + "fullCode": "IBM1966IS" + } as ParametricPLICode, + + /** + * Functions, but not subprocedures, can be used as handles (and then only if they return + * a handle). + * (see page 111) + */ + IBM1967I: { + "code": "IBM1967I", + "severity": "S", + "message": (variablename: string) => `The ENTRY ${variablename} may not be used as a handle since it does not have the RETURNS attribute.`, + "fullCode": "IBM1967IS" + } as ParametricPLICode, + + /** + * x(...)=>y is invalid unless x returns a HANDLE. + * (see page 111) + */ + IBM1968I: { + "code": "IBM1968I", + "severity": "S", + "message": (variablename: string) => `The ENTRY ${variablename} may not be used as a handle.`, + "fullCode": "IBM1968IS" + } as ParametricPLICode, + + /** + * Only scalars can be used as handles. + * (see page 112) + */ + IBM1969I: { + "code": "IBM1969I", + "severity": "S", + "message": (variablename: string) => `The variable ${variablename} is used as a handle, but it is not a scalar.`, + "fullCode": "IBM1969IS" + } as ParametricPLICode, + + /** + * The named built-in function cannot be used as a handle. + * (see page 112) + */ + IBM1970I: { + "code": "IBM1970I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} built-in function may not be used as a handle.`, + "fullCode": "IBM1970IS" + } as ParametricPLICode, + + /** + * GENERIC references may not be used as handles. + * (see page 112) + */ + IBM1971I: { + "code": "IBM1971I", + "severity": "S", + "message": "The GENERIC variable ${variable name } may not be used as a handle.", + "fullCode": "IBM1971IS" + } as SimplePLICode, + + /** + * x=>y is invalid unless x has the HANDLE attribute + * (see page 112) + */ + IBM1972I: { + "code": "IBM1972I", + "severity": "S", + "message": (variablename: string) => `${variablename} may not be used as a handle.`, + "fullCode": "IBM1972IS" + } as ParametricPLICode, + + /** + * Hex strings (strings ending in one of the suffixes X, BX, B4, GX or XN), bit strings + * (strings ending in the suffix B), and character strings not ending in the suffix + * M must contain only SBCS characters. + * (see page 112) + */ + IBM1976I: { + "code": "IBM1976I", + "severity": "S", + "message": "DBCS characters are allowed only in G and M constants.", + "fullCode": "IBM1976IS" + } as SimplePLICode, + + /** + * Mixed SBCS and DBCS is allowed only in M constants. + * (see page 112) + */ + IBM1977I: { + "code": "IBM1977I", + "severity": "S", + "message": "SBCS characters are not allowed in G constants.", + "fullCode": "IBM1977IS" + } as SimplePLICode, + + /** + * Outside of comments, SBCS can be encoded as DBCS only as part of an identifier. + * (see page 112) + */ + IBM1978I: { + "code": "IBM1978I", + "severity": "S", + "message": "Invalid use of SBCS encoded as DBCS.", + "fullCode": "IBM1978IS" + } as SimplePLICode, + + /** + * The named built-in function may be used only inside procedures. + * (see page 112) + */ + IBM1981I: { + "code": "IBM1981I", + "severity": "S", + "message": (BUILTINfunction: string) => `${BUILTINfunction} may not be used outside a PROCEDURE.`, + "fullCode": "IBM1981IS" + } as ParametricPLICode, + + /** + * The named file could not be opened. Make sure that the file is named correctly, that + * it exists, that it has the proper attributes and that you have the needed permissions + * to access it. + * (see page 112) + */ + IBM1984I: { + "code": "IBM1984I", + "severity": "S", + "message": (filename: string) => `File ${filename} could not be opened.`, + "fullCode": "IBM1984IS" + } as ParametricPLICode, + + /** + * The named file could not be opened. Make sure that the file is named correctly, that + * it exists, that it has the proper attributes and that you have the needed permissions + * to access it. The accompanying C library message may help identify the problem. + * (see page 112) + */ + IBM1985I: { + "code": "IBM1985I", + "severity": "S", + "message": (filename: string, Clibrarymessage: string) => `File ${filename} could not be opened. ${Clibrarymessage}`, + "fullCode": "IBM1985IS" + } as ParametricPLICode, + + /** + * This error can occur, for example. when writing the MDECK to a SYSPUNCH dataset that + * is too small or when writing to one of the other compiler output datasets when they + * are too small. It would probably be useful to examine the JES log. + * (see page 112) + */ + IBM1986I: { + "code": "IBM1986I", + "severity": "S", + "message": "A system or user abend has occurred.", + "fullCode": "IBM1986IS" + } as SimplePLICode, + + /** + * The maximum number of open files has been reached. On some platforms, there is a + * system limit on the number of open files, but the compiler also has a limit of 2047 + * include files. + * (see page 112) + */ + IBM1987I: { + "code": "IBM1987I", + "severity": "S", + "message": (filename: string) => `File ${filename} could not be opened because too many files have been opened.`, + "fullCode": "IBM1987IS" + } as ParametricPLICode, + + /** + * Either the file is in use or you tried to open a file for which you do not have sufficient + * privilege. + * (see page 112) + */ + IBM1988I: { + "code": "IBM1988I", + "severity": "S", + "message": (filename: string) => `File ${filename} could not be opened due to an access violation.`, + "fullCode": "IBM1988IS" + } as ParametricPLICode, + + /** + * The length of the file name or extension is greater than the maximum allowed. + * (see page 112) + */ + IBM1989I: { + "code": "IBM1989I", + "severity": "S", + "message": (filename: string) => `File name or extension for ${filename} is too long.`, + "fullCode": "IBM1989IS" + } as ParametricPLICode, + + /** + * Apart from z\/OS UNIX, file names should not contain quotes. Under z\/OS UNIX, if + * the file name does contain quotes, it should specify a PDS member. + * (see page 113) + */ + IBM1990I: { + "code": "IBM1990I", + "severity": "S", + "message": (filename: string) => `File name ${filename} has invalid format.`, + "fullCode": "IBM1990IS" + } as ParametricPLICode, + + /** + * The command syntax is: + * ```pli + * PLI {d:}{path}filename{.ext} {( options} + * ``` + * (see page 113) + */ + IBM1992I: { + "code": "IBM1992I", + "severity": "S", + "message": "A file name must be specified.", + "fullCode": "IBM1992IS" + } as SimplePLICode, + + /** + * If you hit CTL-BRK during the compilation, the compilation will stop. + * (see page 113) + */ + IBM1993I: { + "code": "IBM1993I", + "severity": "S", + "message": "Compilation terminated by ATTENTION condition.", + "fullCode": "IBM1993IS" + } as SimplePLICode, + + /** + * This message indicates that there is an error in the front end of the compiler. Please + * report the problem to IBM. + * (see page 113) + */ + IBM1994I: { + "code": "IBM1994I", + "severity": "S", + "message": "Internal compiler error: storage header has been overwritten", + "fullCode": "IBM1994IS" + } as SimplePLICode, + + /** + * This message indicates that there is an error in the front end of the compiler. Please + * report the problem to IBM. + * (see page 113) + */ + IBM1995I: { + "code": "IBM1995I", + "severity": "S", + "message": "Internal compiler error: storage tail has been overwritten.", + "fullCode": "IBM1995IS" + } as SimplePLICode, + + /** + * This message indicates that there is an error in the front end of the compiler. Please + * report the problem to IBM. + * (see page 113) + */ + IBM1996I: { + "code": "IBM1996I", + "severity": "S", + "message": (freerequestsize: string, allocatedsize: string) => `Internal compiler error: free amount ${freerequestsize} does not match allocated size ${allocatedsize} .`, + "fullCode": "IBM1996IS" + } as ParametricPLICode, + + /** + * This message indicates that there is an error in the front end of the compiler. Please + * report the problem to IBM. + * (see page 113) + */ + IBM1997I: { + "code": "IBM1997I", + "severity": "S", + "message": "Internal compiler error: no WHEN clause satisfied within ${module name}", + "fullCode": "IBM1997IS" + } as SimplePLICode, + + /** + * This message indicates that there is an error in the front end of the compiler. Please + * report the problem to IBM. + * (see page 113) + */ + IBM1998I: { + "code": "IBM1998I", + "severity": "S", + "message": (modulename: string) => `Internal compiler error: protection exception in ${modulename}`, + "fullCode": "IBM1998IS" + } as ParametricPLICode, + + /** + * This message indicates that there is an error in the back end of the compiler. Please + * report the problem to IBM. + * (see page 113) + */ + IBM1999I: { + "code": "IBM1999I", + "severity": "S", + "message": (note: string) => `${note}`, + "fullCode": "IBM1999IS" + } as ParametricPLICode, + + /** + * This message indicates that there is an error in the front end of the compiler. Report + * the problem to IBM. + * (see page 113) + */ + IBM2000I: { + "code": "IBM2000I", + "severity": "S", + "message": (sourceline: string, procedurename: string, packagename: string, extratext: string) => `Internal compiler error: assertion failed on line ${sourceline} in ${procedurename} in ${packagename} >> ${extratext}`, + "fullCode": "IBM2000IS" + } as ParametricPLICode, + + /** + * IBM License Manager is installed on your system, but the request to verify that you + * have a license to use the PL\/I compiler has failed. + * (see page 113) + */ + IBM2001I: { + "code": "IBM2001I", + "severity": "S", + "message": (STATUSCODE: string, RETURNCODE: string) => `A LICENSE REQUEST WAS DENIED FOR PL/I, PID 5655- B22. THE REQUEST ENDED WITH STATUS CODE ${STATUSCODE} AND RETURN CODE ${RETURNCODE} . THE COMPILATION WILL BE TERMINATED.`, + "fullCode": "IBM2001IS" + } as ParametricPLICode, + + /** + * An error has occurred while attempting to close a file. + * (see page 113) + */ + IBM2002I: { + "code": "IBM2002I", + "severity": "S", + "message": (filename: string) => `Close of file ${filename} failed. There may be a space problem.`, + "fullCode": "IBM2002IS" + } as ParametricPLICode, + + /** + * An error has occurred while attempting to write to a file. + * (see page 113) + */ + IBM2003I: { + "code": "IBM2003I", + "severity": "S", + "message": (filename: string) => `Write to file ${filename} failed. There may be a space problem.`, + "fullCode": "IBM2003IS" + } as ParametricPLICode, + + /** + * If the ATTACH reference is declared without an argument list, change the declare + * to specify a null argument list by adding a pair of parentheses. + * (see page 114) + */ + IBM2004I: { + "code": "IBM2004I", + "severity": "S", + "message": "ATTACH reference must be declared with either a null argument list or with an argument list specifying only one argument.", + "fullCode": "IBM2004IS" + } as SimplePLICode, + + /** + * GENERIC references and built-in subroutines may not be attached. + * (see page 114) + */ + IBM2005I: { + "code": "IBM2005I", + "severity": "S", + "message": "ATTACH reference must be an ENTRY reference.", + "fullCode": "IBM2005IS" + } as SimplePLICode, + + /** + * An ATTACH reference must not have the RETURNS attribute, even if the value returned + * is an ENTRY. + * (see page 114) + */ + IBM2006I: { + "code": "IBM2006I", + "severity": "S", + "message": "ATTACH reference cannot be a function reference.", + "fullCode": "IBM2006IS" + } as SimplePLICode, + + /** + * Unless the default linkage is overridden, OPTIONS(LINKAGE(SYSTEM)) must be specified + * on the declare for the ATTACH reference. + * (see page 114) + */ + IBM2007I: { + "code": "IBM2007I", + "severity": "S", + "message": "ATTACH reference must use LINKAGE(SYSTEM).", + "fullCode": "IBM2007IS" + } as SimplePLICode, + + /** + * An ATTACH reference may not be used in a FETCH or RELEASE statement. + * (see page 114) + */ + IBM2008I: { + "code": "IBM2008I", + "severity": "S", + "message": "ATTACH reference cannot be FETCHABLE.", + "fullCode": "IBM2008IS" + } as SimplePLICode, + + /** + * An ATTACH reference must be a level-1 procedure, although it does need to be external + * . + * (see page 114) + */ + IBM2009I: { + "code": "IBM2009I", + "severity": "S", + "message": "ATTACH reference cannot be a nested PROCEDURE.", + "fullCode": "IBM2009IS" + } as SimplePLICode, + + /** + * Specify the LIMITED attribute in the declare for the ENTRY VARIABLE. + * (see page 114) + */ + IBM2010I: { + "code": "IBM2010I", + "severity": "S", + "message": "ATTACH reference, if an ENTRY variable, must be a LIMITED ENTRY.", + "fullCode": "IBM2010IS" + } as SimplePLICode, + + /** + * No other argument types are support in ATTACH statements. + * (see page 114) + */ + IBM2011I: { + "code": "IBM2011I", + "severity": "S", + "message": "ATTACH reference, if it has an argument, must declare that argument as POINTER BYVALUE.", + "fullCode": "IBM2011IS" + } as SimplePLICode, + + /** + * The specified attribute must not be used in a DEFINE ALIAS statement. This includes + * attributes such as ASSIGNABLE, but, as in RETURNS descriptors, the attributes STRUCTURE, + * UNION and DIMENSION are not permitted in ALIAS definitions. Hence, the following + * are invalid: + * ```pli + * define alias array (10) fixed bin; + * define alias point 1, 2 fixed bin, 2 fixed + * bin; + * ``` + * (see page 114) + */ + IBM2012I: { + "code": "IBM2012I", + "severity": "S", + "message": (attributekeyword: string) => `The ${attributekeyword} attribute is invalid in an ALIAS definition.`, + "fullCode": "IBM2012IS" + } as ParametricPLICode, + + /** + * The syntax allows the name in an alias definition to be followed by a description + * list, but that description list must consist of exactly one description. The following + * is invalid: + * ```pli + * define alias x fixed bin, float bin; + * ``` + * (see page 114) + */ + IBM2013I: { + "code": "IBM2013I", + "severity": "S", + "message": "Only one description is allowed in an ALIAS definition.", + "fullCode": "IBM2013IS" + } as SimplePLICode, + + /** + * In ALIAS and STRUCTURE definitions, each string length and AREA size must be specified + * with a restricted expression. Like RETURNS descriptors, asterisks and non-constant + * expressions are not permitted. + * (see page 114) + */ + IBM2014I: { + "code": "IBM2014I", + "severity": "S", + "message": "Extents in type descriptors must be constant.", + "fullCode": "IBM2014IS" + } as SimplePLICode, + + /** + * The VALUE attribute is allowed only with computational data types as well as pointer, + * offset, handle and ordinal. + * (see page 114) + */ + IBM2015I: { + "code": "IBM2015I", + "severity": "S", + "message": "VALUE attribute conflicts with data type.", + "fullCode": "IBM2015IS" + } as SimplePLICode, + + /** + * The VALUE attribute is not allowed with typed structures. + * (see page 115) + */ + IBM2016I: { + "code": "IBM2016I", + "severity": "S", + "message": "The VALUE attribute is not allowed with typed structures.", + "fullCode": "IBM2016IS" + } as SimplePLICode, + + /** + * INITIAL TO is not valid for NONNATIVE POINTERs. It is also invalid for non-POINTERs + * since they cannot be assigned addresses. + * (see page 115) + */ + IBM2017I: { + "code": "IBM2017I", + "severity": "S", + "message": "INITIAL TO is valid only for NATIVE POINTER.", + "fullCode": "IBM2017IS" + } as SimplePLICode, + + /** + * INITIAL TO is not supported for variables belonging to any storage class other than + * STATIC. + * (see page 115) + */ + IBM2018I: { + "code": "IBM2018I", + "severity": "S", + "message": "INITIAL TO is supported only for STATIC variables.", + "fullCode": "IBM2018IS" + } as SimplePLICode, + + /** + * Specify OPTIONS(LINKAGE(OPTLINK)) or, on WINDOWS, OPTIONS(LINKAGE(CDECL)) on the + * PROCEDURE or ENTRY having a parameter with the LIST attribute and then recompile + * . + * (see page 115) + */ + IBM2019I: { + "code": "IBM2019I", + "severity": "S", + "message": "Unsupported LINKAGE used with the LIST attribute.", + "fullCode": "IBM2019IS" + } as SimplePLICode, + + /** + * All references must be unambiguous. + * (see page 115) + */ + IBM2020I: { + "code": "IBM2020I", + "severity": "S", + "message": (referencename: string, structurename: string) => `There is more than one element named ${referencename} in the typed structure ${structurename} .`, + "fullCode": "IBM2020IS" + } as ParametricPLICode, + + /** + * All structure references must be explicitly declared. + * (see page 115) + */ + IBM2021I: { + "code": "IBM2021I", + "severity": "S", + "message": (referencename: string, structurename: string) => `There is no element named ${referencename} in the structure ${structurename} .`, + "fullCode": "IBM2021IS" + } as ParametricPLICode, + + /** + * Functions, but not subprocedures, can be used as typed structure qualifiers (and + * then only if they return a typed structure). + * (see page 115) + */ + IBM2022I: { + "code": "IBM2022I", + "severity": "S", + "message": (variablename: string) => `The ENTRY ${variablename} may not be used as a typed structure qualifier since it does not have the RETURNS attribute.`, + "fullCode": "IBM2022IS" + } as ParametricPLICode, + + /** + * x(...)=>y is invalid unless x returns a typed structure. + * (see page 115) + */ + IBM2023I: { + "code": "IBM2023I", + "severity": "S", + "message": (variablename: string) => `The ENTRY ${variablename} may not be used as a typed structure qualifier.`, + "fullCode": "IBM2023IS" + } as ParametricPLICode, + + /** + * For instance, if x is an array of structure t with member m, x.m(2) is invalid. However, + * x(2).m is valid. + * (see page 115) + */ + IBM2024I: { + "code": "IBM2024I", + "severity": "S", + "message": (variablename: string) => `The array variable ${variablename} may be used as a typed structure qualifier only if it is completely subscripted before its dot qualification.`, + "fullCode": "IBM2024IS" + } as ParametricPLICode, + + /** + * The named built-in function cannot be used as a typed structure qualifier. + * (see page 115) + */ + IBM2025I: { + "code": "IBM2025I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} built-in function may not be used as a typed structure qualifier.`, + "fullCode": "IBM2025IS" + } as ParametricPLICode, + + /** + * GENERIC references may not be used as typed structure qualifiers. + * (see page 115) + */ + IBM2026I: { + "code": "IBM2026I", + "severity": "S", + "message": "The GENERIC variable ${variable name } may not be used as a typed structure qualifier.", + "fullCode": "IBM2026IS" + } as SimplePLICode, + + /** + * x.y is invalid unless x is a structure, a union or a function returning a typed structure + * . + * (see page 115) + */ + IBM2027I: { + "code": "IBM2027I", + "severity": "S", + "message": (variablename: string) => `${variablename} may not be used as a structure qualifier.`, + "fullCode": "IBM2027IS" + } as ParametricPLICode, + + /** + * The DEFINE STRUCTURE or DEFINE ALIAS statement for a type x must precede any of use + * of x as attribute type. The following two statements should be in the opposite order. + * 115 + * ```pli + * dcl x type point; + * define structure + * 1 point, + * 2 x fixed bin(31), + * 2 y fixed bin(31); + * ``` + * (see page 115) + */ + IBM2028I: { + "code": "IBM2028I", + "severity": "S", + "message": "TYPEs must be defined before their use.", + "fullCode": "IBM2028IS" + } as SimplePLICode, + + /** + * A DEFINE STRUCTURE statement can specify just a level 1 name only if there no other + * attributes specified. The following are invalid + * ```pli + * define structure 1 int fixed bin; + * define structure 1 a type b; + * ``` + * (see page 116) + */ + IBM2029I: { + "code": "IBM2029I", + "severity": "S", + "message": "A DEFINE STRUCTURE statement must consist of a level one structure name optionally followed by its substructures. Use DEFINE ALIAS to set a name as a synonym for a data type.", + "fullCode": "IBM2029IS" + } as SimplePLICode, + + /** + * Defined structure types must be initialized via assignments. + * (see page 116) + */ + IBM2030I: { + "code": "IBM2030I", + "severity": "S", + "message": "INITIAL attribute is invalid in structure definitions.", + "fullCode": "IBM2030IS" + } as SimplePLICode, + + /** + * Storage attributes, such as AUTOMATIC and BYADDR, must be specified with variables + * declared with structure type. + * (see page 116) + */ + IBM2031I: { + "code": "IBM2031I", + "severity": "S", + "message": "Storage attributes are invalid in structure definition.", + "fullCode": "IBM2031IS" + } as SimplePLICode, + + /** + * The level 1 name in a structure definition may not have the DIMENSION attribute. + * (see page 116) + */ + IBM2032I: { + "code": "IBM2032I", + "severity": "S", + "message": "DEFINE STRUCTURE may not specify an array of structures.", + "fullCode": "IBM2032IS" + } as SimplePLICode, + + /** + * The syntax allows the name in a structure definition to be followed by a description + * list, but that description list must consist of exactly one structure description. + * The following is invalid: + * ```pli + * define structure + * 1 point, + * 2 x fixed bin(31), + * 2 y fixed bin(31), + * 1 rectangle, + * 2 upper_left type point, + * 2 lower_right type point; + * ``` + * (see page 116) + */ + IBM2033I: { + "code": "IBM2033I", + "severity": "S", + "message": "Only one description is allowed in a structure definition.", + "fullCode": "IBM2033IS" + } as SimplePLICode, + + /** + * The argument to the type functions FIRST and LAST must be an unambiguous type name, + * and that type must be an ordinal type. + * (see page 116) + */ + IBM2034I: { + "code": "IBM2034I", + "severity": "S", + "message": (typefunction: string) => `The argument to the type function ${typefunction} must be an ordinal type name.`, + "fullCode": "IBM2034IS" + } as ParametricPLICode, + + /** + * The argument to the type function NEW must be an unambiguous type name, and that + * type must be a structure type. + * (see page 116) + */ + IBM2035I: { + "code": "IBM2035I", + "severity": "S", + "message": (typefunction: string) => `The argument to the type function ${typefunction} must be a structure type name.`, + "fullCode": "IBM2035IS" + } as ParametricPLICode, + + /** + * The second argument to the BIND type function must be a pointer or offset value that + * is to be converted to a handle to the structure type named as the first argument + * . + * (see page 116) + */ + IBM2036I: { + "code": "IBM2036I", + "severity": "S", + "message": (typefunction: string) => `The second argument to the type function ${typefunction} must have locator type.`, + "fullCode": "IBM2036IS" + } as ParametricPLICode, + + /** + * The first argument to the type functions BIND must be an unambiguous type name, and + * that type must be a structure type. + * (see page 116) + */ + IBM2037I: { + "code": "IBM2037I", + "severity": "S", + "message": (typefunction: string) => `The first argument to the type function ${typefunction} must be a structure type name.`, + "fullCode": "IBM2037IS" + } as ParametricPLICode, + + /** + * An expression contains the named built-in function with an argument that is not a + * HANDLE. + * (see page 116) + */ + IBM2038I: { + "code": "IBM2038I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have HANDLE type.`, + "fullCode": "IBM2038IS" + } as ParametricPLICode, + + /** + * The TYPE pseudovariable can be applied only to HANDLEs. + * (see page 117) + */ + IBM2039I: { + "code": "IBM2039I", + "severity": "S", + "message": (variablename: string) => `Argument to ${variablename} pseudovariable must be a HANDLE.`, + "fullCode": "IBM2039IS" + } as ParametricPLICode, + + /** + * The first argument to the type function SIZE must be the unambiguous name of a defined + * type. + * (see page 117) + */ + IBM2040I: { + "code": "IBM2040I", + "severity": "S", + "message": (typefunction: string) => `The argument to the type function ${typefunction} must be a defined type.`, + "fullCode": "IBM2040IS" + } as ParametricPLICode, + + /** + * The first argument to the type function CAST must be the unambiguous name of a defined + * type. + * (see page 117) + */ + IBM2041I: { + "code": "IBM2041I", + "severity": "S", + "message": (typefunction: string) => `The first argument to the type function ${typefunction} must be a defined type.`, + "fullCode": "IBM2041IS" + } as ParametricPLICode, + + /** + * The second argument to the type function CAST must be a scalar. + * (see page 117) + */ + IBM2042I: { + "code": "IBM2042I", + "severity": "S", + "message": (typefunction: string) => `The second argument to the type function ${typefunction} must be a scalar.`, + "fullCode": "IBM2042IS" + } as ParametricPLICode, + + /** + * The second argument to the type function CAST must have the same size as the size + * of the type that is the first argument. + * (see page 117) + */ + IBM2043I: { + "code": "IBM2043I", + "severity": "S", + "message": (typefunction: string) => `The second argument to the type function ${typefunction} must have the same size as the first argument.`, + "fullCode": "IBM2043IS" + } as ParametricPLICode, + + /** + * The function should be declared as + * ```pli + * dcl get entry( pointer byvalue, + * fixed bin(31) byaddr, + * fixed bin(31) byaddr ) + * returns( pointer ); + * ``` + * (see page 117) + */ + IBM2044I: { + "code": "IBM2044I", + "severity": "S", + "message": (BUILTINname: string) => `The get storage function to ${BUILTINname} must be a LIMITED ENTRY with LINKAGE(OPTLINK) and an appropriate entry description list.`, + "fullCode": "IBM2044IS" + } as ParametricPLICode, + + /** + * The function should be declared as + * ```pli + * dcl free entry( pointer byvalue, + * pointer byvalue, + * fixed bin(31) byvalue ); + * ``` + * (see page 117) + */ + IBM2045I: { + "code": "IBM2045I", + "severity": "S", + "message": (BUILTINname: string) => `The free storage function to ${BUILTINname} must be a LIMITED ENTRY with LINKAGE(OPTLINK) and an appropriate entry description list.`, + "fullCode": "IBM2045IS" + } as ParametricPLICode, + + /** + * If an entry or procedure has a variable number of arguments in imitation of C, i.e. + * if its last parameter has the LIST attribute, then OPTIONS(NODESCRIPTOR) must be + * specified (and valid). + * (see page 117) + */ + IBM2046I: { + "code": "IBM2046I", + "severity": "S", + "message": "OPTIONS(NODESCRIPTOR) is required if the last parameter to an ENTRY or PROC has the LIST attribute.", + "fullCode": "IBM2046IS" + } as SimplePLICode, + + /** + * The VARGLIST built-in function obtains the address of the variable argument list + * passed to procedures whose last parameter had the LIST attribute. It may not be + * used in subprocedures of such routines or in procedures having either no parameters + * or having no parameter declared with the LIST attribute. + * (see page 117) + */ + IBM2047I: { + "code": "IBM2047I", + "severity": "S", + "message": "The VARGLIST built-in function may be used only inside PROCEDUREs whose last parameter had the LIST attribute.", + "fullCode": "IBM2047IS" + } as SimplePLICode, + + /** + * The LIST attribute causes a variable argument list to be built, and such argument + * lists are permitted neither with nested procedures nor with entry variables declared + * without the LIMITED attribute. + * (see page 117) + */ + IBM2048I: { + "code": "IBM2048I", + "severity": "S", + "message": "The LIST attribute may be specified only on non-nested PROCEDUREs, external entry constants, and limited entry variables.", + "fullCode": "IBM2048IS" + } as SimplePLICode, + + /** + * The LIST attribute indicates that zero or more parameters may be specified after + * it, but those parameters may not be described. + * (see page 117) + */ + IBM2049I: { + "code": "IBM2049I", + "severity": "S", + "message": "The LIST attribute may be specified only on the last element of an entry description list.", + "fullCode": "IBM2049IS" + } as SimplePLICode, + + /** + * If OPTIONS( FORTRAN DESCRIPTOR ) applies, all parameters other than character strings + * must have constant extents. + * (see page 118) + */ + IBM2050I: { + "code": "IBM2050I", + "severity": "S", + "message": "Descriptors are supported for Fortran only for scalar character strings.", + "fullCode": "IBM2050IS" + } as SimplePLICode, + + /** + * If OPTIONS( FORTRAN DESCRIPTOR ) applies to an ENTRY statement or to a procedure + * containing an ENTRY statement, all parameters must have constant extents. + * (see page 118) + */ + IBM2051I: { + "code": "IBM2051I", + "severity": "S", + "message": "Descriptors are not supported for Fortran for routines defined by or containing ENTRY statements.", + "fullCode": "IBM2051IS" + } as SimplePLICode, + + /** + * Either BYADDR must be specified in the RETURNS option of the PROCEDURE statement, + * or the RETURNS(BYADDR) suboption of the DEFAULT statement must be in effect. + * (see page 118) + */ + IBM2052I: { + "code": "IBM2052I", + "severity": "S", + "message": "A function defined by a PROCEDURE containing ENTRY statements must return aggregate values BYADDR.", + "fullCode": "IBM2052IS" + } as SimplePLICode, + + /** + * Either BYADDR must be specified in the RETURNS option of the ENTRY statement, or + * the RETURNS(BYADDR) suboption of the DEFAULT statement must be in effect. + * (see page 118) + */ + IBM2053I: { + "code": "IBM2053I", + "severity": "S", + "message": "A function defined by an ENTRY statement must return aggregate values BYADDR.", + "fullCode": "IBM2053IS" + } as SimplePLICode, + + /** + * Either BYADDR must be specified in the declares for the parameters, or the BYADDR + * suboption of the DEFAULT statement must be in effect. + * (see page 118) + */ + IBM2054I: { + "code": "IBM2054I", + "severity": "S", + "message": "A PROCEDURE containing ENTRY statements must receive all non- pointer parameters BYADDR.", + "fullCode": "IBM2054IS" + } as SimplePLICode, + + /** + * Either BYADDR must be specified in the declares for the parameters, or the BYADDR + * suboption of the DEFAULT statement must be in effect. + * (see page 118) + */ + IBM2055I: { + "code": "IBM2055I", + "severity": "S", + "message": "An ENTRY statement must receive all parameters BYADDR.", + "fullCode": "IBM2055IS" + } as SimplePLICode, + + /** + * ENTRY statements are allowed in non-iterative DO groups, but not in iterative DO + * loops. + * (see page 118) + */ + IBM2056I: { + "code": "IBM2056I", + "severity": "S", + "message": "ENTRY statement is not allowed in DO loops.", + "fullCode": "IBM2056IS" + } as SimplePLICode, + + /** + * A RETURN statement is valid inside a BEGIN block only if the PROCEDURE enclosing + * that BEGIN block contains no ENTRY statements. + * (see page 118) + */ + IBM2057I: { + "code": "IBM2057I", + "severity": "S", + "message": "RETURN statement is invalid inside a BEGIN in a PROCEDURE that contains ENTRY statements.", + "fullCode": "IBM2057IS" + } as SimplePLICode, + + /** + * Either BYADDR must be specified in the RETURNS option of the ENTRY statement, or + * the RETURNS(BYADDR) suboption of the DEFAULT statement must be in effect. + * (see page 118) + */ + IBM2058I: { + "code": "IBM2058I", + "severity": "S", + "message": "In a PROCEDURE without the RETURNS option, any ENTRY statement must use BYADDR for its RETURNS value.", + "fullCode": "IBM2058IS" + } as SimplePLICode, + + /** + * Only ALIGNED BIT strings with constant length are valid with OPTIONS(FORTRAN). + * (see page 118) + */ + IBM2059I: { + "code": "IBM2059I", + "severity": "S", + "message": "OPTIONS(FORTRAN) is invalid if any parameters are UNALIGNED BIT.", + "fullCode": "IBM2059IS" + } as SimplePLICode, + + /** + * Attributes may be specified only in ALLOCATEs of CONTROLLED variables. + * (see page 118) + */ + IBM2060I: { + "code": "IBM2060I", + "severity": "S", + "message": "Attributes may not be specified in ALLOCATEs of BASED variables.", + "fullCode": "IBM2060IS" + } as SimplePLICode, + + /** + * An attribute, such as CHARACTER, may be specified in an ALLOCATE statement only if + * it is also specified in the declaration of the variable to be allocated. + * (see page 118) + */ + IBM2061I: { + "code": "IBM2061I", + "severity": "S", + "message": "Attributes specified for ${variable name } in ALLOCATE statement do not match those in its declaration.", + "fullCode": "IBM2061IS" + } as SimplePLICode, + + /** + * In an ALLOCATE statement for a structure, all the levels specified in its declaration + * must be specified, and no new levels may be specified. + * (see page 119) + */ + IBM2062I: { + "code": "IBM2062I", + "severity": "S", + "message": (variablename: string) => `Structuring specified in ALLOCATE of ${variablename} does not match that in its declaration.`, + "fullCode": "IBM2062IS" + } as ParametricPLICode, + + /** + * An attribute, such as CHARACTER, may be specified in an ALLOCATE statement only if + * it is also specified in the declaration of the variable to be allocated with either + * an asterisk or a non-constant expression. + * (see page 119) + */ + IBM2063I: { + "code": "IBM2063I", + "severity": "S", + "message": (variablename: string) => `Specification of extent for ${variablename} in ALLOCATE statement is invalid since it was declared with a constant extent.`, + "fullCode": "IBM2063IS" + } as ParametricPLICode, + + /** + * If a bound for a CONTROLLED variable is declared as a constant, then it must be specified + * as the same constant value in any ALLOCATE statement for that variable. + * (see page 119) + */ + IBM2064I: { + "code": "IBM2064I", + "severity": "S", + "message": (dimensionvalue: string, variablename: string) => `The extent specified for the lower bound for dimension ${dimensionvalue} of ${variablename} in ALLOCATE statement is invalid since that variable was declared with a different constant extent.`, + "fullCode": "IBM2064IS" + } as ParametricPLICode, + + /** + * If a bound for a CONTROLLED variable is declared as a constant, then it must be specified + * as the same constant value in any ALLOCATE statement for that variable. + * (see page 119) + */ + IBM2065I: { + "code": "IBM2065I", + "severity": "S", + "message": (dimensionvalue: string, variablename: string) => `The extent specified for the upper bound for dimension ${dimensionvalue} of ${variablename} in ALLOCATE statement is invalid since that variable was declared with a different constant extent.`, + "fullCode": "IBM2065IS" + } as ParametricPLICode, + + /** + * A ENTRY type or argument used with the type function CAST must have the attribute + * LIMITED. + * (see page 119) + */ + IBM2075I: { + "code": "IBM2075I", + "severity": "S", + "message": (typefunction: string) => `ENTRY types and arguments in ${typefunction} must be LIMITED.`, + "fullCode": "IBM2075IS" + } as ParametricPLICode, + + /** + * A FLOAT type or argument used with the type function CAST must have the attributes + * NATIVE REAL. + * (see page 119) + */ + IBM2076I: { + "code": "IBM2076I", + "severity": "S", + "message": (typefunction: string) => `FLOAT types and arguments in ${typefunction} must be NATIVE REAL.`, + "fullCode": "IBM2076IS" + } as ParametricPLICode, + + /** + * A FIXED BIN type or argument used with the type function CAST must have the attributes + * REAL PRECISION(p,0). + * (see page 119) + */ + IBM2077I: { + "code": "IBM2077I", + "severity": "S", + "message": (typefunction: string) => `FIXED BIN types and arguments in ${typefunction} must be REAL with scale factor zero.`, + "fullCode": "IBM2077IS" + } as ParametricPLICode, + + /** + * The first argument to the type function CAST must be a type with one of the following + * sets of attributes: REAL FIXED BIN(p,0) or NATIVE REAL FLOAT. + * (see page 119) + */ + IBM2078I: { + "code": "IBM2078I", + "severity": "S", + "message": (attributes: string, typefunction: string) => `Types with the attributes ${attributes} are not supported as the target of the ${typefunction} function.`, + "fullCode": "IBM2078IS" + } as ParametricPLICode, + + /** + * The second argument to the type function CAST must have one of the following sets + * of attributes: REAL FIXED BIN(p,0) or NATIVE REAL FLOAT. + * (see page 119) + */ + IBM2079I: { + "code": "IBM2079I", + "severity": "S", + "message": (attributes: string, typefunction: string) => `Arguments with the attributes ${attributes} are not supported as the source in the ${typefunction} function.`, + "fullCode": "IBM2079IS" + } as ParametricPLICode, + + /** + * See the Language Reference Manual for a list of the supported DATE patterns. + * (see page 119) + */ + IBM2080I: { + "code": "IBM2080I", + "severity": "S", + "message": "DATE pattern is invalid.", + "fullCode": "IBM2080IS" + } as SimplePLICode, + + /** + * The DATE attribute cannot be used on any other than the named types. + * (see page 119) + */ + IBM2081I: { + "code": "IBM2081I", + "severity": "S", + "message": "DATE attribute is valid only with NONVARYING CHARACTER, FIXED DECIMAL and arithmetic PICTURE.", + "fullCode": "IBM2081IS" + } as SimplePLICode, + + /** + * The DATE attribute can be used on a numeric only if it has a scale factor of zero + * . + * (see page 120) + */ + IBM2082I: { + "code": "IBM2082I", + "severity": "S", + "message": "DATE attribute conflicts with non- zero scale factor.", + "fullCode": "IBM2082IS" + } as SimplePLICode, + + /** + * The DATE attribute can be used on a numeric only if it is REAL. + * (see page 120) + */ + IBM2083I: { + "code": "IBM2083I", + "severity": "S", + "message": "DATE attribute conflicts with COMPLEX attribute.", + "fullCode": "IBM2083IS" + } as SimplePLICode, + + /** + * The DATE attribute can be used on a PICTURE only if the PICTURE consists entirely + * of 9's. + * (see page 120) + */ + IBM2084I: { + "code": "IBM2084I", + "severity": "S", + "message": "DATE attribute conflicts with PICTURE string containing characters other than 9.", + "fullCode": "IBM2084IS" + } as SimplePLICode, + + /** + * The DATE attribute can be used on a numeric only if its precision equals the length + * of the DATE pattern. + * (see page 120) + */ + IBM2085I: { + "code": "IBM2085I", + "severity": "S", + "message": "Length of DATE pattern and base precision do not match.", + "fullCode": "IBM2085IS" + } as SimplePLICode, + + /** + * The DATE attribute can be used on a string only if its length equals the length of + * the DATE pattern. + * (see page 120) + */ + IBM2086I: { + "code": "IBM2086I", + "severity": "S", + "message": "Length of DATE pattern and base length do not match.", + "fullCode": "IBM2086IS" + } as SimplePLICode, + + /** + * The DATE attribute can be used on a string only if the string is declared with a + * constant length. + * (see page 120) + */ + IBM2087I: { + "code": "IBM2087I", + "severity": "S", + "message": "DATE attribute conflicts with adjustable length.", + "fullCode": "IBM2087IS" + } as SimplePLICode, + + /** + * The options string built from the response file must be less than 32767 characters + * long. + * (see page 120) + */ + IBM2088I: { + "code": "IBM2088I", + "severity": "S", + "message": "Response file is too large. Excess will be ignored.", + "fullCode": "IBM2088IS" + } as SimplePLICode, + + /** + * All lines in any response file must contain no more than 100 characters. + * (see page 120) + */ + IBM2089I: { + "code": "IBM2089I", + "severity": "S", + "message": "Line in response file is longer than 100 characters. That line and rest of file will be ignored.", + "fullCode": "IBM2089IS" + } as SimplePLICode, + + /** + * The named statement cannot be used under CICS. + * (see page 120) + */ + IBM2090I: { + "code": "IBM2090I", + "severity": "S", + "message": (keyword: string) => `The ${keyword} statement cannot be used under SYSTEM(CICS).`, + "fullCode": "IBM2090IS" + } as ParametricPLICode, + + /** + * DISPLAY with REPLY cannot be used under CICS. + * (see page 120) + */ + IBM2091I: { + "code": "IBM2091I", + "severity": "S", + "message": "DISPLAY with REPLY cannot be used under SYSTEM(CICS).", + "fullCode": "IBM2091IS" + } as SimplePLICode, + + /** + * The named built-in function cannot be used under CICS. + * (see page 120) + */ + IBM2092I: { + "code": "IBM2092I", + "severity": "S", + "message": (BUILTINname: string) => `The ${BUILTINname} built-in function cannot be used under SYSTEM(CICS).`, + "fullCode": "IBM2092IS" + } as ParametricPLICode, + + /** + * The named I\/O statement cannot be used under CICS unless the file used in the statement + * is SYSPRINT. + * (see page 120) + */ + IBM2093I: { + "code": "IBM2093I", + "severity": "S", + "message": (keyword: string) => `The ${keyword} statement cannot be used under SYSTEM(CICS) except with SYSPRINT.`, + "fullCode": "IBM2093IS" + } as ParametricPLICode, + + /** + * The source in a CAST to a FLOAT must be FLOAT, FIXED or ORDINAL. + * (see page 120) + */ + IBM2094I: { + "code": "IBM2094I", + "severity": "S", + "message": "Source in CAST to FLOAT must be FLOAT, FIXED or ORDINAL.", + "fullCode": "IBM2094IS" + } as SimplePLICode, + + /** + * The target in a CAST from a FLOAT must be FLOAT, FIXED BIN or ORDINAL. + * (see page 120) + */ + IBM2095I: { + "code": "IBM2095I", + "severity": "S", + "message": "Target in CAST from FLOAT must be FLOAT, FIXED BIN or ORDINAL.", + "fullCode": "IBM2095IS" + } as SimplePLICode, + + /** + * The target in a CAST from a FIXED DEC must be FLOAT, FIXED BIN or ORDINAL. + * (see page 120) + */ + IBM2096I: { + "code": "IBM2096I", + "severity": "S", + "message": "Target in CAST from FIXED DEC must be FLOAT, FIXED BIN or ORDINAL.", + "fullCode": "IBM2096IS" + } as SimplePLICode, + + /** + * A FIXED DEC type or argument used with the type function CAST must have the attributes + * REAL PRECISION(p,q) with p >= q and q >= 0. + * (see page 121) + */ + IBM2097I: { + "code": "IBM2097I", + "severity": "S", + "message": (typefunction: string) => `FIXED DEC types and arguments in ${typefunction} must be REAL with non-negative scale factor.`, + "fullCode": "IBM2097IS" + } as ParametricPLICode, + + /** + * The source in a CAST to a FIXED DEC must be FLOAT, FIXED or ORDINAL. + * (see page 121) + */ + IBM2098I: { + "code": "IBM2098I", + "severity": "S", + "message": "Source in CAST to FIXED DEC must be FLOAT, FIXED or ORDINAL.", + "fullCode": "IBM2098IS" + } as SimplePLICode, + + /** + * The two strings in the CASEX option must have the same length. The second argument + * is the uppercase value of the first. If a character in the first string does not + * have an uppercase value, use the character itself as the uppercase value. + * (see page 121) + */ + IBM2099I: { + "code": "IBM2099I", + "severity": "S", + "message": "CASEX strings must have the same length.", + "fullCode": "IBM2099IS" + } as SimplePLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2100I: { + "code": "IBM2100I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. The ORDINAL types do not match.`, + "fullCode": "IBM2100IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2101I: { + "code": "IBM2101I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. The HANDLE types do not match.`, + "fullCode": "IBM2101IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2102I: { + "code": "IBM2102I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. The STRUCTURE types do not match.`, + "fullCode": "IBM2102IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2103I: { + "code": "IBM2103I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Alignment does not match.`, + "fullCode": "IBM2103IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2104I: { + "code": "IBM2104I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Number and attributes of structure members do not match.`, + "fullCode": "IBM2104IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2105I: { + "code": "IBM2105I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. The number of dimensions do not match.`, + "fullCode": "IBM2105IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2106I: { + "code": "IBM2106I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Lower bounds do not match.`, + "fullCode": "IBM2106IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 121) + */ + IBM2107I: { + "code": "IBM2107I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Upper bounds do not match.`, + "fullCode": "IBM2107IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2108I: { + "code": "IBM2108I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. RETURNS attributes do not match.`, + "fullCode": "IBM2108IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2109I: { + "code": "IBM2109I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. BYVALUE and BYADDR attributes in RETURNS do not match.`, + "fullCode": "IBM2109IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2110I: { + "code": "IBM2110I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. LINKAGE values do not match.`, + "fullCode": "IBM2110IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2111I: { + "code": "IBM2111I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. OPTIONS values do not match.`, + "fullCode": "IBM2111IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2112I: { + "code": "IBM2112I", + "severity": "S", + "message": (variablename: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Parameter counts do not match.`, + "fullCode": "IBM2112IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2113I: { + "code": "IBM2113I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. BYVALUE and BYADDR attributes in parameter ${parameternumber} do not match.`, + "fullCode": "IBM2113IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2114I: { + "code": "IBM2114I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. The number of dimensions for parameter ${parameternumber} do not match.`, + "fullCode": "IBM2114IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2115I: { + "code": "IBM2115I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Lower bounds for parameter ${parameternumber} do not match.`, + "fullCode": "IBM2115IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2116I: { + "code": "IBM2116I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Upper bounds for parameter ${parameternumber} do not match.`, + "fullCode": "IBM2116IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 122) + */ + IBM2117I: { + "code": "IBM2117I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do 122 not match those in its previous declaration. Alignment of parameter ${parameternumber} does not match.`, + "fullCode": "IBM2117IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 123) + */ + IBM2118I: { + "code": "IBM2118I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Number and attributes of structure members in parameter ${parameternumber} do not match.`, + "fullCode": "IBM2118IS" + } as ParametricPLICode, + + /** + * EXTERNAL variables can be declared in more than one procedure in a compilation unit, + * but the attributes in those declarations must match. + * (see page 123) + */ + IBM2119I: { + "code": "IBM2119I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes of the EXTERNAL variable ${variablename} do not match those in its previous declaration. Attributes of parameter ${parameternumber} do not match.`, + "fullCode": "IBM2119IS" + } as ParametricPLICode, + + /** + * But an AREA may be output parameter. + * (see page 123) + */ + IBM2120I: { + "code": "IBM2120I", + "severity": "S", + "message": "AREAs are not supported in RETURNS.", + "fullCode": "IBM2120IS" + } as SimplePLICode, + + /** + * For a AREA parameter declared with constant size, any corresponding argument must + * have equal constant size. Dummy AREA arguments are not supported in this scenario + * . + * ```pli + * dcl x entry( area(10000) ); + * dcl a area(8000) ); + * call x( a ); + * ``` + * (see page 123) + */ + IBM2121I: { + "code": "IBM2121I", + "severity": "S", + "message": "Argument number ${argument number } in ENTRY reference ${entry name } must have the same size as the corresponding parameter.", + "fullCode": "IBM2121IS" + } as SimplePLICode, + + /** + * The IBMUEXIT routine should have a PACKAGE statement that specifies EXPORTS( IBMUEXIT + * ) and not EXPORTS( * ). + * (see page 123) + */ + IBM2122I: { + "code": "IBM2122I", + "severity": "S", + "message": "User exit routine addresses are invalid. Check that the user exit routine is a PACKAGE that exports only IBMUEXIT.", + "fullCode": "IBM2122IS" + } as SimplePLICode, + + /** + * The total number of dimensions allowed in a DEFINED STRUCTURE type used in XMLCHAR + * must not exceed 15. + * (see page 123) + */ + IBM2123I: { + "code": "IBM2123I", + "severity": "S", + "message": "When expanded, DEFINE STRUCTURE type would have an array with more than 15 total dimensions.", + "fullCode": "IBM2123IS" + } as SimplePLICode, + + /** + * The total number of logical levels allowed in a DEFINED STRUCTURE type used in XMLCHAR + * must not exceed 15. + * (see page 123) + */ + IBM2124I: { + "code": "IBM2124I", + "severity": "S", + "message": "When expanded, DEFINE STRUCTURE type would contain more than 15 logical levels.", + "fullCode": "IBM2124IS" + } as SimplePLICode, + + /** + * The use of DEFINE STRUCTURE types is not supported in GET DATA statements. + * ```pli + * define structure + * 1 a, + * 2 a1 fixed bin(31), + * 2 a2 fixed bin(31); + * dcl x type a; + * get skip data( x ); + * ``` + * (see page 123) + */ + IBM2125I: { + "code": "IBM2125I", + "severity": "S", + "message": (variablename: string) => `${variablename} is a typed structure and hence cannot be used in GET DATA.`, + "fullCode": "IBM2125IS" + } as ParametricPLICode, + + /** + * The use of members of DEFINE STRUCTURE types is not supported in data directed I\/O + * statements. + * ```pli + * define structure + * 1 a, + * 2 a1 fixed bin(31), + * 2 a2 fixed bin(31); + * dcl x type a; + * x.a1 = 17; + * x.a2 = 29; + * put skip data( x.a ); + * ``` + * (see page 123) + */ + IBM2126I: { + "code": "IBM2126I", + "severity": "S", + "message": (variablename: string) => `${variablename} is a member of a typed structure and hence cannot be used in data directed I/O.`, + "fullCode": "IBM2126IS" + } as ParametricPLICode, + + /** + * A match for the GENERIC reference has been found, but the match is not suitable because + * while the GENERIC reference is used as a function, the matching ENTRY is not a function. + * For example, the first GENERIC reference below is invalid, while the second is ok + * . + * ```pli + * dcl e1 entry( fixed bin ); + * dcl e2 entry( fixed bin, fixed bin ) + * returns( fixed bin ); + * dcl gp generic( e1 when( * ), + * e2 when( *, * ) ); + * rc = gp( 0 ); + * rc = gp( 0, 0 ); + * ``` + * (see page 124) + */ + IBM2127I: { + "code": "IBM2127I", + "severity": "S", + "message": "The ENTRY named ${ENTRYvariable name } matches the reference to the GENERIC variable ${GENERIC variablename } , but while the GENERIC reference is used as a function, the matching ENTRY does not have the RETURNS attribute.", + "fullCode": "IBM2127IS" + } as SimplePLICode, + + /** + * A match for the GENERIC reference has been found, but the match is not suitable because + * while the GENERIC reference is used as a locator, the matching ENTRY is not a function + * returning a POINTER. For example, the first GENERIC reference below is invalid, + * while the second is ok. + * ```pli + * dcl f1 entry( fixed bin ) returns( fixed + * bin ); + * dcl f2 entry( fixed bin, fixed bin ) + * returns( pointer ); + * dcl bx based fixed bin; + * dcl gf generic( f1 when( * ), + * f2 when( *, * ) ); + * rc = gf( 0 )->bx; + * rc = gf( 0, 0 )->bx; + * ``` + * (see page 124) + */ + IBM2128I: { + "code": "IBM2128I", + "severity": "S", + "message": "The ENTRY named ${ENTRYvariable name } matches the reference to the GENERIC variable ${GENERIC variablename } , but while the GENERIC reference is used as a function acting as a locator qualifier, the matching ENTRY does not return a POINTER.", + "fullCode": "IBM2128IS" + } as SimplePLICode, + + /** + * A match for the GENERIC reference has been found, but the match is not suitable because + * while the GENERIC reference is used as a function whose return value is a function + * that is invoked (and so on, as the number of argument lists mandates), the matching + * ENTRY cannot be so used. For example, the first GENERIC reference below is invalid, + * while the second is ok. + * ```pli + * dcl x1 entry( fixed bin ) + * returns( entry ); + * dcl x2 entry( fixed bin, fixed bin ) + * returns( entry returns( fixed + * bin ) ); + * dcl gx generic( x1 when( * ), + * x2 when( *, * ) ); + * rc = gx( 0 )(); + * rc = gx( 0, 0 )(); + * ``` + * (see page 124) + */ + IBM2129I: { + "code": "IBM2129I", + "severity": "S", + "message": "The ENTRY named ${ENTRYvariable name } matches the reference to the GENERIC variable ${GENERIC variablename } , but while the GENERIC reference is used as a repeating function reference, the matching ENTRY cannot be so used.", + "fullCode": "IBM2129IS" + } as SimplePLICode, + + /** + * The POSITION attribute can be used only with string overlay defining. + * ```pli + * dcl b(4) char(2) pos(2) def( a(1sub,1sub) ); + * ``` 124 + * (see page 124) + */ + IBM2130I: { + "code": "IBM2130I", + "severity": "S", + "message": "iSUB defining is not valid with the POSITION attribute.", + "fullCode": "IBM2130IS" + } as SimplePLICode, + + /** + * The defined and base arrays in iSUB defining must have identical attributes apart + * from the dimension attribute. + * ```pli + * dcl a(4) fixed bin(31); + * dcl b(4) fixed bin(15) def( a(1sub,1sub) ); + * ``` + * (see page 125) + */ + IBM2131I: { + "code": "IBM2131I", + "severity": "S", + "message": "In iSUB defining, the base and DEFINED variables must match.", + "fullCode": "IBM2131IS" + } as SimplePLICode, + + /** + * The i in an iSUB reference must refer to a subscript of the DEFINED variable and + * hence must not be greater than the number of dimensions for that variable. + * ```pli + * dcl a(4,4) fixed bin(31); + * dcl b(4) fixed bin(15) def( a(1sub,2sub) ); + * ``` + * (see page 125) + */ + IBM2132I: { + "code": "IBM2132I", + "severity": "S", + "message": "The i in an iSUB reference must not exceed the dimensionality of the DEFINED variable.", + "fullCode": "IBM2132IS" + } as SimplePLICode, + + /** + * In an iSUB variable, no asterisks may appear in the specification of the base array + * . + * ```pli + * dcl a(4,4) fixed bin(31); + * dcl b(4) fixed bin(15) def( a(1sub,*) ); + * ``` + * (see page 125) + */ + IBM2133I: { + "code": "IBM2133I", + "severity": "S", + "message": "An iSUB variable cannot be defined on a cross-section of its base.", + "fullCode": "IBM2133IS" + } as SimplePLICode, + + /** + * iSUB defining is not supported for structures and unions. + * (see page 125) + */ + IBM2134I: { + "code": "IBM2134I", + "severity": "S", + "message": "iSUB defining is supported only for arrays of scalars.", + "fullCode": "IBM2134IS" + } as SimplePLICode, + + /** + * If CMPAT(V1) or CMPAT(V2) is specified, then DFT(DESCLOCATOR) must be in effect (as + * it is by default on z\/OS). + * (see page 125) + */ + IBM2135I: { + "code": "IBM2135I", + "severity": "S", + "message": (cmpatsuboption: string) => `DFT(DESCLIST) conflicts with CMPAT( ${cmpatsuboption} ).`, + "fullCode": "IBM2135IS" + } as ParametricPLICode, + + /** + * The number of indices given for an element of a label constant array must not vary + * . + * ```pli + * a(1,1): .... + * a(1,2): .... + * a(3): .... + * ``` + * (see page 125) + */ + IBM2136I: { + "code": "IBM2136I", + "severity": "S", + "message": (identifier: string) => `The number of indices specified for the LABEL ${identifier} does not match the number previously specified.`, + "fullCode": "IBM2136IS" + } as ParametricPLICode, + + /** + * A label constant cannot be subscripted if its first use contains no subscripts. + * ```pli + * a: .... + * a(3): .... + * ``` + * (see page 125) + */ + IBM2137I: { + "code": "IBM2137I", + "severity": "S", + "message": (identifier: string) => `Indices have been specified for the LABEL ${identifier} when it was previously specified without indices.`, + "fullCode": "IBM2137IS" + } as ParametricPLICode, + + /** + * A label constant must be subscripted if its first use contains subscripts. + * ```pli + * a(3): .... + * a: .... + * ``` + * (see page 125) + */ + IBM2138I: { + "code": "IBM2138I", + "severity": "S", + "message": (identifier: string) => `Indices have not been specified for the LABEL ${identifier} when it was previously specified with indices.`, + "fullCode": "IBM2138IS" + } as ParametricPLICode, + + /** + * The compiler requires that you use z\/OS Language Environment V2 R1 or later. + * (see page 125) + */ + IBM2139I: { + "code": "IBM2139I", + "severity": "S", + "message": "The Language Enviroment run- time is not current enough.", + "fullCode": "IBM2139IS" + } as SimplePLICode, + + /** + * The second argument to the REPLACEBY2 built-in function provides the set of pairs + * of characters which are to replace the corresponding characters in the third argument, + * and hence the length of the second string must be twice that of the third. + * (see page 125) + */ + IBM2140I: { + "code": "IBM2140I", + "severity": "S", + "message": "Length of second argument to the REPLACEBY2 built-in function must be twice that of the third.", + "fullCode": "IBM2140IS" + } as SimplePLICode, + + /** + * The first argument to the named built-in subroutine must be a structure. + * (see page 126) + */ + IBM2141I: { + "code": "IBM2141I", + "severity": "S", + "message": "First argument to the ${BUILTIN name } built-in function must be a structure.", + "fullCode": "IBM2141IS" + } as SimplePLICode, + + /** + * The first argument to the named built-in subroutine must be a structure supplying + * the event handlers for the SAX parser, and that structure must have exactly the + * right number of members. See the Programming Guide for more details. + * (see page 126) + */ + IBM2142I: { + "code": "IBM2142I", + "severity": "S", + "message": (BUILTINname: string) => `Event structure argument to the ${BUILTINname} built-in function has too few elements.`, + "fullCode": "IBM2142IS" + } as ParametricPLICode, + + /** + * The first argument to the named built-in subroutine must be a structure supplying + * the event handlers for the SAX parser, and that structure must have exactly the + * right number of members. See the Programming Guide for more details. + * (see page 126) + */ + IBM2143I: { + "code": "IBM2143I", + "severity": "S", + "message": (BUILTINname: string) => `Event structure argument to the ${BUILTINname} built-in function has too many elements.`, + "fullCode": "IBM2143IS" + } as ParametricPLICode, + + /** + * The first argument to the named built-in subroutine must be a structure supplying + * the event handlers for the SAX parser, and each element of that structure must be + * a scalar. See the Programming Guide for more details. + * (see page 126) + */ + IBM2144I: { + "code": "IBM2144I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function is not a scalar.`, + "fullCode": "IBM2144IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must be a LIMITED ENTRY. See the Programming Guide for more details. + * (see page 126) + */ + IBM2145I: { + "code": "IBM2145I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must be a LIMITED ENTRY.`, + "fullCode": "IBM2145IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must be a function returning BYVALUE a NATIVE FIXED BIN(31). See the Programming + * Guide for more details. + * (see page 126) + */ + IBM2146I: { + "code": "IBM2146I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must return BYVALUE a NATIVE FIXED BIN(31).`, + "fullCode": "IBM2146IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a non- empty entry description list. See the Programming Guide for more + * details. + * (see page 126) + */ + IBM2147I: { + "code": "IBM2147I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a non-empty entry description list.`, + "fullCode": "IBM2147IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have the correct number of parameters. See the Programming Guide for more details + * . + * (see page 126) + */ + IBM2148I: { + "code": "IBM2148I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string, specifiedparmcount: string, requiredparmcount: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function has a parameter count of ${specifiedparmcount} when the correct parameter count is ${requiredparmcount} .`, + "fullCode": "IBM2148IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE POINTER as its first parameter. See the Programming Guide for + * more details. + * (see page 126) + */ + IBM2149I: { + "code": "IBM2149I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE POINTER as its first parameter.`, + "fullCode": "IBM2149IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE POINTER as its second parameter. See the Programming Guide for + * more details. + * (see page 127) + */ + IBM2150I: { + "code": "IBM2150I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE POINTER as its second parameter.`, + "fullCode": "IBM2150IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE NATIVE FIXED BIN(31) as its third parameter. See the Programming + * Guide for more details. + * (see page 127) + */ + IBM2151I: { + "code": "IBM2151I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE NATIVE FIXED BIN(31) as its third parameter.`, + "fullCode": "IBM2151IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE POINTER as its fourth parameter. See the Programming Guide for + * more details. + * (see page 127) + */ + IBM2152I: { + "code": "IBM2152I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE POINTER as its fourth parameter.`, + "fullCode": "IBM2152IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE NATIVE FIXED BIN(31) as its fifth parameter. See the Programming + * Guide for more details. + * (see page 127) + */ + IBM2153I: { + "code": "IBM2153I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE NATIVE FIXED BIN(31) as its fifth parameter.`, + "fullCode": "IBM2153IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE POINTER as its second parameter. See the Programming Guide for + * more details. + * (see page 127) + */ + IBM2154I: { + "code": "IBM2154I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE POINTER as its second parameter.`, + "fullCode": "IBM2154IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE NATIVE FIXED BIN(31) as its fourth parameter. See the Programming + * Guide for more details. + * (see page 127) + */ + IBM2155I: { + "code": "IBM2155I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE NATIVE FIXED BIN(31) as its fourth parameter.`, + "fullCode": "IBM2155IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE NATIVE FIXED BIN(31) as its second parameter. See the Programming + * Guide for more details. + * (see page 127) + */ + IBM2156I: { + "code": "IBM2156I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE NATIVE FIXED BIN(31) as its second parameter.`, + "fullCode": "IBM2156IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE CHAR (or BYVALUE WIDECHAR) of length one as its second parameter. + * See the Programming Guide for more details. + * (see page 127) + */ + IBM2157I: { + "code": "IBM2157I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE CHAR(1) or BYVALUE WCHAR(1) as its second parameter.`, + "fullCode": "IBM2157IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have the PL\/I default linkage. See the Programming Guide for more details + * . + * (see page 127) + */ + IBM2158I: { + "code": "IBM2158I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function has the wrong linkage.`, + "fullCode": "IBM2158IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have the NODESCRIPTOR option. See the Programming Guide for more details. + * (see page 128) + */ + IBM2159I: { + "code": "IBM2159I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have the NODESCRIPTOR option.`, + "fullCode": "IBM2159IS" + } as ParametricPLICode, + + /** + * The XMLCHAR built-in function cannot be applied to structures containing noncomputational + * types. + * (see page 128) + */ + IBM2160I: { + "code": "IBM2160I", + "severity": "S", + "message": (BUILTINname: string) => `All members of the input structure to the ${BUILTINname} built-in function must have computational type.`, + "fullCode": "IBM2160IS" + } as ParametricPLICode, + + /** + * The XMLCHAR built-in function cannot be applied to unions or to structures containing + * unions. + * (see page 128) + */ + IBM2161I: { + "code": "IBM2161I", + "severity": "S", + "message": "The input structure to the ${BUILTIN name } built-in function must not be a UNION or contain any UNIONs.", + "fullCode": "IBM2161IS" + } as SimplePLICode, + + /** + * The XMLCHAR built-in function cannot be applied to structures containing any GRAPHIC + * data. + * (see page 128) + */ + IBM2162I: { + "code": "IBM2162I", + "severity": "S", + "message": "The input structure to the ${BUILTIN name } built-in function must not contain any GRAPHIC elements.", + "fullCode": "IBM2162IS" + } as SimplePLICode, + + /** + * The XMLCHAR built-in function cannot be applied to structures containing any WIDECHAR + * or WIDEPIC data. + * (see page 128) + */ + IBM2163I: { + "code": "IBM2163I", + "severity": "S", + "message": "The input structure to the ${BUILTIN name } built-in function must not contain any UTF-16 elements.", + "fullCode": "IBM2163IS" + } as SimplePLICode, + + /** + * The XMLCHAR built-in function cannot be applied to structures containing substructures + * using an asterisk as a name. + * (see page 128) + */ + IBM2164I: { + "code": "IBM2164I", + "severity": "S", + "message": (BUILTINname: string) => `The input structure to the ${BUILTINname} built-in function must not contain any unnamed substructures.`, + "fullCode": "IBM2164IS" + } as ParametricPLICode, + + /** + * Support for long external names is incompatible with support for using the PRV to + * address CONTROLLED variables. + * (see page 128) + */ + IBM2165I: { + "code": "IBM2165I", + "severity": "S", + "message": "PRV support is provided only if the LIMITS(EXTNAME(7)) option is in effect.", + "fullCode": "IBM2165IS" + } as SimplePLICode, + + /** + * Support for the RENT option is incompatible with support for using the PRV to address + * CONTROLLED variables. + * (see page 128) + */ + IBM2166I: { + "code": "IBM2166I", + "severity": "S", + "message": "PRV support is provided only if the NORENT option is in effect.", + "fullCode": "IBM2166IS" + } as SimplePLICode, + + /** + * Support for the CMPAT(LE) option is incompatible with support for using the PRV to + * address CONTROLLED variables. + * (see page 128) + */ + IBM2167I: { + "code": "IBM2167I", + "severity": "S", + "message": "PRV support is provided only if the CMPAT(V2) or CMPAT(V3) option is in effect.", + "fullCode": "IBM2167IS" + } as SimplePLICode, + + /** + * When using the PRV to address CONTROLLED variables, there may be no more than 568 + * INTERNAL CONTROLLED variables. + * (see page 128) + */ + IBM2170I: { + "code": "IBM2170I", + "severity": "S", + "message": "Too many INTERNAL CONTROLLED variables.", + "fullCode": "IBM2170IS" + } as SimplePLICode, + + /** + * Under the NOWRITABLE option, every FETCHABLE ENTRY constant must be declared inside + * a PROCEDURE. + * (see page 128) + */ + IBM2171I: { + "code": "IBM2171I", + "severity": "S", + "message": "Under the NOWRITABLE option, no FETCHABLE ENTRY may be declared at the PACKAGE level.", + "fullCode": "IBM2171IS" + } as SimplePLICode, + + /** + * Under the NOWRITABLE option, every FILE CONSTANT must be declared inside a PROCEDURE + * . + * (see page 128) + */ + IBM2172I: { + "code": "IBM2172I", + "severity": "S", + "message": "Under the NOWRITABLE option, no FILE CONSTANT may be declared at the PACKAGE level.", + "fullCode": "IBM2172IS" + } as SimplePLICode, + + /** + * Under the NOWRITABLE option, every CONTROLLED variable must be declared inside a + * PROCEDURE. + * (see page 129) + */ + IBM2173I: { + "code": "IBM2173I", + "severity": "S", + "message": "Under the NOWRITABLE option, no CONTROLLED may be declared at the PACKAGE level.", + "fullCode": "IBM2173IS" + } as SimplePLICode, + + /** + * The length of the string literal produced by applying the REPLACEBY2 built-in function + * to 3 literals must not be greater than the maximum allowed for a character literal + * . + * (see page 129) + */ + IBM2174I: { + "code": "IBM2174I", + "severity": "S", + "message": "Result of REPLACEBY2 is too long.", + "fullCode": "IBM2174IS" + } as SimplePLICode, + + /** + * The REPLACEBY2 built-in function currently supports only second and third arguments + * that have a length and value known at compile time. + * (see page 129) + */ + IBM2175I: { + "code": "IBM2175I", + "severity": "S", + "message": "The second and third arguments to REPLACEBY2 must be restricted expressions.", + "fullCode": "IBM2175IS" + } as SimplePLICode, + + /** + * The HEX and HEXIMAGE built-in functions cannot be applied to strings using more than + * 16383 bytes of storage. + * (see page 129) + */ + IBM2176I: { + "code": "IBM2176I", + "severity": "S", + "message": (BUILTINname: string) => `The result of the ${BUILTINname} built-in function would require more than 32767 bytes.`, + "fullCode": "IBM2176IS" + } as ParametricPLICode, + + /** + * The named file is the file intended to be used as the SYSADATA file, but such a file + * must not be a member of a PDS. + * (see page 129) + */ + IBM2177I: { + "code": "IBM2177I", + "severity": "S", + "message": (filename: string) => `The file ${filename} is a PDS member and hence cannot be used for SYSADATA.`, + "fullCode": "IBM2177IS" + } as ParametricPLICode, + + /** + * When the LINEDIR option is in effect, your source must contain no INCLUDE statements + * . + * (see page 129) + */ + IBM2178I: { + "code": "IBM2178I", + "severity": "S", + "message": "INCLUDE statements are not supported when the LINEDIR option is in effect.", + "fullCode": "IBM2178IS" + } as SimplePLICode, + + /** + * The %LINE directive generated by the PPTRACE must fit on one line. You must either + * make the margins wide enough to allow this or make the source file names short enough + * . + * (see page 129) + */ + IBM2179I: { + "code": "IBM2179I", + "severity": "S", + "message": "There is too little room between the margins for the LINE directive. The PPTRACE option will be turned off.", + "fullCode": "IBM2179IS" + } as SimplePLICode, + + /** + * Any input\/output operation using a KEYED DIRECT file must include the key of the + * record to which the the operation is to be applied. + * (see page 129) + */ + IBM2180I: { + "code": "IBM2180I", + "severity": "S", + "message": (filename: string, keyword: string) => `Use of the KEYED DIRECT file ${filename} in a ${keyword} statement without a KEY/KEYFROM clause is invalid.`, + "fullCode": "IBM2180IS" + } as ParametricPLICode, + + /** + * This applies to the PICSPEC built-in function, for example. + * (see page 129) + */ + IBM2181I: { + "code": "IBM2181I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type CHARACTER.`, + "fullCode": "IBM2181IS" + } as ParametricPLICode, + + /** + * The specified argument to the named built-in function must be a restricted expression. + * This applies to second argument to the PICSPEC built-in function, for example. + * (see page 129) + */ + IBM2182I: { + "code": "IBM2182I", + "severity": "S", + "message": (argumentnumber: string, BUILTINname: string) => `Argument number ${argumentnumber} to ${BUILTINname} built-in function must be a constant.`, + "fullCode": "IBM2182IS" + } as ParametricPLICode, + + /** + * This applies to the PICSPEC built-in function, for example. + * (see page 129) + */ + IBM2183I: { + "code": "IBM2183I", + "severity": "S", + "message": "The first argument to ${BUILTIN name } built-in function must have constant length equal to that of the second argument.", + "fullCode": "IBM2183IS" + } as SimplePLICode, + + /** + * Break up the source files into smaller files. + * (see page 129) + */ + IBM2184I: { + "code": "IBM2184I", + "severity": "S", + "message": "Compiler input files must have less then 1000000 lines.", + "fullCode": "IBM2184IS" + } as SimplePLICode, + + /** + * This applies to the ISFINITE and similar built-in functions. + * (see page 130) + */ + IBM2185I: { + "code": "IBM2185I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built- in function must have type REAL DECIMAL FLOAT, and the DFP option must be in effect.`, + "fullCode": "IBM2185IS" + } as ParametricPLICode, + + /** + * The named built-in function is not supported for float using DFP. This message applies, + * for instance, to the SQRTF built-in functions + * (see page 130) + */ + IBM2186I: { + "code": "IBM2186I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} is not supported for DFP.`, + "fullCode": "IBM2186IS" + } as ParametricPLICode, + + /** + * A DFP literal value when adjusted to have no decimal point (e.g. 3.14E0 would be + * adjusted to 314E-2) must have an exponent no larger than the maximum for its precision. + * For precision <= 7, the maximum is 90. For 7 < precision <= 16, the maximum is 369. + * For 16 < precision, the maximum is 6111. + * (see page 130) + */ + IBM2187I: { + "code": "IBM2187I", + "severity": "S", + "message": (value: string, precision: string) => `The exponent in the literal ${value} is too large for DECIMAL FLOAT with precision ${precision} .`, + "fullCode": "IBM2187IS" + } as ParametricPLICode, + + /** + * A DFP literal value when adjusted to have no decimal point (e.g. 3.14E0 would be + * adjusted to 314E-2) must have an exponent no smaller than the minimum for its precision. + * For precision <= 7, the minimum is -95. For 7 < precision <= 16, the minimum is + * -383. For 16 < precision, the minimum is -6143. + * (see page 130) + */ + IBM2188I: { + "code": "IBM2188I", + "severity": "S", + "message": (value: string, precision: string) => `The exponent in the literal ${value} is too small for DECIMAL FLOAT with precision ${precision} .`, + "fullCode": "IBM2188IS" + } as ParametricPLICode, + + /** + * Under CMPAT(V2) and CMPAT(LE), bounds must be between -2147483648 and +2147483647 + * . + * (see page 130) + */ + IBM2189I: { + "code": "IBM2189I", + "severity": "S", + "message": "Under CMPAT(V2) and CMPAT(LE), bounds must not be greater than +2147483647.", + "fullCode": "IBM2189IS" + } as SimplePLICode, + + /** + * Under CMPAT(V2) and CMPAT(LE), bounds must be between -2147483648 and +2147483647 + * . + * (see page 130) + */ + IBM2190I: { + "code": "IBM2190I", + "severity": "S", + "message": "Under CMPAT(V2) and CMPAT(LE), bounds must not be less than -2147483648.", + "fullCode": "IBM2190IS" + } as SimplePLICode, + + /** + * You must specify at least one valid character in each of the OR, NOT and QUOTE or + * NAMES compiler options. + * (see page 130) + */ + IBM2191I: { + "code": "IBM2191I", + "severity": "S", + "message": (option: string) => `No valid character specified in the ${option} option.`, + "fullCode": "IBM2191IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE POINTER in the specified parameter position. See the Programming + * Guide for more details. + * (see page 130) + */ + IBM2192I: { + "code": "IBM2192I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string, parameternumber: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE POINTER as parameter number ${parameternumber} .`, + "fullCode": "IBM2192IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE NATIVE FIXED BIN(31) in the specified parameter position. See + * the Programming Guide for more details. + * (see page 130) + */ + IBM2193I: { + "code": "IBM2193I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string, parameternumber: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE NATIVE FIXED BIN(31) as parameter number ${parameternumber} .`, + "fullCode": "IBM2193IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYADDR POINTER in the specified parameter position. See the Programming + * Guide for more details. + * (see page 130) + */ + IBM2194I: { + "code": "IBM2194I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string, parameternumber: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYADDR POINTER as parameter number ${parameternumber} .`, + "fullCode": "IBM2194IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYADDR NATIVE FIXED BIN(31) in the specified parameter position. See + * the Programming Guide for more details. + * (see page 130) + */ + IBM2195I: { + "code": "IBM2195I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string, parameternumber: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYADDR NATIVE 130 FIXED BIN(31) as parameter number ${parameternumber} .`, + "fullCode": "IBM2195IS" + } as ParametricPLICode, + + /** + * The indicated element of the structure supplying the event handlers for the SAX parser + * must have a BYVALUE ALIGNED BIT(8) in the specified parameter position. See the + * Programming Guide for more details. + * (see page 131) + */ + IBM2196I: { + "code": "IBM2196I", + "severity": "S", + "message": (membernumber: string, BUILTINname: string, parameternumber: string) => `Member ${membernumber} in the event structure argument to the ${BUILTINname} built-in function must have a BYVALUE ALIGNED BIT(8) as parameter number ${parameternumber} .`, + "fullCode": "IBM2196IS" + } as ParametricPLICode, + + /** + * This applies to the ULENGTH built-in function, for example. + * (see page 131) + */ + IBM2197I: { + "code": "IBM2197I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to ${BUILTINname} built-in function must have type CHAR or WIDECHAR.`, + "fullCode": "IBM2197IS" + } as ParametricPLICode, + + /** + * This applies to the UPOS and UWIDTH built-in functions, for example. + * (see page 131) + */ + IBM2198I: { + "code": "IBM2198I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type CHAR or WIDECHAR.`, + "fullCode": "IBM2198IS" + } as ParametricPLICode, + + /** + * The compiler backend requires the XPLINK(ON) option to be in effect. + * (see page 131) + */ + IBM2199I: { + "code": "IBM2199I", + "severity": "S", + "message": "The run-time option XPLINK(ON) must be in effect if object code is to be generated.", + "fullCode": "IBM2199IS" + } as SimplePLICode, + + /** + * The indicated conversion had a DFP source, target, or both but failed at compile + * time with an operation exception. These conversions require that the machine on + * which the compilation occurs have DFP hardware installed. + * (see page 131) + */ + IBM2200I: { + "code": "IBM2200I", + "severity": "S", + "message": (sourcetype: string, targettype: string) => `DFP conversion from ${sourcetype} to ${targettype} failed with an operation exception. The most likely cause for this is lack of DFP hardware.`, + "fullCode": "IBM2200IS" + } as ParametricPLICode, + + /** + * This applies to the ROUNDDEC and similar built-in functions. + * (see page 131) + */ + IBM2201I: { + "code": "IBM2201I", + "severity": "S", + "message": (BUILTINname: string) => `First argument to ${BUILTINname} built-in function must have type REAL DECIMAL FIXED, or REAL DECIMAL FLOAT, and in the latter case, the DFP option must be in effect.`, + "fullCode": "IBM2201IS" + } as ParametricPLICode, + + /** + * This applies to various built-in functions on some platforms. For example, on z\/OS, + * MEMCU4* and MEMCU*4 require at least ARCH(7). + * (see page 131) + */ + IBM2202I: { + "code": "IBM2202I", + "severity": "S", + "message": (BUILTINname: string, level: string) => `Use of the ${BUILTINname} built-in function requires ARCH( ${level} ) or greater.`, + "fullCode": "IBM2202IS" + } as ParametricPLICode, + + /** + * If any leaf structure member has the VALUE attribute, then all must have the VALUE + * attribute. + * (see page 131) + */ + IBM2203I: { + "code": "IBM2203I", + "severity": "S", + "message": "The VALUE attribute may be used on a structure member only if it is used on all base members of that structure.", + "fullCode": "IBM2203IS" + } as SimplePLICode, + + /** + * It is invalid to specify the VALUE attribute for a member of a structure if the structure + * has a storage attribute such as BASED, CONTROLLED, etc. + * (see page 131) + */ + IBM2204I: { + "code": "IBM2204I", + "severity": "S", + "message": "The VALUE attribute may be used on a structure member only if no storage attribute is specified for the structure.", + "fullCode": "IBM2204IS" + } as SimplePLICode, + + /** + * It is invalid to specify the VALUE attribute for a member of a structure that has + * inherited dimensions. + * (see page 131) + */ + IBM2205I: { + "code": "IBM2205I", + "severity": "S", + "message": "The VALUE attribute may be used on a structure member only if no dimension attributes are specified for its parents.", + "fullCode": "IBM2205IS" + } as SimplePLICode, + + /** + * It is invalid to specify the VALUE attribute for an array. + * (see page 132) + */ + IBM2206I: { + "code": "IBM2206I", + "severity": "S", + "message": "The VALUE attribute conflicts with the DIMENSION attribute.", + "fullCode": "IBM2206IS" + } as SimplePLICode, + + /** + * It is invalid to specify the VALUE attribute for a member of a union. + * (see page 132) + */ + IBM2207I: { + "code": "IBM2207I", + "severity": "S", + "message": "The VALUE attribute may be used on a structure member only if no parent has the UNION attribute.", + "fullCode": "IBM2207IS" + } as SimplePLICode, + + /** + * Only the leaf elements of a structure containing elements with the VALUE attribute + * may be referenced, and only the individual elements of an array of VALUEs may be + * referenced. + * (see page 132) + */ + IBM2208I: { + "code": "IBM2208I", + "severity": "S", + "message": "Structure references that contain the VALUE attribute are invalid.", + "fullCode": "IBM2208IS" + } as SimplePLICode, + + /** + * Extents in BASED variables must all be constant except where the REFER option is + * used - unless the variable is a scalar. So, the first declare below is valid, while + * the second is invalid. + * ```pli + * dcl x based char(n); + * dcl y(n,m) based fixed bin(31); + * ``` + * (see page 132) + */ + IBM2209I: { + "code": "IBM2209I", + "severity": "S", + "message": "Use of nonconstant extents in BASED variables without REFER is invalid except on scalars.", + "fullCode": "IBM2209IS" + } as SimplePLICode, + + /** + * The VALUE type function can be applied only to those structure types that have at + * least one member with an INITIAL attribute. + * (see page 132) + */ + IBM2210I: { + "code": "IBM2210I", + "severity": "S", + "message": (typename: string) => `The VALUE type function cannot be applied to ${typename} since that structure has no members with an INITIAL attribute.`, + "fullCode": "IBM2210IS" + } as ParametricPLICode, + + /** + * Every DBCS shift-out code between the margins must have a matching DBCS shift-in + * code also between the margins. + * (see page 132) + */ + IBM2211I: { + "code": "IBM2211I", + "severity": "S", + "message": "Shift-out code has no closing shift- in code before the right margin.", + "fullCode": "IBM2211IS" + } as SimplePLICode, + + /** + * The argument to the named built-in subroutine must be a structure. + * (see page 132) + */ + IBM2212I: { + "code": "IBM2212I", + "severity": "S", + "message": (BUILTINname: string) => `Argument to the ${BUILTINname} built-in function must be a structure.`, + "fullCode": "IBM2212IS" + } as ParametricPLICode, + + /** + * Procedures and begin blocks must contain fewer than 2048 label arrays. + * (see page 132) + */ + IBM2213I: { + "code": "IBM2213I", + "severity": "S", + "message": "Block contains too many label arrays.", + "fullCode": "IBM2213IS" + } as SimplePLICode, + + /** + * The XMLATTR and XMLOMIT attributes may be used only on base structure elements. + * (see page 132) + */ + IBM2214I: { + "code": "IBM2214I", + "severity": "S", + "message": (Attribute: string) => `${Attribute} is invalid on structure parents.`, + "fullCode": "IBM2214IS" + } as ParametricPLICode, + + /** + * The XMLATTR and XMLOMIT attributes may be used only on named structure elements. + * (see page 132) + */ + IBM2215I: { + "code": "IBM2215I", + "severity": "S", + "message": (Attribute: string) => `${Attribute} is invalid on unnamed structure elements.`, + "fullCode": "IBM2215IS" + } as ParametricPLICode, + + /** + * The XMLATTR and XMLOMIT attributes may be used only on scalar structure elements + * . + * (see page 132) + */ + IBM2216I: { + "code": "IBM2216I", + "severity": "S", + "message": (Attribute: string) => `${Attribute} is invalid on arrays.`, + "fullCode": "IBM2216IS" + } as ParametricPLICode, + + /** + * The XMLATTR attribute may be used on a structure element only if all its previous + * sister elements at the same logical level also had the XMLATTR attribute. + * (see page 132) + */ + IBM2217I: { + "code": "IBM2217I", + "severity": "S", + "message": "XMLATTR is invalid if the previous element at that logical level does not also have the XMLATTR attribute.", + "fullCode": "IBM2217IS" + } as SimplePLICode, + + /** + * The XMLOMIT attribute may not be used on FLOAT elements using a data representation + * not supported by the hardware. + * (see page 132) + */ + IBM2218I: { + "code": "IBM2218I", + "severity": "S", + "message": (Attribute: string) => `${Attribute} is invalid on non-native FLOAT elements.`, + "fullCode": "IBM2218IS" + } as ParametricPLICode, + + /** + * If a parameter is declared as INONLY, then the ASSIGNABLE attribute is invalid on + * it and all of the elements it contains. + * (see page 133) + */ + IBM2219I: { + "code": "IBM2219I", + "severity": "S", + "message": "Parameters declared as INONLY must not contain any elements declared with the ASSIGNABLE attribute.", + "fullCode": "IBM2219IS" + } as SimplePLICode, + + /** + * If a parameter is declared as OUTONLY, then the NONASSIGNABLE attribute must not + * be specified on all of its elements. + * (see page 133) + */ + IBM2220I: { + "code": "IBM2220I", + "severity": "S", + "message": "Parameters declared as OUTONLY must contain at least one element declared with the ASSIGNABLE attribute.", + "fullCode": "IBM2220IS" + } as SimplePLICode, + + /** + * The use of a non-constant extent in BASED variable without using REFER is limited. + * In an array, its use requires that the array has only one dimension. + * (see page 133) + */ + IBM2221I: { + "code": "IBM2221I", + "severity": "S", + "message": "A non-constant array extent in a BASED variable is invalid if the array has more than one dimension.", + "fullCode": "IBM2221IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In an array, its use requires that the array has a constant lower bound. + * (see page 133) + */ + IBM2222I: { + "code": "IBM2222I", + "severity": "S", + "message": "A non-constant array extent in a BASED variable is invalid if the array has a non-constant lower bound.", + "fullCode": "IBM2222IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In an array that is part of a structure, its use requires that no other field in + * the structure have non-constant extents. + * (see page 133) + */ + IBM2223I: { + "code": "IBM2223I", + "severity": "S", + "message": "A non-constant array extent in a BASED structure is invalid if any other fields in the structure have non-constant extents.", + "fullCode": "IBM2223IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In an AREA, BIT, GRAPHIC or WIDECHAR extent, its use requires that the AREA or string + * is a scalar. + * (see page 133) + */ + IBM2224I: { + "code": "IBM2224I", + "severity": "S", + "message": "A non-constant AREA, BIT, GRAPHIC, or WIDECHAR extent in a BASED variable is invalid if the variable is an array element or part of a structure.", + "fullCode": "IBM2224IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In a CHARACTER extent, its use requires that the string be either UNALIGNED, NONVARYING + * or VARYINGZ. + * (see page 133) + */ + IBM2225I: { + "code": "IBM2225I", + "severity": "S", + "message": "A non-constant CHARACTER extent in a BASED variable is invalid if the string is ALIGNED and either VARYING or VARYING4.", + "fullCode": "IBM2225IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In an array, its use requires that the array and the array's parents have no sibling + * fields. + * (see page 133) + */ + IBM2226I: { + "code": "IBM2226I", + "severity": "S", + "message": "A non-constant array extent in a BASED variable is invalid if there are any sibling fields after the array or any of the array's parents.", + "fullCode": "IBM2226IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In a CHARACTER extent, its use requires that the string not be part of an array + * . + * (see page 133) + */ + IBM2227I: { + "code": "IBM2227I", + "severity": "S", + "message": "A non-constant CHARACTER extent in a BASED structure is invalid if the string is a member of an array of structures.", + "fullCode": "IBM2227IS" + } as SimplePLICode, + + /** + * The use of non-constant extents in BASED variables without using REFER is limited. + * In a CHARACTER extent, its use requires that the string be the last element in the + * structure and not part of a union. + * (see page 133) + */ + IBM2228I: { + "code": "IBM2228I", + "severity": "S", + "message": "A non-constant CHARACTER extent in a BASED structure is invalid unless the string is the last field in the structure and not part of a union.", + "fullCode": "IBM2228IS" + } as SimplePLICode, + + /** + * This applies, for example, to the POPCNT built-in function. + * (see page 134) + */ + IBM2230I: { + "code": "IBM2230I", + "severity": "S", + "message": (BUILTINname: string) => `The argument to the ${BUILTINname} built-in function must have the attributes REAL FIXED BIN and scale factor zero.`, + "fullCode": "IBM2230IS" + } as ParametricPLICode, + + /** + * The XMLCHAR built-in function cannot be used with DFT(EBCDIC) on Windows or AIX nor + * with DFT(ASCII) on the host. + * (see page 134) + */ + IBM2231I: { + "code": "IBM2231I", + "severity": "S", + "message": (BUILTINname: string) => `The ${BUILTINname} built-in function is supported only with the native character set.`, + "fullCode": "IBM2231IS" + } as ParametricPLICode, + + /** + * Multiple targets are not permitted in BY DIMACROSS assignments. For example, the + * following is invalid. + * ```pli + * dcl 1 a, 2 a1 fixed bin, 2 a2 fixed bin; + * dcl 1 b like a; + * dcl 1 c(100) dimacross like a; + * a,b = c, by dimacross(jx); + * ``` + * (see page 134) + */ + IBM2232I: { + "code": "IBM2232I", + "severity": "S", + "message": "There must be only one target in a BY DIMACROSS assignment.", + "fullCode": "IBM2232IS" + } as SimplePLICode, + + /** + * The target in a BY DIMACROSS assignment must not be an array of structures or a scalar. + * For example, the following is invalid. + * ```pli + * dcl 1 a(100), 2 a1 fixed bin, 2 a2 fixed + * bin; + * dcl 1 b(100) dimacross, 2 b1 fixed bin, 2 + * b2 fixed bin; + * a = b, by dimacross(1); + * ``` + * (see page 134) + */ + IBM2233I: { + "code": "IBM2233I", + "severity": "S", + "message": "The target in a BY DIMACROSS assignment must be a structure reference.", + "fullCode": "IBM2233IS" + } as SimplePLICode, + + /** + * The source in a BY DIMACROSS assignment must not include any array references. + * (see page 134) + */ + IBM2234I: { + "code": "IBM2234I", + "severity": "S", + "message": "No arrays are permitted in the source in a BY DIMACROSS assignment.", + "fullCode": "IBM2234IS" + } as SimplePLICode, + + /** + * The immediate children of a structure used in a BY DIMACROSS assignment must be scalars + * or substructures, but not arrays unless the structure was declared with the DIMACROSS + * attribute. For example, the following is invalid. + * ```pli + * dcl 1 a, 2 a1(100) fixed bin, 2 a2(100) + * fixed bin; + * dcl 1 b(100) dimacross, 2 b1 fixed bin, 2 + * b2 fixed bin; + * a = b, by dimacross(1); + * ``` + * (see page 134) + */ + IBM2235I: { + "code": "IBM2235I", + "severity": "S", + "message": "In a BY DIMACROSS assignment, the immediate children of any structure not declared with DIMACROSS must not be arrays.", + "fullCode": "IBM2235IS" + } as SimplePLICode, + + /** + * The named built-in function is valid only when applied to a reference to a variable + * declared with the DIMACROSS attribute. + * (see page 134) + */ + IBM2236I: { + "code": "IBM2236I", + "severity": "S", + "message": (BUILTINname: string) => `${BUILTINname} argument must have the DIMACROSS attribute.`, + "fullCode": "IBM2236IS" + } as ParametricPLICode, + + /** + * The third argument to the ALLCOMPARE built-in function must be a restricted expression + * with the attributes CHAR(2) NONVARYING. + * (see page 134) + */ + IBM2237I: { + "code": "IBM2237I", + "severity": "S", + "message": "The third argument to the ALLCOMPARE built-in function must be a CHAR(2) constant.", + "fullCode": "IBM2237IS" + } as SimplePLICode, + + /** + * When uppercased, the third argument to the ALLCOMPARE built-in function must be one + * of 'EQ', 'LT', 'LE', 'GE', 'GT', or 'NE'. + * (see page 134) + */ + IBM2238I: { + "code": "IBM2238I", + "severity": "S", + "message": "The third argument to the ALLCOMPARE built-in function must specify the name of a comparison operator.", + "fullCode": "IBM2238IS" + } as SimplePLICode, + + /** + * If a DEFINE STRUCT statement specifies no member names, then any attempt to dereference + * the type is invalid. + * (see page 135) + */ + IBM2239I: { + "code": "IBM2239I", + "severity": "S", + "message": (typename: string) => `Invalid use of unspecified STRUCT type ${typename} .`, + "fullCode": "IBM2239IS" + } as ParametricPLICode, + + /** + * The size of an unspecified structure is unknown, and hence all arithmetic operations + * on handles for it are ill-defined. + * (see page 135) + */ + IBM2240I: { + "code": "IBM2240I", + "severity": "S", + "message": "Arithmetic operations are not allowed on handles for unspecified structure definitions.", + "fullCode": "IBM2240IS" + } as SimplePLICode, + + /** + * The argument to the named type function must be the name of a structure type that + * was fully specified. + * (see page 135) + */ + IBM2241I: { + "code": "IBM2241I", + "severity": "S", + "message": (typefunction: string) => `The argument to the type function ${typefunction} must be a specified structure type name.`, + "fullCode": "IBM2241IS" + } as ParametricPLICode, + + /** + * If h1 is a handle for structure type t1 and h2 is a handle for structure type t2, + * the h1-h2 is invalid unless t1 and t2 are the same. + * (see page 135) + */ + IBM2242I: { + "code": "IBM2242I", + "severity": "S", + "message": "Subtraction of HANDLE from HANDLE is invalid unless both point to the same type.", + "fullCode": "IBM2242IS" + } as SimplePLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 135) + */ + IBM2243I: { + "code": "IBM2243I", + "severity": "S", + "message": (variablename: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. RETURNS attributes do not match.`, + "fullCode": "IBM2243IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 135) + */ + IBM2244I: { + "code": "IBM2244I", + "severity": "S", + "message": (variablename: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. BYVALUE/BYADDR attributes in RETURNS do not match.`, + "fullCode": "IBM2244IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 135) + */ + IBM2245I: { + "code": "IBM2245I", + "severity": "S", + "message": (variablename: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. LINKAGE values do not match.`, + "fullCode": "IBM2245IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 135) + */ + IBM2246I: { + "code": "IBM2246I", + "severity": "S", + "message": (variablename: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. OPTIONS values do not match.`, + "fullCode": "IBM2246IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 135) + */ + IBM2247I: { + "code": "IBM2247I", + "severity": "S", + "message": (variablename: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Parameter counts do not match.`, + "fullCode": "IBM2247IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 135) + */ + IBM2248I: { + "code": "IBM2248I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. BYVALUE/BYADDR attributes in parameter ${parameternumber} do not match.`, + "fullCode": "IBM2248IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 136) + */ + IBM2249I: { + "code": "IBM2249I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Number of dimensions for parameter ${parameternumber} do not match.`, + "fullCode": "IBM2249IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 136) + */ + IBM2250I: { + "code": "IBM2250I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Lower bounds for parameter ${parameternumber} do not match.`, + "fullCode": "IBM2250IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 136) + */ + IBM2251I: { + "code": "IBM2251I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Upper bounds for parameter ${parameternumber} do not match.`, + "fullCode": "IBM2251IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 136) + */ + IBM2252I: { + "code": "IBM2252I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Alignment of parameter ${parameternumber} does not match.`, + "fullCode": "IBM2252IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 136) + */ + IBM2253I: { + "code": "IBM2253I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Number and attributes of structure members in parameter ${parameternumber} do not match.`, + "fullCode": "IBM2253IS" + } as ParametricPLICode, + + /** + * A label on a PROCEDURE statement constitutes a declaration for an ENTRY constant + * with that name. That name also appears in a DECLARE statement, but the attributes + * in those two declarations do not match. + * (see page 136) + */ + IBM2254I: { + "code": "IBM2254I", + "severity": "S", + "message": (variablename: string, parameternumber: string) => `The attributes derived from the PROCEDURE statement for the ENTRY constant ${variablename} do not match those in its explicit declaration. Attributes of parameter ${parameternumber} do not match.`, + "fullCode": "IBM2254IS" + } as ParametricPLICode, + + /** + * This message applies to the UTF8 built-in function. GRAPHIC and non-computational + * arguments are not allowed. + * (see page 136) + */ + IBM2255I: { + "code": "IBM2255I", + "severity": "S", + "message": (BUILTINname: string) => `The argument to the ${BUILTINname} built-in function must be numeric, BIT, or CHARACTER.`, + "fullCode": "IBM2255IS" + } as ParametricPLICode, + + /** + * Conversion of CHAR or WCHAR to UTF-8 can produce a result string that is longer than + * the source string because some CHAR(1) and WCHAR(1) values can produce CHAR(2) or + * CHAR(3) strings when converted 136 to UTF-8. If there are too many of these values + * in the source string then the target string would have a length greater than the + * the maximum allowed for a CHARACTER string. + * (see page 136) + */ + IBM2256I: { + "code": "IBM2256I", + "severity": "S", + "message": "The result of the ${BUILTIN name } built-in function would have a length greater than the the maximum allowed for a CHARACTER string.", + "fullCode": "IBM2256IS" + } as SimplePLICode, + + /** + * This message applies to the UTF8 built-in function. + * (see page 137) + */ + IBM2257I: { + "code": "IBM2257I", + "severity": "S", + "message": (BUILTINname: string) => `The argument to the ${BUILTINname} built-in function must hold valid UTF-16.`, + "fullCode": "IBM2257IS" + } as ParametricPLICode, + + /** + * This message applies to the UTF8TOCHAR and UTF8TOWCHAR built-in functions. + * (see page 137) + */ + IBM2258I: { + "code": "IBM2258I", + "severity": "S", + "message": (BUILTINname: string) => `The argument to the ${BUILTINname} built-in function must have type CHARACTER.`, + "fullCode": "IBM2258IS" + } as ParametricPLICode, + + /** + * This message applies to the UTF8TOCHAR and UTF8TOWCHAR built-in functions. + * (see page 137) + */ + IBM2259I: { + "code": "IBM2259I", + "severity": "S", + "message": (BUILTINname: string) => `The argument to the ${BUILTINname} built-in function must contain valid UTF-8.`, + "fullCode": "IBM2259IS" + } as ParametricPLICode, + + /** + * These expressions must be simple restricted expressions. For example, ENTRY, FILE + * and LABEL constants must not be used in these INITIAL expressions + * (see page 137) + */ + IBM2260I: { + "code": "IBM2260I", + "severity": "S", + "message": "INITIAL expressions in DEFINE STRUCT must not depend on any address values.", + "fullCode": "IBM2260IS" + } as SimplePLICode, + + /** + * These characters are allowed in PICTURE specifications, but not in WIDEPIC. + * (see page 137) + */ + IBM2261I: { + "code": "IBM2261I", + "severity": "S", + "message": "Overpunch and currency characters are not allowed in WIDEPIC specifications.", + "fullCode": "IBM2261IS" + } as SimplePLICode, + + /** + * These characters are allowed in PICTURE specifications, but not in WIDEPIC. + * (see page 137) + */ + IBM2262I: { + "code": "IBM2262I", + "severity": "S", + "message": "A and X characters are not allowed in WIDEPIC specifications.", + "fullCode": "IBM2262IS" + } as SimplePLICode, + + /** + * REFER objects should have the REAL attribute. + * (see page 137) + */ + IBM2263I: { + "code": "IBM2263I", + "severity": "S", + "message": "REFER objects must not be COMPLEX WIDEPIC.", + "fullCode": "IBM2263IS" + } as SimplePLICode, + + /** + * The LOCATES descriptor may not specify a structure, union or array. The following + * code example is invalid: + * ```pli + * dcl b offset(a) locates( 1 union, 2 ptr, 2 + * ptr ); + * ``` + * (see page 137) + */ + IBM2264I: { + "code": "IBM2264I", + "severity": "S", + "message": (attribute: string) => `The ${attribute} attribute is invalid in a LOCATES descriptor.`, + "fullCode": "IBM2264IS" + } as ParametricPLICode, + + /** + * In LOCATES descriptors, any string length and AREA size must be specified with a + * restricted expression that has computational type. + * (see page 137) + */ + IBM2265I: { + "code": "IBM2265I", + "severity": "S", + "message": "Extents in LOCATES descriptors must be constants.", + "fullCode": "IBM2265IS" + } as SimplePLICode, + + /** + * This rule applies to the LOCVAL and similar built-in functions. + * (see page 137) + */ + IBM2266I: { + "code": "IBM2266I", + "severity": "S", + "message": (BUILTINname: string) => `The argument to ${BUILTINname} built-in function must have the LOCATES attribute.`, + "fullCode": "IBM2266IS" + } as ParametricPLICode, + + /** + * This rule applies to the LOCNEWSPACE and similar built-in functions. + * (see page 137) + */ + IBM2267I: { + "code": "IBM2267I", + "severity": "S", + "message": "The first argument to ${BUILTIN name } built-in function must have the LOCATES attribute.", + "fullCode": "IBM2267IS" + } as SimplePLICode, + + /** + * The LOCVAL pseudovariable can be applied only to variables with the LOCATES attribute + * . + * (see page 137) + */ + IBM2268I: { + "code": "IBM2268I", + "severity": "S", + "message": "Argument to the LOCVAL pseudovariable must have the LOCATES attribute.", + "fullCode": "IBM2268IS" + } as SimplePLICode, + + /** + * The LOCATES attribute cannot be used on any other types. + * (see page 137) + */ + IBM2269I: { + "code": "IBM2269I", + "severity": "S", + "message": "LOCATES attribute is valid only with OFFSET.", + "fullCode": "IBM2269IS" + } as SimplePLICode +};