Skip to content

Commit 3f0103f

Browse files
committed
fixed WhitespacePolicy compile error
1 parent 741af90 commit 3f0103f

File tree

7 files changed

+10
-24
lines changed

7 files changed

+10
-24
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## dev branch / next version (1.x.x)
44

5+
## version 1.17.1 (2024-10-22)
6+
7+
- Fixed WhitespacePolicy compilation error
8+
59
## version 1.17.0 (2024-10-06)
610

711
- **Breaking Change** replaced `whitespace.openingBracketPolicy` and `whitespace.closingBracketPolicy` settings with `whitespace.bracketConfig`, fixes [#592](https://github.com/HaxeCheckstyle/haxe-formatter/issues/592)

haxelib.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
"style"
99
],
1010
"description": "A code formatter for Haxe",
11-
"version": "1.17.0",
12-
"releasenote": "Added more wrapping conditions; fixed various issues affecting a whole bunch of special cases - see CHANGELOG for details.",
11+
"version": "1.17.1",
12+
"releasenote": "Fixed WhitespacePolicy error - see CHANGELOG for details.",
1313
"contributors": [
1414
"AlexHaxe",
1515
"Gama11"

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@haxecheckstyle/haxe-formatter",
3-
"version": "1.17.0",
3+
"version": "1.17.1",
44
"description": "A code formatter for Haxe",
55
"repository": {
66
"type": "git",

resources/default-hxformat.json

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -921,20 +921,6 @@
921921
}
922922
]
923923
},
924-
"opAssignWrap": {
925-
"defaultWrap": "noWrap",
926-
"rules": [
927-
{
928-
"conditions": [
929-
{
930-
"cond": "exceedsMaxLineLength",
931-
"value": 1
932-
}
933-
],
934-
"type": "fillLineWithLeadingBreak"
935-
}
936-
]
937-
},
938924
"opBoolChain": {
939925
"defaultWrap": "noWrap",
940926
"rules": [

resources/hxformat-schema.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1283,10 +1283,6 @@
12831283
"description": "call parameter wrapping rules",
12841284
"$ref": "#/definitions/formatter.config.WrapRules"
12851285
},
1286-
"opAssignWrap": {
1287-
"description": "chain wrapping rules for case patterns",
1288-
"$ref": "#/definitions/formatter.config.WrapRules"
1289-
},
12901286
"arrayMatrixWrap": {
12911287
"description": "detect arrays in matrix configuration from source noMatrixWrap = no detection matrixWrapNoAlign = detect and format as matrix without alignment matrixWrapWithAlign = detect and format as matrix and align columns",
12921288
"$ref": "#/definitions/formatter.config.ArrayMatrixWrap",

src/formatter/config/WhitespacePolicy.hx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ enum abstract WhitespacePolicy(String) {
1111
var Around = "around";
1212

1313
public static function has(policy:WhitespacePolicy, wantPolicy:WhitespacePolicy):Bool {
14-
return (policy.remove(wantPolicy) != policy);
14+
return (remove(policy, wantPolicy) != policy);
1515
}
1616

1717
public static function remove(policy:WhitespacePolicy, removePolicy:WhitespacePolicy):WhitespacePolicy {

0 commit comments

Comments
 (0)