@abaplint/core 2.83.20 → 2.83.21
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/src/registry.js
CHANGED
|
@@ -47,10 +47,10 @@ class DefinitionsTop extends _abap_rule_1.ABAPRule {
|
|
|
47
47
|
if (structure === undefined) {
|
|
48
48
|
return [];
|
|
49
49
|
}
|
|
50
|
-
// one fix per file
|
|
51
|
-
this.fixed = false;
|
|
52
50
|
const routines = structure.findAllStructures(Structures.Form).concat(structure.findAllStructures(Structures.Method));
|
|
53
51
|
for (const r of routines) {
|
|
52
|
+
// one fix per routine
|
|
53
|
+
this.fixed = false;
|
|
54
54
|
this.mode = DEFINITION;
|
|
55
55
|
this.moveTo = r.getFirstStatement();
|
|
56
56
|
const found = this.walk(r, file);
|
|
@@ -89,7 +89,7 @@ class DefinitionsTop extends _abap_rule_1.ABAPRule {
|
|
|
89
89
|
|| c.get() instanceof Statements.Static
|
|
90
90
|
|| c.get() instanceof Statements.FieldSymbol)) {
|
|
91
91
|
if (this.mode === AFTER) {
|
|
92
|
-
// only one fix per
|
|
92
|
+
// only one fix per routine, as it reorders a lot
|
|
93
93
|
let fix = undefined;
|
|
94
94
|
if (this.fixed === false && this.moveTo) {
|
|
95
95
|
fix = this.buildFix(file, c, this.moveTo);
|