void () { TriConsumer<String, String, String> checkCompatibility = (String ideVersion, String sinceBuild, String untilBuild) -> { boolean ignoreCompatibility = PluginManagerCore.isIgnoreCompatibility; try { assertIncompatible(ideVersion, sinceBuild, untilBuild); PluginManagerCore.isIgnoreCompatibility = true; assertCompatible(ideVersion, sinceBuild, untilBuild); } finally { PluginManagerCore.isIgnoreCompatibility = ignoreCompatibility; } }; checkCompatibility.accept("42", "43", null); checkCompatibility.accept("43", null, "42"); }