Redmine#1735: classesmatching() function