This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Bug: when I try to debug but there is a compiler error...

This is kind of a silly one, but it's annoying too.  If I hit the "debug" button on some code that I didn't build yet, but there's a compiler/linker error, I get a dialog box that asks:

Errors exist in required project(s):

<YOUR PROJECT NAME THAT HAD ERRORS>

Proceed with launch?

There's also a checkbox "Always launch without asking" too.    Launching is impossible since the failed build has blown away the binary file that's to be launched.  Since it is basically impossible to launch the debugger, this dialog should either notify the user that errors exist in the code and provide no option; just return the user to the edit mode,  or if providing the option to launch a binary that no longer exists is so important, change that checkbox to the more realistic "Never launch when errors exist."

It would also be nice to have CCS return to edit mode and not dump the user into debug mode when the build has failed to produce a debuggable binary.   At current, hitting "Cancel" dumps the user into debug mode anyway.

Thank you

Rob

  • Hi Rob,
    You can indeed launch a debug session (launch the debugger and connect to the target), it just won't load the program. However I agree that it is usually pointless since the main purpose was to debug a program that failed to be generated. I like your request to never launch when errors exist. I will file an enhancement request for this.

    Thanks
    ki
  • Rob,

    You raise some interesting points regarding usability when launching debug sessions tied to existing projects. 

    Robert Stoddard64964 said:
    Launching is impossible since the failed build has blown away the binary file that's to be launched.  Since it is basically impossible to launch the debugger, this dialog should either notify the user that errors exist in the code and provide no option;

    The choice is there because it is still possible to launch the debugger and gain access the target without having to load and run an executable. That said, I agree that, in the context the debug session was launched, it presupposes a valid executable to be loaded and therefore launching it without one is moot.

    Robert Stoddard64964 said:
    or if providing the option to launch a binary that no longer exists is so important, change that checkbox to the more realistic "Never launch when errors exist."

    Using converse logic this option really makes more sense. However, how to warn a user the "green bug" debug launch button is inoperative? Throw a message box saying the project still has errors? Do nothing?

    Robert Stoddard64964 said:
    It would also be nice to have CCS return to edit mode and not dump the user into debug mode when the build has failed to produce a debuggable binary. At current, hitting "Cancel" dumps the user into debug mode anyway.

    I fully agree with that. Will have to investigate the feasibility of this.

    This message box comes from the open-source components of Eclipse, therefore the usability implementations may or may not be quick.  

    Regards,

    Rafael