From 2e838e9196720fcf70fa7b052aa703ef1e38db84 Mon Sep 17 00:00:00 2001 From: "Egor.Ushakov" Date: Mon, 2 Mar 2015 17:55:08 +0300 Subject: [PATCH] IDEA-132677 Groovy evaluation is broken if there are marked values --- .../evaluation/CodeFragmentFactoryContextWrapper.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/java/debugger/impl/src/com/intellij/debugger/engine/evaluation/CodeFragmentFactoryContextWrapper.java b/java/debugger/impl/src/com/intellij/debugger/engine/evaluation/CodeFragmentFactoryContextWrapper.java index 7a709aed4449..26e01417bd58 100644 --- a/java/debugger/impl/src/com/intellij/debugger/engine/evaluation/CodeFragmentFactoryContextWrapper.java +++ b/java/debugger/impl/src/com/intellij/debugger/engine/evaluation/CodeFragmentFactoryContextWrapper.java @@ -1,5 +1,5 @@ /* - * Copyright 2000-2014 JetBrains s.r.o. + * Copyright 2000-2015 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -75,6 +75,10 @@ public class CodeFragmentFactoryContextWrapper extends CodeFragmentFactory { private PsiElement wrapContext(Project project, final PsiElement originalContext) { if (project.isDefault()) return originalContext; + //TODO [egor] : does not work for anything other than java anyway, see IDEA-132677 + if (!(myDelegate instanceof DefaultCodeFragmentFactory)) { + return originalContext; + } PsiElement context = originalContext; XDebugSession session = XDebuggerManager.getInstance(project).getCurrentSession(); if (session != null) {