boolean (PsiSwitchLabelStatementBase[] labels) { return labels != null && Arrays.stream(labels).map(t -> t.getCaseLabelElementList()) .flatMap(t -> t != null ? Arrays.stream(t.getElements()) : Stream.empty()).anyMatch(e -> e instanceof PsiPattern); }