Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial commit of the Scala debugger #1000864 #87

Merged
merged 15 commits into from Apr 12, 2012

Conversation

skyluc
Copy link
Member

@skyluc skyluc commented Apr 5, 2012

This is the base of the new Scala debugger. A fair amount of work is still needed. The icons and labels need to be improved. The features need to be test in more cases. The hedge cases need to checked.
But it is stable and it needs to be used to get more test cases.

The code is self contained in org.scala-ide.sdt.debug and org.scala-ide.sdt.debug.test, with a few change to add it to the build process and access features provided by sdt.core.

Documentation is available at http://scala-ide.org/docs/helium/features/scaladebugger/index.html

skyluc and others added 13 commits March 5, 2012 12:09
It is enable using a checkbox in the preferences.
It replaces the Java based debug elements by the Scala ones.
Only terminate and improved step over actions are supported right now.
None of the labels are fine.
There are likely a lot of bug and other missing things.
I'll create some doc about it on the website.
??? was added in 2.10, and I'm using it in the code right now.
This change can be reverted when the model is fully implemented.
Improved display of all elements.
Added support for resume action.
Added 'this' in variable list.
Created tests for all improvements.
Added hack of logical structure support.
Improved the support for logical structure for collections
Changed the display name for array indexes
Added support for symbols in names

With tests
Added display of boxed values for boxing types
Added a tweak for a JDT bug.
Added support for step into and out actions.
Improved the test framework so it is more resilient
Fixed some stack traces thrown when program was terminating
Updated source locator to work with any type using file search and type search.
Fixed problem with smart step over in method without line information.
* Reworked the code to use only one list of jdi requests
Fetch local variable value right await, as the stack frame can become invalid at any time.
Changed the way the method signature for the stackframe label is generated
* MethodReference@argumentTypes can fail, especially when debug osgi application.
* MethodReference#getArguments can fail too, for native methods
* Uses the method JNI signature to create a method name.
Send the right event on resume.
Handle null thread group
Logic for can resume was reversed
Added check to avoid abstract methods in anon func search
Switch to actors to manage debug events
Sorted object reference fields by name
Added support for thread suspend
Fixed problem where main thread was appearing twice.
Fixed debug session hanging. All requests to the VM needs to be set to THREAD_ONLY suspend policy
'this' reference is not available for native methods
Copy of the JDT TcpIpSpy with a fix for ReferenceType#MethodsWithGeneric
Disable step over tests for collection of Ints, due to SI-5646 problem
@gkossakowski
Copy link
Contributor

I cannot say anything about the code but I'd love to see this hit nightly builds ASAP. :-)

def handleDebugEvents(events: Array[DebugEvent]) {
events.foreach(event =>
event.getKind match {
case DebugEvent.CREATE =>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be very nice if we could use actors for these events. In the future (no pun intended).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(promise!)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Saw the actor later down.. but the extractor idea could still apply :)

Luc Bourlier added 2 commits April 11, 2012 11:55
Added some comments and cleaned style.
Switch management of Eclipse Debug Event to use extractors.
Made ScalaStepOver use the find anon func methods from ScalaDebugTarget.
Made some stepping tests less fragile.
Created stepping tests for bridge method optimisation, and enabled test without optimization.
Added Scala 2.10 vs 2.09 check in debug session.
skyluc pushed a commit that referenced this pull request Apr 12, 2012
Initial commit of the Scala debugger #1000864
@skyluc skyluc merged commit ddf3c98 into master Apr 12, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants