Skip to content

Commit

Permalink
Merge pull request #193 from swingfield/master
Browse files Browse the repository at this point in the history
Nodeclipse issue #189 - workaround for node issue 25266
  • Loading branch information
Paul Verest committed Jul 13, 2015
2 parents fc9c8a9 + e5b5b0f commit ed887a3
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ public enum DebuggerCommand {
BREAK("break"),
EXCEPTION("exception"),
AFTER_COMPILE("afterCompile"),
COMPILE_ERROR("compileError"),
SCRIPT_COLLECTED("scriptCollected"),
;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,27 @@ BreakpointProcessor get(DefaultResponseHandler instance) {
command2EventProcessorGetter.put(DebuggerCommand.BREAK /* event */, bppGetter);
command2EventProcessorGetter.put(DebuggerCommand.EXCEPTION /* event */, bppGetter);

// Nodeclipse Issue 189 / node issue 25266
// Treat the "compileError" event as if it were
// the "afterCompile" event...
// This is a workaround for an apparent problem in node
// that was introduced in v0.11.14. The reported problem
// is that when a new script is required and compiled,
// the compileError event is generated instead of the
// afterCompile event.
// If this does in fact turn out to be a node issue,
// then presumably this workaround would be version-specific,
// and would only need to be activated for certain versions
// of node.
command2EventProcessorGetter.put(DebuggerCommand.COMPILE_ERROR /* event */,
new ProcessorGetter() {
@Override
AfterCompileProcessor get(DefaultResponseHandler instance) {
return instance.afterCompileProcessor;
}
});
// <end> Nodeclipse Issue 189 / node issue 25266

command2EventProcessorGetter.put(DebuggerCommand.AFTER_COMPILE /* event */,
new ProcessorGetter() {
@Override
Expand Down

0 comments on commit ed887a3

Please sign in to comment.