Refactor - transform classes to use singleton pattern#1291
Merged
Conversation
* Initial plan * Add .github/copilot-instructions.md for agent onboarding Co-authored-by: tgiphil <124747+tgiphil@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: tgiphil <124747+tgiphil@users.noreply.github.com>
- Introduced "Agent Coding Rules" in copilot-instructions.md, prohibiting unsafe code, manual edits to generated files, and changes to Mosa.UnitTests by AI/Copilot. - Clarified .NET SDK requirements, now preferring .NET 10 SDK for local development and explaining CI roll-forward. - Updated style guide to note "unsafe" is forbidden despite its presence in modifier order. - Added copilot-instructions.md as a solution item in a new "Copilot" folder in Mosa.sln for visibility in Visual Studio.
Improving reporting accuracy and consistency Cleaning up naming, structure, and shutdown behavior
Changed EmitBinary from a public property to a private property with getter and setter, limiting its visibility within the class. This encapsulates the field and prevents external modification.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request refactors several transform classes to implement the singleton pattern. Instead of creating new instances each time, these classes now expose a static
Instanceproperty and have private constructors. This change improves memory usage and performance by reusing the same instance.