Skip to content

Expand debugging problem: Add further background to the documentation.#45

Draft
Ajay-singh1 wants to merge 2 commits intorustfoundation:mainfrom
Ajay-singh1:debugging
Draft

Expand debugging problem: Add further background to the documentation.#45
Ajay-singh1 wants to merge 2 commits intorustfoundation:mainfrom
Ajay-singh1:debugging

Conversation

@Ajay-singh1
Copy link
Copy Markdown
Contributor

@Ajay-singh1 Ajay-singh1 commented Apr 4, 2026

Summary

This PR improves the debugging problem description for mixed Rust and C++ environments by adding missing sections and clarifying the problem space.

Changes

  • Added further background explaining the role of debug information formats (e.g., DWARF and PDB) and their limitations in mixed-language scenarios
  • Improved the overall structure and clarity of the problem description

Motivation

Debugging mixed Rust and C++ programs is currently difficult due to differences in type systems, debug information, and language semantics. Existing tooling often exposes low-level representations rather than meaningful abstractions, making it harder for developers to understand program behavior.

Notes

  • This PR focuses on improving the problem definition and documentation
  • It does not introduce implementation changes

…iteria

Signed-off-by: Ajay Singh <ajaykripa8736968359@gmail.com>
@Ajay-singh1 Ajay-singh1 changed the title Expand debugging problem: add example, acceptance criteria, and unresolved questions Expand debugging problem: further background, acceptance criteria, and unresolved questions Apr 6, 2026
Copy link
Copy Markdown
Collaborator

@teor2345 teor2345 left a comment

Choose a reason for hiding this comment

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

Hi, I appreciate the enthusiasm here, but I'm not sure if we're ready to fill in some of this information in the problem statement yet.

This information has to come from active users of these features. It should be supported by links to documentation, decisions about project goals, and stories of user experiences. The "unresolved questions" section is filled in later, when we've covered most of the problem statement, and know what questions are left over.

If you want to apply for Outreachy, please follow the instructions here to submit a code example for "calling overloaded C++ functions from Rust":
https://rust-lang.zulipchat.com/#narrow/channel/578347-outreachy/topic/project.20-.20Calling.20overloaded.20C.2B.2B.20functions.20from.20Rust/near/581501981

The build system project is closed to new applicants, but you can choose from any of the 3 other Rust projects:
https://www.outreachy.org/apply/project-selection/#the-rust-project


Rust currently emits debug information that is largely compatible with existing tooling designed for C and C++. However, Rust’s language features—such as enums with rich semantics, pattern matching, and async/await transformations—do not always map cleanly onto these formats.

As a result, debuggers often fall back to displaying low-level representations of Rust types, exposing implementation details (e.g., discriminants and internal fields) rather than high-level abstractions.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

How do you know this? Can you link to where you got this information from?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It is mentioned on the official documentation.


In mixed-language projects, these issues are amplified. C++ and Rust use different abstractions and conventions, and there is no unified model for representing types and execution flow across both languages in debugging tools.

Additionally, Rust’s async model introduces compiler-generated state machines, which can obscure control flow and make stack traces harder to interpret during debugging.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Again, this paragraph needs a reference to user experiences or other documentation of what works and what doesn't.

Copy link
Copy Markdown
Contributor Author

@Ajay-singh1 Ajay-singh1 Apr 7, 2026

Choose a reason for hiding this comment

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

I'll add a reference to this section of the documentation.

@teor2345 teor2345 added documentation question Further information is requested and removed documentation labels Apr 6, 2026
Removed specific acceptance criteria and unresolved questions related to Rust debugging.
@Ajay-singh1 Ajay-singh1 changed the title Expand debugging problem: further background, acceptance criteria, and unresolved questions Expand debugging problem: Add further background to the documentation. Apr 7, 2026
@Ajay-singh1 Ajay-singh1 marked this pull request as draft April 7, 2026 02:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

question Further information is requested

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants