$constraint =~ m@ ^\s* # skip all whitespace at beginning ( /.+/ # capture the custom regex |m(.).+\2 # does this capture the ops? What does the |m do? why is the (.) and \2 in there? ) [cgimosx]* # ?? don't understand what this is for. what are we trying to match? I thought the ops were matched above \s*$ # skip all whitespace at end @x