if (contextElement == null) {
throw EvaluateExceptionUtil.CANNOT_FIND_SOURCE_CLASS;
}
final Project project = contextElement.getProject();
PsiCodeFragment codeFragment = DefaultCodeFragmentFactory.getInstance().createCodeFragment(text, contextElement, project);
<BUG>DebuggerUtils.checkSyntax(codeFragment);</BUG>
if(codeFragment == null) {
throw EvaluateExceptionUtil.createEvaluateException(DebuggerBundle.message("evaluation.error.invalid.expression", text.getText()));
<BUG>}
return build(codeFragment);</BUG>
}

if (contextElement == null) {
throw EvaluateExceptionUtil.CANNOT_FIND_SOURCE_CLASS;
}
final Project project = contextElement.getProject();
PsiCodeFragment codeFragment = DefaultCodeFragmentFactory.getInstance().createCodeFragment(text, contextElement, project);
if(codeFragment == null) {
throw EvaluateExceptionUtil.createEvaluateException(DebuggerBundle.message("evaluation.error.invalid.expression", text.getText()));
}
codeFragment.forceResolveScope(GlobalSearchScope.allScope(project));
DebuggerUtils.checkSyntax(codeFragment);
return build(codeFragment);
}
