there is no way of doing that, the debug shell executing just interfere in objects that are currently in the context of the running program.
you can change the values of variables and objects that are currently at runtime, but not define new ones on the debug shell. even if you could do that your new variable will not be anywhere in your code, and if you have it declared, you may have issues declaring the same identifier twice.
if you declare a new variable like in your example (
int c = a + b; ), the
c variable will be available only inside your debug shell context.
one workaround to you see the result of the execution is to inspect your expression using the ctrl + shift + i shortcut:
- How to create a new variable using debug shell
- How to create new project from GIT repo using Eclipse EGit
- How to create a new android project without using support libraries?
- How to create new Eclipse RCP project using Maven?
- How to create new projects in Eclipse using Maven 3 archetypes
- How to create Android application without ActionBar using new theme in API9?
- How to create a new JSP project in Eclipse using Maven and Jetty
- How to create a new debug marker with icon for eclipse error view?
- how to create a new folder inside a folder using IFolder or IResources interfaces in eclipse
- How to create a new text file in SVN using SVNKIT..?
- How to create default debug and run configuration in Eclipse?
- How to Debug Android application line by line using Eclipse?
- How do I run Eclipse using Oracle's new 1.7 JDK for the Mac?
- How to debug Java code when using ANT script in Eclipse
- How to upgrade new version of Eclipse instead of using new downloaded package?
- How can I create a Windows .exe (standalone executable) using Java/Eclipse?
- How to create a new layout for an Android project (using Eclipse)
- Cannot create a new Android Project using Eclipse
- How to create a swing application using maven?
- how to create a new AVD in eclipse?
- how to create jar file using eclipse
- EGit: how to create a new tag?
- How do I configure Eclipse to launch a browser when Run or Debug is selected using Pydev plugin
- c++: How to debug a C++ application compiled using the "Microsoft Visual C++" toolchain in eclipse?
- How do I debug properly using Eclipse and Pydev?
- How to ignore "id" in Short Variable rule using PMD
- How do I debug GlassFish 3 using Eclipse Helios?
- How to create new android project in eclipse and share in local git repository?
- How to debug servlet using Eclipse
- How to get Eclipse to stop asking to create a module-info java file on new Java project creation?
More Query from same tag
- Eclipse runs debug mode even when I click "run"
- GWT-JRE-Emulated classes aware Eclipse?
- What is the purpose of org.eclipse.jst.ws.util.JspUtils.markup(String text) method
- Eclipse: Turn on syntax-highlighting for Classes and Objects
- Using OBR on Virgo 3.5
- UPDATED: Android: java.lang.RuntimeException: Unable to start activity ComponentInfo
- Eclipse compilation and make file
- Incorrect time in Eclipse. How to change it?
- Android Listview multiple buttons click
- Liferay Developer Studio not showing "File" menu, any trick to perform an import?
- Java eclipse expression window view the full HttpRequest from @RequestBody
- 404 - the requested ressource is not available
- Eclipse Gradle STS Plugin. Add project reference vs dependency management
- Installed java 64 bit but still gettin error opening eclipse
- How do I detach JProfiler from Eclipse?
- Eclipse->New Android Projects always compile java 1.4
- Using OpenOCD for debugging STM32F1xx Discovery board (ST-Link)
- Cannot create JPA Facet: "project facet jpt.jpa could not be found"
- eclipse can't see my lenovo S650 phone
- Setting Eclipse STS to use Java 8 to compile java code of my project
- Remote debugging in apache ant and eclipse
- How to set a build path from terminal
- how to manage multiple editions of the same android app
- Add a method breakpoint to all methods of a class in EclipseIDE
- mvn install is not working in eclipse but works fine from command line
- Failing a very simple program in both ways
- How can I push project in specific folder in my GitHub repository?
- How to remove trailing space behind multiline comment's asterisk in Eclipse autoformat
- How do I use MiG Layout with Eclipse?
- SVN Update issue