mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Fixed wrong test condition in disabling inspections for Cython
This commit is contained in:
@@ -43,7 +43,7 @@ public class PyArgumentListInspection extends PyInspection {
|
||||
|
||||
@Override
|
||||
public void visitPyArgumentList(final PyArgumentList node) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node.getLanguage())) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node)) {
|
||||
return;
|
||||
}
|
||||
// analyze
|
||||
|
||||
@@ -50,7 +50,7 @@ public class PyUnboundLocalVariableInspection extends PyInspection {
|
||||
return new PyInspectionVisitor(holder){
|
||||
@Override
|
||||
public void visitPyReferenceExpression(final PyReferenceExpression node) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node.getLanguage())) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node)) {
|
||||
return;
|
||||
}
|
||||
final Set<ScopeOwner> largeFunctions = session.getUserData(LARGE_FUNCTIONS_KEY);
|
||||
@@ -209,7 +209,7 @@ public class PyUnboundLocalVariableInspection extends PyInspection {
|
||||
|
||||
@Override
|
||||
public void visitPyNonlocalStatement(final PyNonlocalStatement node) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node.getLanguage())) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node)) {
|
||||
return;
|
||||
}
|
||||
for (PyTargetExpression var : node.getVariables()) {
|
||||
|
||||
@@ -202,7 +202,7 @@ public class PyUnresolvedReferencesInspection extends PyInspection {
|
||||
@Override
|
||||
public void visitPyElement(final PyElement node) {
|
||||
super.visitPyElement(node);
|
||||
if (CythonLanguageDialect._isDisabledFor(node.getLanguage())) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node)) {
|
||||
return;
|
||||
}
|
||||
if (node instanceof PyReferenceOwner) {
|
||||
|
||||
@@ -74,7 +74,7 @@ class PyUnusedLocalInspectionVisitor extends PyInspectionVisitor {
|
||||
static class DontPerformException extends RuntimeException {}
|
||||
|
||||
private void processScope(final ScopeOwner owner, final PyElement node) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node.getLanguage())) {
|
||||
if (CythonLanguageDialect._isDisabledFor(node)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@ public class ParameterListAnnotator extends PyAnnotator {
|
||||
int inTuple = 0;
|
||||
@Override
|
||||
public void visitNamedParameter(PyNamedParameter parameter, boolean first, boolean last) {
|
||||
if (CythonLanguageDialect._isDisabledFor(parameter.getLanguage())) {
|
||||
if (CythonLanguageDialect._isDisabledFor(parameter)) {
|
||||
return;
|
||||
}
|
||||
if (parameterNames.contains(parameter.getName())) {
|
||||
|
||||
Reference in New Issue
Block a user