rescript-lang / rescript-lang/reanalyze
`-write` removes trailing newline from modified file
Nobody has claimed this yet.
- Dominant language
- OCaml
- Stars
- 281
- Forks
- 22
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 7
Description
Running reanalyze https://github.com/rescript-association/reanalyze/commit/389dd682223201b42c33e5c444e5c79e0805adad on Goblint https://github.com/goblint/analyzer/commit/a544002114324a207df72f9e79eb656c3ebe7b5b revealed the following.
When -write modifies a file to add dead code attributes, it removes the trailing newline from the file. Since all other code style is nicely preserved, it shouldn't be removing that.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the -write behavior described in the issue using the linked ReScript and Goblint commits as context. Inspect the code path that adds dead code attributes and writes the modified file; done means the trailing newline is preserved while the other formatting remains unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ocaml
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100