Skip to content

Conversation

@supersaiyansubtlety
Copy link
Member

fixes #91

repurposed from my fix for #274 that was plagued by AnalyzerExceptions when used by QMap

this:

  • exposes Enigma's lib index
  • adds and exposes a combined index containing both lib and main jar entries to Enigma
  • passes the combined index to EntryRemapper instead of the main jar index
  • disallows renaming entries that trace back to libs (effects Interface implementers with external method implementations prevent naming in GUI #274, but only for the limited number of lib classes currently indexed)
  • removes java/lang/Object's explicit exclusion from InheritanceIndex (added in this commit)

Also adds but does not use JavaClassProvider which can be swapped for ClasspathClassProvider to fix more of #274 once AnalyzerExceptions are sorted.

When squash-merging, be sure to change the commit message about fixing #274 so it doesn't get prematurely closed.

add JavaClassProvider which provied java.* classes
add CombinedJarIndex which indexes main jar and libraries
added missing translation for "progress.jar.indexing.libraries"
keep lib classes whose fields or methods are referenced in the main jar
check if method is indexed in EnigmaProject::isLibraryMethodOverride
@supersaiyansubtlety supersaiyansubtlety self-assigned this Sep 26, 2025
@supersaiyansubtlety supersaiyansubtlety added bug Something isn't working backend affects the enigma backend labels Sep 26, 2025
@ix0rai ix0rai self-requested a review October 26, 2025 17:51
@ix0rai ix0rai moved this to Ready in enigma 2.7 Nov 4, 2025
@ix0rai ix0rai added this to enigma 2.7 Nov 4, 2025
@ix0rai ix0rai moved this from Ready to In review in enigma 2.7 Nov 4, 2025
@supersaiyansubtlety supersaiyansubtlety mentioned this pull request Nov 9, 2025
8 tasks
@ix0rai ix0rai merged commit 42ddbd9 into QuiltMC:develop/2.7 Nov 9, 2025
2 checks passed
@github-project-automation github-project-automation bot moved this from In review to Done in enigma 2.7 Nov 9, 2025
@ix0rai ix0rai mentioned this pull request Nov 12, 2025
5 tasks
ix0rai added a commit that referenced this pull request Nov 16, 2025
* OUT OF MEMORY when trying to run all tests
add JavaClassProvider which provied java.* classes
add CombinedJarIndex which indexes main jar and libraries
added missing translation for "progress.jar.indexing.libraries"

* make methods that trace back to non-jar methods non-renamable

* checkstyle

* filter out unreferenced classNames for LibrariesJarIndex and CombinedJarIndex

* add ReferenceIndex::getFieldsReferencedBy
keep lib classes whose fields or methods are referenced in the main jar

* exclude java/io/PrintStream from JavaClassProvider
check if method is indexed in EnigmaProject::isLibraryMethodOverride

* update asm (AnalyzerExceptions persist)

* use ClasspathClassProvider instead of JavaClassProvider to avoid AnalyzerExceptions; BREAK #274

* stop excluding Object from InheritanceIndex and update tests; fix #91

* update TODO

* try finding child node instead of assuming it's first

* add clarifying comment to UN_ANALYZABLE_CLASS_NAMES

Co-authored-by: ix0rai <[email protected]>

* add jar index javadocs

---------

Co-authored-by: ix0rai <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend affects the enigma backend bug Something isn't working

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

[bug] enigma does not consider that classes all override java/lang/Object

2 participants