Fix bug in counting slashes in a regexp.

Fixes #391.
Merge pull request #396 from jonas054/fix_regexp_literal

Fix bug in counting slashes in a regexp.