Skip to content

JNetReflector check the beginning of TypeName#923

Merged
masesdevelopers merged 7 commits intomasterfrom
897-nested-classes-are-not-removed-from-reflection-setting-its-container-class
Apr 8, 2026
Merged

JNetReflector check the beginning of TypeName#923
masesdevelopers merged 7 commits intomasterfrom
897-nested-classes-are-not-removed-from-reflection-setting-its-container-class

Conversation

@masesdevelopers
Copy link
Copy Markdown
Contributor

@masesdevelopers masesdevelopers commented Apr 7, 2026

Description

Instead to check the full equivalence of type name, the new check verify if type name starts with one of the excluded class: if the containing class is in the list of avoided classes, the nested classes, which starts with the same type name of its containing class, shall be avoided too otherwise there isn't a container in C# to allocated nested classes.

Related Issue

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Instead to check the full equivalence of type name, the new check verify if type name starts with one of the excluded class: if the containing class is in the list of avoided classes, the nested classes, which starts with the same type name of its containing class, shall be avoided too otherwise there isn't a container in C# to allocated nested classes.
Within the check a class load error was discovered since the class received from the function JVMClass can receive a type containing the definition of a generic type: to avoid load problem if the type contains a possible generic definition the type name is updated and the class is loaded using the raw type name.
@masesdevelopers masesdevelopers self-assigned this Apr 7, 2026
@masesdevelopers masesdevelopers added bug Something isn't working JNetReflector JNetReflector related issue labels Apr 7, 2026
@masesdevelopers masesdevelopers merged commit 363079b into master Apr 8, 2026
11 checks passed
@masesdevelopers masesdevelopers deleted the 897-nested-classes-are-not-removed-from-reflection-setting-its-container-class branch April 8, 2026 02:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working JNetReflector JNetReflector related issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nested classes are not removed from reflection setting its container class

1 participant