@abaplint/core 2.105.2 → 2.105.3

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.
@@ -295,6 +295,9 @@ class TypeUtils {
295
295
  }
296
296
  return true;
297
297
  }
298
+ else if (target instanceof basic_1.CLikeType) {
299
+ return this.isCharLikeStrict(source);
300
+ }
298
301
  else if (target instanceof basic_1.VoidType || target instanceof basic_1.AnyType) {
299
302
  return true;
300
303
  }
@@ -65,7 +65,7 @@ class Registry {
65
65
  }
66
66
  static abaplintVersion() {
67
67
  // magic, see build script "version.sh"
68
- return "2.105.2";
68
+ return "2.105.3";
69
69
  }
70
70
  getDDICReferences() {
71
71
  return this.ddicReferences;
@@ -51,7 +51,9 @@ STATICS: use CLASS-DATA instead
51
51
 
52
52
  DESCRIBE TABLE LINES: use lines() instead (quickfix exists)
53
53
 
54
- TEST-SEAMS: https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#use-test-seams-as-temporary-workaround`,
54
+ TEST-SEAMS: https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#use-test-seams-as-temporary-workaround
55
+
56
+ BREAK points`,
55
57
  tags: [_irule_1.RuleTag.Styleguide, _irule_1.RuleTag.SingleFile],
56
58
  };
57
59
  }
@@ -11,17 +11,17 @@ class NoPrefixesConf extends _basic_rule_config_1.BasicRuleConfig {
11
11
  constructor() {
12
12
  super(...arguments);
13
13
  /** DATA, CLASS-DATA, DATA BEGIN OF, CLASS-DATA BEGIN OF, FINAL(), DATA(), case insensitive regex */
14
- this.data = "^[lg]._";
14
+ this.data = "^[lg].?_";
15
15
  /** STATICS, STATICS BEGIN OF, case insensitive regex */
16
16
  this.statics = "";
17
17
  /** FIELD-SYMBOLS and inline FIELD-SYMBOLS(), case insensitive regex */
18
- this.fieldSymbols = "^<l._";
18
+ this.fieldSymbols = "^<l.?_";
19
19
  /** CONSTANTS, CONSTANTS BEGIN OF, case insensitive regex */
20
20
  this.constants = "^[lg]c_";
21
21
  /** TYPES, ENUM, MESH, case insensitive regex */
22
22
  this.types = "^ty_";
23
23
  /** importing, exporting, returning and changing parameters, case insensitive regex */
24
- this.methodParameters = "^[ierc]._";
24
+ this.methodParameters = "^[ierc].?_";
25
25
  // todo, public localClass: string = "";
26
26
  // todo, public localInterface: string = "";
27
27
  // todo, public functionModuleParameters: string = "";
@@ -43,6 +43,9 @@ class NoPrefixes extends _abap_rule_1.ABAPRule {
43
43
  title: "No Prefixes",
44
44
  shortDescription: `Dont use hungarian notation`,
45
45
  extendedInformation: `
46
+ Note: not prefixing TYPES will require changing the errorNamespace in the abaplint configuration,
47
+ allowing all types to become voided, abaplint will then provide less precise syntax errors.
48
+
46
49
  https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#avoid-encodings-esp-hungarian-notation-and-prefixes
47
50
 
48
51
  https://github.com/SAP/styleguides/blob/main/clean-abap/sub-sections/AvoidEncodings.md`,
@@ -6,6 +6,7 @@ const _abap_rule_1 = require("./_abap_rule");
6
6
  const _irule_1 = require("./_irule");
7
7
  const Statements = require("../abap/2_statements/statements");
8
8
  const issue_1 = require("../issue");
9
+ const _statement_1 = require("../abap/2_statements/statements/_statement");
9
10
  class ReduceProceduralCodeConf extends _basic_rule_config_1.BasicRuleConfig {
10
11
  constructor() {
11
12
  super(...arguments);
@@ -25,7 +26,9 @@ class ReduceProceduralCode extends _abap_rule_1.ABAPRule {
25
26
  shortDescription: `Checks FORM and FUNCTION-MODULE have few statements`,
26
27
  extendedInformation: `Delegate logic to a class method instead of using FORM or FUNCTION-MODULE.
27
28
 
28
- https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#prefer-object-orientation-to-procedural-programming`,
29
+ https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#prefer-object-orientation-to-procedural-programming
30
+
31
+ Comments are not counted as statements.`,
29
32
  tags: [_irule_1.RuleTag.SingleFile, _irule_1.RuleTag.Styleguide],
30
33
  badExample: `FORM foo.
31
34
  DATA lv_bar TYPE i.
@@ -71,6 +74,9 @@ ENDFORM.`,
71
74
  }
72
75
  doCount = undefined;
73
76
  }
77
+ else if (statement.get() instanceof _statement_1.Comment) {
78
+ continue;
79
+ }
74
80
  else if (doCount !== undefined) {
75
81
  count = count + 1;
76
82
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abaplint/core",
3
- "version": "2.105.2",
3
+ "version": "2.105.3",
4
4
  "description": "abaplint - Core API",
5
5
  "main": "build/src/index.js",
6
6
  "typings": "build/abaplint.d.ts",