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

feat(#229): Avoid Using Labels on Stack #259

Merged
merged 4 commits into from
May 21, 2024

Conversation

volodya-lombrozo
Copy link
Member

@volodya-lombrozo volodya-lombrozo commented May 21, 2024

In this PR I fixed the problem with incorrect Labels handling on stack. Actually, Labels shouldn't be used on stack during decompilation. So
I attached labels to near nodes. This fixed several decompilation problems in integration tests.

Risk: Labels are decompiled in a different way as any other nodes. This incosistency might cause some problems in the future. In order to find a proper solution, I added one more issue.

Related to #229.
History:


PR-Codex overview

This PR enhances the decompilation process by refactoring label handling, adding test coverage, and improving code readability.

Detailed summary

  • Refactored label handling in Labeled class
  • Added a test for array store decompilation
  • Improved code readability by using @ToString annotation
  • Updated log messages in test
  • Enhanced InvokespecialHandler by checking target type before linking

The following files were skipped due to too many changes: src/test/resources/xmir/BeanMethod$NonOverridableMethodError.xmir, src/it/decompile-compile/target/generated-sources/jeo-xmir/org/eolang/jeo/BeanMethod$NonOverridableMethodError.xmir

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

@volodya-lombrozo
Copy link
Member Author

@rultor merge

@rultor
Copy link
Contributor

rultor commented May 21, 2024

@rultor merge

@volodya-lombrozo OK, I'll try to merge now. You can check the progress of the merge here

@rultor rultor merged commit 0d93512 into objectionary:master May 21, 2024
8 checks passed
@rultor
Copy link
Contributor

rultor commented May 21, 2024

@rultor merge

@volodya-lombrozo Done! FYI, the full log is here (took me 7min)

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.

2 participants