-
Notifications
You must be signed in to change notification settings - Fork 433
Refactor output selection into handler methods #4223
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
Refactor output selection into handler methods #4223
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| File cn1Globals = new File(srcRoot, "cn1_globals.h"); | ||
| copy(ByteCodeTranslator.class.getResourceAsStream("/cn1_globals.h"), new FileOutputStream(cn1Globals)); | ||
| if (System.getProperty("INCLUDE_NPE_CHECKS", "false").equals("true")) { | ||
| replaceInFile(cn1Globals, "//#define CN1_INCLUDE_NPE_CHECKS", "#define CN1_INCLUDE_NPE_CHECKS"); | ||
| } | ||
| File xmlvm = new File(srcRoot, "xmlvm.h"); | ||
| copy(ByteCodeTranslator.class.getResourceAsStream("/xmlvm.h"), new FileOutputStream(xmlvm)); | ||
| File nativeMethods = new File(srcRoot, "nativeMethods.m"); | ||
| copy(ByteCodeTranslator.class.getResourceAsStream("/nativeMethods.m"), new FileOutputStream(nativeMethods)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copy cn1_globals.m for clean output
The new handleCleanOutput() copies cn1_globals.h and nativeMethods.m but never copies cn1_globals.m, even though the generated C code (and nativeMethods.m) rely on implementations defined there such as monitorEnter/GC helpers. The iOS handler still copies both header and .m (lines 293–299), so the clean target now ships only declarations and will fail to link when using the clean output mode.
Useful? React with 👍 / 👎.
✅ Continuous Quality ReportTest & Coverage
Static Analysis
Generated automatically by the PR CI workflow. |
✅ ByteCodeTranslator Quality ReportTest & Coverage
Static Analysis
Generated automatically by the PR CI workflow. |




























Summary
Testing
Codex Task