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

Lambdas do not get remapped #4

Open
TwilightFlower opened this issue Jun 14, 2020 · 4 comments
Open

Lambdas do not get remapped #4

TwilightFlower opened this issue Jun 14, 2020 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@TwilightFlower
Copy link

When remapping a lambda, everything appears to get remapped properly except the name of the method to implement. (The invokedName parameter of LambdaMetafactory.metafactory.) This results in an AbstractMethodError when the lambda is called.

@jamierocks
Copy link
Member

Presumably this issue is meant for Lorenz? (don't close, I can move it)

Though could you supply some example mappings that are causing issues?

@jamierocks jamierocks self-assigned this Jun 14, 2020
@jamierocks jamierocks added the bug Something isn't working label Jun 14, 2020
@TwilightFlower
Copy link
Author

TwilightFlower commented Jun 17, 2020

Ah, sorry for putting this on the wrong project. Specifically, I was remapping Minecraft Forge universal (everything under the net.minecraftforge package) from SRG to obfuscated. I don't remember exactly where the error cropped up, though -- I forgot to create this issue for a few weeks. I could create a smaller test case to demonstrate it when I have more time in a week or so.

@jamierocks
Copy link
Member

I could create a smaller test case to demonstrate it when I have more time in a week or so.

Did you get chance to follow this up at all?

@LexManos
Copy link

LexManos commented Jun 17, 2021

public interface TestLambda {
    static final TestLambda TEST = () -> System.out.println("test");
    void hello();
    
    public static void main(String... args) {
        TEST.hello();
    }
}
TestLambda TestLambda
	hello ()V goodbye
Exception in thread "main" java.lang.AbstractMethodError: TestLambda$$Lambda$1/754666084.goodbye()V
        at TestLambda.main(TestLambda.java:6)

Simple enough test case. It is borked.

This is my fix in SS for it, gunna hack it into my fork for the time being. LexManos/SpecialSource@ef5ac81
Edit: My fix: LexManos/Vignette@c597252

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants