Skip to content
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

Add some type commands to the disassembler #2151

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ike709
Copy link
Collaborator

@ike709 ike709 commented Dec 30, 2024

  • Added a requested dump-types command. This just prints a list of all types to a file. The count is so huge on bigger codebases that writing it to the console isn't feasible.
  • Added a new stats subtypes-by-type command. This is similar to stats procs-by-type except it prints the number of direct subtypes on each type. This also has to go to a file due to its huge size.
  • Added some prettyprint formatting to various prints where it was missing.

@boring-cyborg boring-cyborg bot added the Compiler Involves the OpenDream compiler label Dec 30, 2024
DMDisassembler/Program.cs Outdated Show resolved Hide resolved
DMDisassembler/Program.cs Dismissed Show resolved Hide resolved
DMDisassembler/Program.cs Outdated Show resolved Hide resolved

var outputFile = Path.ChangeExtension(JsonFile, ".txt")!;
var name = Path.GetFileName(outputFile);
outputFile = outputFile.Replace(name!, $"__od_subtypes-by-type_{name}");
Copy link
Member

Choose a reason for hiding this comment

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

This could potentially break if name appears in the path multiple times


var outputFile = Path.ChangeExtension(JsonFile, ".txt")!;
var name = Path.GetFileName(outputFile);
outputFile = outputFile.Replace(name!, $"__od_types_{name}");
Copy link
Member

Choose a reason for hiding this comment

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

Same problem here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compiler Involves the OpenDream compiler size/M
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants