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
Throw an exception when attempting to register an abstract class #6307
Throw an exception when attempting to register an abstract class #6307
Conversation
There are ClassInfos such as Projectile that are registered as abstract classes |
I believe ClassInfos are okay to be registered as abstract class if Skript doesn't need to instantiate them. |
Marked as feature-ready, but I believe this is fine for a patch as well. |
488d21c
to
fe0a5f9
Compare
Description
Registering an abstract class as a syntax element doesn't cause any errors;
however, parsing a code matching it will fail with an error like "Can't understand this ..."
I'd like to add a check on the constructor parameter of
SyntaxElementInfo
for abstract classes so an addon developer can notice what's wrong with their addon.Target Minecraft Versions: any
Requirements: none
Related Issues: none