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

Add an IDE inspection error for mixin and target type mismatches #2343

Open
O7410 opened this issue Aug 1, 2024 · 3 comments
Open

Add an IDE inspection error for mixin and target type mismatches #2343

O7410 opened this issue Aug 1, 2024 · 3 comments

Comments

@O7410
Copy link
Contributor

O7410 commented Aug 1, 2024

Minecraft Development for IntelliJ plugin version

2024.1-1.8.0

Description of the feature request

Currently, when the mixin is an interface and the target is a class, there is no IDE error, but there is a compile error that says:
Targetted type 'net.minecraft.block.Block of mypackage.mixin.BlockMixin is not an interface
When the mixin is a class and the target is an interface, there is a runtime error that says
@Mixin target type mismatch: net.minecraft.text.Text is an interface in org.spongepowered.asm.mixin.transformer.MixinInfo$SubType$Standard@75769ab0
This is the behavior i want:
image
image

This is low priority since it's very easy to see what the problem is when you try to run it (the compile and runtime errors)

@O7410
Copy link
Contributor Author

O7410 commented Aug 1, 2024

should also mention i used fabric with yarn mappings to test

@Earthcomputer
Copy link
Member

How did you get those screenshots? Did you make this inspection yourself already?

O7410 added a commit to O7410/MinecraftDev that referenced this issue Aug 2, 2024
@O7410
Copy link
Contributor Author

O7410 commented Aug 2, 2024

Yeah i wrote some horrible code
you can look at it here O7410@2de6199

O7410 added a commit to O7410/MinecraftDev that referenced this issue Aug 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants