Skip to content

Add callback support to EnumClassInfo and RegistryClassInfo#8677

Open
APickledWalrus wants to merge 1 commit into
dev/featurefrom
feature/class-info-parser-callbacks
Open

Add callback support to EnumClassInfo and RegistryClassInfo#8677
APickledWalrus wants to merge 1 commit into
dev/featurefrom
feature/class-info-parser-callbacks

Conversation

@APickledWalrus

Copy link
Copy Markdown
Member

Problem

There is a need to take certain actions during the parsing of elements for EnumClassInfo and RegistryClassInfo. For example, printing a deprecation warning when certain elements are used.

Solution

This pull request implements the ability to provide a parseCallback, a Consumer of the parsed element, when creating an EnumClassInfo or RegistryClassInfo.

This was inspired by some changes I was making to teleport flags (as some are now deprecated). Here is an example making use of a callback:
image

While here, I have also deprecated the methods with a registerComparator option. This functionality is no longer needed as Comparators properly handle the cases that necessitated the option.

Testing Completed

Manual testing (see above photo)

Supporting Information

n/a


Completes: none
Related: none
AI assistance: none

@APickledWalrus APickledWalrus requested review from a team as code owners June 2, 2026 18:33
@APickledWalrus APickledWalrus requested review from Pesekjak and UnderscoreTud and removed request for a team June 2, 2026 18:33
@skriptlang-automation skriptlang-automation Bot added needs reviews A PR that needs additional reviews needs triage An issue that hasn't been classified or verified yet labels Jun 2, 2026
@skriptlang-automation

This comment has been minimized.

@skriptlang-automation skriptlang-automation Bot added the enhancement Feature request, an issue about something that could be improved, or a PR improving something. label Jun 2, 2026
@skriptlang-automation skriptlang-automation Bot removed the needs triage An issue that hasn't been classified or verified yet label Jun 2, 2026
@skriptlang-automation skriptlang-automation Bot moved this to In Review in 2.16 Releases Jun 2, 2026
@APickledWalrus APickledWalrus added the feature Pull request adding a new feature. label Jun 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Feature request, an issue about something that could be improved, or a PR improving something. feature Pull request adding a new feature. needs reviews A PR that needs additional reviews

Projects

Status: In Review

Development

Successfully merging this pull request may close these issues.

2 participants