@abaplint/transpiler-cli 2.11.37 → 2.11.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/build/bundle.js +11 -6
  2. package/package.json +2 -2
package/build/bundle.js CHANGED
@@ -79195,9 +79195,14 @@ class FieldChainTranspiler {
79195
79195
  let name = c.getFirstToken().getStr().toLowerCase();
79196
79196
  if (context instanceof abaplint.BasicTypes.ObjectReferenceType) {
79197
79197
  const cdef = traversal.findClassDefinition(context.getIdentifierName(), scope);
79198
- const attr = cdef?.getAttributes().findByName(c.getFirstToken().getStr());
79198
+ const tokenName = c.getFirstToken().getStr();
79199
+ const attr = cdef?.getAttributes().findByName(tokenName);
79200
+ // Do not mark constants as private JS fields. Constants are exposed on instances via constructor copying.
79201
+ const constants = cdef?.getAttributes().getConstants() || [];
79202
+ const isConstant = constants.some(cons => cons.getName().toUpperCase() === tokenName.toUpperCase());
79199
79203
  if (feature_flags_1.FEATURE_FLAGS.PRIVATE_ATTRIBUTES === true
79200
- && attr?.getVisibility() === abaplint.Visibility.Private) {
79204
+ && attr?.getVisibility() === abaplint.Visibility.Private
79205
+ && isConstant === false) {
79201
79206
  const id = scope?.getParent()?.getParent()?.getIdentifier();
79202
79207
  if (id?.stype === abaplint.ScopeType.ClassImplementation
79203
79208
  && cdef?.getName().toUpperCase() === id.sname.toUpperCase()) {
@@ -87833,10 +87838,6 @@ class SelectTranspiler {
87833
87838
  if (from) {
87834
87839
  select += new sql_from_1.SQLFromTranspiler().transpile(from, traversal).getCode();
87835
87840
  }
87836
- const groupBy = node.findFirstExpression(abaplint.Expressions.SQLGroupBy);
87837
- if (groupBy) {
87838
- select += new sql_group_by_1.SQLGroupByTranspiler().transpile(groupBy, traversal).getCode();
87839
- }
87840
87841
  const { table, keys } = this.findTable(node, traversal);
87841
87842
  let where = undefined;
87842
87843
  for (const sqlCond of node.findAllExpressions(abaplint.Expressions.SQLCond)) {
@@ -87847,6 +87848,10 @@ class SelectTranspiler {
87847
87848
  if (where) {
87848
87849
  select += "WHERE " + new expressions_1.SQLCondTranspiler().transpile(where, traversal, table).getCode() + " ";
87849
87850
  }
87851
+ const groupBy = node.findFirstExpression(abaplint.Expressions.SQLGroupBy);
87852
+ if (groupBy) {
87853
+ select += new sql_group_by_1.SQLGroupByTranspiler().transpile(groupBy, traversal).getCode() + " ";
87854
+ }
87850
87855
  const upTo = node.findFirstExpression(abaplint.Expressions.SQLUpTo);
87851
87856
  if (upTo) {
87852
87857
  const s = upTo.findFirstExpression(abaplint.Expressions.SimpleSource3);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/transpiler-cli",
3
- "version": "2.11.37",
3
+ "version": "2.11.39",
4
4
  "description": "Transpiler - Command Line Interface",
5
5
  "funding": "https://github.com/sponsors/larshp",
6
6
  "bin": {
@@ -28,7 +28,7 @@
28
28
  "license": "MIT",
29
29
  "devDependencies": {
30
30
  "@abaplint/core": "^2.113.180",
31
- "@abaplint/transpiler": "^2.11.37",
31
+ "@abaplint/transpiler": "^2.11.39",
32
32
  "@types/glob": "^8.1.0",
33
33
  "@types/node": "^24.3.0",
34
34
  "@types/progress": "^2.0.7",