#1 Case-sensitive exceptions

open
nobody
None
5
2005-10-03
2005-10-03
No

If a rule is defined as being case-sensitive then it
makes sense that any expections that are part of the
rule are also treated as case-sensitive.

For example

<rule match="\b([Nn])orth ([Aa])merica(ns?)?\b"
suggestion="North America$1"
case-sensitive="true">
<except if="$1$2" matches="NA"/>
<description>Countries/continents need capital
letters.</description>
<test in="two north americans in North america
and another north American in North America"
out="two North Americans in North America
and another North American in North America"/>
</rule>

fails at the moment because the test for the exception
NA (i.e. so the rule doesn't fire if North America is
already capitalised) is always true if the test is not
case-sensitive.

Discussion


Log in to post a comment.