Vineflower / vineflower

Modern Java decompiler aiming to be as accurate as possible, with an emphasis on output quality. Fork of the Fernflower decompiler.
https://vineflower.org/
Apache License 2.0
1.12k stars 83 forks source link

The decompiler configuration options are not working #406

Closed meiMingle closed 2 days ago

meiMingle commented 3 days ago

Vineflower version

1.10.1

Describe the bug

At least Dump Code Lines does not work at the moment.

Additional information

See Recaf/issues/801

Geolykt commented 3 days ago

This is a bug in recaf - it works just fine in gslStarplane.

Geolykt commented 3 days ago

Okay, I've just did some further digging into this issue since "works on my end" would've seriously angered me. The Dump Code Lines option is mostly completely irrelevant to most users - it just has the effect that the line mappings are stored in the output zip file as extra data - see https://github.com/Vineflower/vineflower/blob/ddf84710f8521ce62d1e3e55a39d300432d6b729/src/org/jetbrains/java/decompiler/main/decompiler/SingleFileSaver.java#L126-L127

What you are looking for is DUMP_ORIGINAL_LINES (or __dump_original_lines__). However recaf does not expose this option - probably because the name hints at this attribute probably being for internal use only.

Col-E commented 2 days ago

However recaf does not expose this option

I just went down the list in IFernflowerPreferences but if I missed something, that's my bad. I agree that if the DCL flag is for zip output I should hide it so people don't get confused.

This issue can be closed.