FancyRegex

An example of backtracking regex usage.

Source

extends: existence
message: "Avoid saying '%s' when not followed by 'box'."
level: error
tokens:
  - 'dialog (?!box)'

Example

Click "OK" to close the dialog box. Click "OK" to close the dialog window.