boolean (PsiDeclarationStatement declarationStatement, PsiVariable variable, Set<MethodSignature> checkedMethods, boolean strict) { final PsiElement[] elements = declarationStatement.getDeclaredElements(); for (PsiElement element : elements) { if (element instanceof PsiVariable declaredVariable) { if (expressionAssignsVariableOrFails(declaredVariable.getInitializer(), variable, checkedMethods, strict)) { return true; } } } return false; }