musescore / musescore/MuseScore
Add a defined place to set a breakpoint for any non-clean exit
Open
@RomanPudashkin is already working on this.
Since Jul 10, 2026.
needs review
- Dominant language
- C++
- Stars
- 15.1k
- Forks
- 3.3k
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 91
Description
Your idea
Adding something like this:
std::set_terminate([]()
{
std::cout << "Unhandled exception\n" << std::flush;
// set a debuger's breakpoint here to get a proper stack trace on any crash
std::abort();
});
somewhere in early startup, like in main(), prior to entering the main loop, would enable us to properly debug any crash, to at least get a proper stack trace.
Problem to be solved
Debugging some crashes is next to impossible when not being able to get a proper stack trace.
One example woulde be "pure virtual method called".
Prior art
There's one place that exists already for this, but that only catches qAssert()s, as far as I can tell
Additional context
n/a
Checklist
- This request follows the guidelines for reporting issues
- I have verified that this feature request has not been logged before, by searching the issue tracker for similar requests
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.