cs + small refactoring

allows in future to have full regular expressions as marks