private static boolean isAnyDigit(RegExpClassElement classElement) {
    if (classElement instanceof RegExpSimpleClass) {
      return ((RegExpSimpleClass)classElement).getKind().equals(DIGIT);
    }
    if (classElement instanceof RegExpPosixBracketExpression) {
      String className = ((RegExpPosixBracketExpression)classElement).getClassName();
      return className != null && className.equals("digit");
    }
    return false;
  }
private static boolean isAnyDigit(RegExpClassElement classElement)