Closed lucamug closed 2 years ago
Hey Luca,
Thank you for the issue. Could you create an SSCCE maybe? That would help knowing whether a solution I could implement solves the issue or not.
I would have to look at whether it's the rule you mentioned is doing something incorrect or weird, or if it's elm-review. Anyway, elm-review should have noticed there was a problem after the fix, so in any case I think this is something that should be improved 👍
I just re-read the issue, and the result is valid Elm syntax, though a weird one. I don't think there's much that elm-review
can do about this, at least with our current means of checking the result of a fix (checking whether the new code is syntactically valid Elm code). We could do more by running the compiler but that would be very slow, and I'd hope to be able to avoid that as much as possible.
I will close the issue as I don't know of anything else this tool could do. Please open an issue in the project exposing NoUnsortedRecordFields
, and if there is something else that you think elm-review
could help with, please open a new issue here.
I got several times broken Elm code if the autofix feature move a string containing
\"
. For example, this line of Elmwas transformed to
also
was transformed to
This case in particular happened with the rule
NoUnsortedRecordFields
but I think it happened with other rules too, if I remember correctly.