Slava Potsepnia (ViacheslavPotsepnia / scnsoft.com) wrote:
>  Hi All!
>  
>  I would like to know if it's possible to negate regexps in
>  case-when-then-else-end. I.g.

You can often use the negative lookahead operator to simulate that
effect, as in:

  case line
  when /^(?!regex)/ then # expression does not occur at start of line
    ...
  when /\A(?!.*regex)/ then # expression does not occur anywhere
    ...
  end

[...]

			Reimer Behrends