@abaplint/cli 2.118.8 → 2.118.9
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.
- package/build/cli.js +13 -4
- package/package.json +2 -2
package/build/cli.js
CHANGED
|
@@ -31834,7 +31834,7 @@ class CreateObject {
|
|
|
31834
31834
|
this.validateParameters(cdef, node, input);
|
|
31835
31835
|
}
|
|
31836
31836
|
static checkInstantiationAllowed(cdef, input) {
|
|
31837
|
-
var _a, _b;
|
|
31837
|
+
var _a, _b, _c, _d;
|
|
31838
31838
|
const createVis = cdef.getCreateVisibility();
|
|
31839
31839
|
if (createVis === visibility_1.Visibility.Public) {
|
|
31840
31840
|
return undefined;
|
|
@@ -31851,14 +31851,23 @@ class CreateObject {
|
|
|
31851
31851
|
input.scope.isLocalFriend(cdef.getName(), enclosingClass)) {
|
|
31852
31852
|
return undefined;
|
|
31853
31853
|
}
|
|
31854
|
+
// subclasses of friends also have friendship
|
|
31855
|
+
let enclosingSup = (_a = input.scope.findClassDefinition(enclosingClass)) === null || _a === void 0 ? void 0 : _a.getSuperClass();
|
|
31856
|
+
while (enclosingSup !== undefined) {
|
|
31857
|
+
if (cdef.getFriends().some(f => f.toUpperCase() === enclosingSup.toUpperCase()) ||
|
|
31858
|
+
input.scope.isLocalFriend(cdef.getName(), enclosingSup)) {
|
|
31859
|
+
return undefined;
|
|
31860
|
+
}
|
|
31861
|
+
enclosingSup = (_b = input.scope.findClassDefinition(enclosingSup)) === null || _b === void 0 ? void 0 : _b.getSuperClass();
|
|
31862
|
+
}
|
|
31854
31863
|
if (createVis === visibility_1.Visibility.Protected) {
|
|
31855
31864
|
// subclasses are also allowed
|
|
31856
|
-
let sup = (
|
|
31865
|
+
let sup = (_c = input.scope.findClassDefinition(enclosingClass)) === null || _c === void 0 ? void 0 : _c.getSuperClass();
|
|
31857
31866
|
while (sup !== undefined) {
|
|
31858
31867
|
if (sup.toUpperCase() === cdef.getName().toUpperCase()) {
|
|
31859
31868
|
return undefined;
|
|
31860
31869
|
}
|
|
31861
|
-
sup = (
|
|
31870
|
+
sup = (_d = input.scope.findClassDefinition(sup)) === null || _d === void 0 ? void 0 : _d.getSuperClass();
|
|
31862
31871
|
}
|
|
31863
31872
|
}
|
|
31864
31873
|
return cdef.getName() + " cannot be instantiated, class is defined as " +
|
|
@@ -56039,7 +56048,7 @@ class Registry {
|
|
|
56039
56048
|
}
|
|
56040
56049
|
static abaplintVersion() {
|
|
56041
56050
|
// magic, see build script "version.sh"
|
|
56042
|
-
return "2.118.
|
|
56051
|
+
return "2.118.9";
|
|
56043
56052
|
}
|
|
56044
56053
|
getDDICReferences() {
|
|
56045
56054
|
return this.ddicReferences;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/cli",
|
|
3
|
-
"version": "2.118.
|
|
3
|
+
"version": "2.118.9",
|
|
4
4
|
"description": "abaplint - Command Line Interface",
|
|
5
5
|
"funding": "https://github.com/sponsors/larshp",
|
|
6
6
|
"bin": {
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
},
|
|
39
39
|
"homepage": "https://abaplint.org",
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@abaplint/core": "^2.118.
|
|
41
|
+
"@abaplint/core": "^2.118.9",
|
|
42
42
|
"@types/chai": "^4.3.20",
|
|
43
43
|
"@types/minimist": "^1.2.5",
|
|
44
44
|
"@types/mocha": "^10.0.10",
|