Skip to content

[Doc] improve the documentation for the role of returns edges in the dfg #1659

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

Conversation

EagleoutIce
Copy link
Member

No description provided.

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR enhances the documentation around how return edges and exit points are represented in both the Dataflow and Control Flow Graph wikis, plus a few small code cleanups.

  • Added a “Working With Exit Points” section to the CFG wiki and updated generation timestamps.
  • Enhanced the Dataflow Graph wiki with richer notes on Returns edges, anonymous function origins, and issue links.
  • Consolidated imports and adjusted fallback behavior in the Mermaid DFG renderer; introduced UnnamedFunctionCallOrigin constant.

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
wiki/Control Flow Graph.md Updated timestamps and added “Working With Exit Points” section
src/util/mermaid/dfg.ts Merged imports and changed the default node-lexeme fallback value
src/documentation/print-dataflow-graph-wiki.ts Reordered imports, added Returns-edge documentation and note blocks
src/documentation/print-cfg-wiki.ts Added imports for edge names/assertions and new exit-points section
src/dataflow/internal/process/functions/call/unnamed-call-handling.ts Added UnnamedFunctionCallOrigin and updated its usage
Comments suppressed due to low confidence (2)

src/documentation/print-cfg-wiki.ts:2372

  • Correct 'exit points' to singular 'exit point' when referring to one marker.
Looking at the if vertex for (with id `5`) we see that it is again linked to a single exit points: `5-exit`.

src/dataflow/internal/process/functions/call/unnamed-call-handling.ts:16

  • Consider adding or updating unit tests to verify that UnnamedFunctionCallOrigin is correctly emitted and consumed in processUnnamedFunctionCall.
export const UnnamedFunctionCallOrigin = 'unnamed';

@EagleoutIce EagleoutIce merged commit e26f98b into main May 19, 2025
19 checks passed
@EagleoutIce EagleoutIce deleted the 1655-doc-improve-the-documentation-for-the-role-of-returns-edges-in-the-dfg branch May 19, 2025 21:39
@EagleoutIce
Copy link
Member Author

This pull request is included in v2.2.13 (see Release v2.2.13 (Control-Flow Graph, R Graphics, and Better Aliasing)).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Doc] Improve the Documentation for the Role of Returns Edges in the DFG
1 participant