Skip to content

Commit 5654786

Browse files
committed
[en] fix \b regex for JDK>=19
1 parent b474be4 commit 5654786

File tree

1 file changed

+1
-1
lines changed
  • languagetool-language-modules/en/src/main/resources/org/languagetool/rules/en

1 file changed

+1
-1
lines changed

languagetool-language-modules/en/src/main/resources/org/languagetool/rules/en/grammar.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113239,7 +113239,7 @@ The accident victim died from her injuries.
113239113239
</rule>
113240113240
<rulegroup id="UNIT_SPACE" name="Missing space between numeric value and unit (e.g., 25 km)" type="typographical" tags="picky">
113241113241
<rule>
113242-
<regexp case_sensitive='yes'>(?&lt;![A-Z\$€£¥฿฿=]-?[0-9\.]{0,5})((\b|\-)[0-9]{1,5}[0-9,.]{0,5}(€|¥|฿|฿|°C|°F|°De?|°R[éeøa]?|(Z|E|P|T|G|M|k|h|da|d|c|m|µ|n|f|z|y)[ΩΩm]|[ΩΩ]|(Z|E|P|T|G|M|k|h|da|d|c|m|µ|n|p|f|a|z|y)?N|[kKMGTPEZY]i?B|[kmµnp]g|[Mk]t|kWh|GWa|MWd|MWh)(?!\w))</regexp>
113242+
<regexp case_sensitive='yes'>(?U)(?&lt;![A-Z\$€£¥฿฿=]-?[0-9\.]{0,5})((\b|\-)[0-9]{1,5}[0-9,.]{0,5}(€|¥|฿|฿|°C|°F|°De?|°R[éeøa]?|(Z|E|P|T|G|M|k|h|da|d|c|m|µ|n|f|z|y)[ΩΩm]|[ΩΩ]|(Z|E|P|T|G|M|k|h|da|d|c|m|µ|n|p|f|a|z|y)?N|[kKMGTPEZY]i?B|[kmµnp]g|[Mk]t|kWh|GWa|MWd|MWh)(?!\w))</regexp>
113243113243
<message>Insert a space between the numerical value and the unit symbol.</message>
113244113244
<suggestion><match no="1" regexp_match="((\-)?[0-9]+[0-9,.]*{1,30})" regexp_replace="$1&nbsp;"/></suggestion>
113245113245
<example correction="25&nbsp;°C">The temperature is <marker>25°C</marker>.</example>

0 commit comments

Comments
 (0)