Rust Compilation Anxiety
I’ve used Rust full time for approximately three months. I’d like to share with you my greatest peeve. It’s relatively minor yet important enough to warrant this post: The compiler error count is misleading and harmful.
The Rust compiler presents an error count that will change with each change since last compilation. Because of this, resolving one error from an error count of 3 can turn the total error count to 19, without introducing any new issues in implementation.
While reading this, you may find yourself leading to a reasonable technical explanation that there are limitations with compiling that won’t allow for improved counting. Stop. The problem isn’t technical. The problem relates to communication and design (user experience).
How is this harmful? The error count sets an expectation-- a goal. As the goal post moves from 3 to 19, one may experience a sense of anxiety. A moving goal post is demoralizing.
So… What can be done to improve the experience of working through errors?
My thoughts: The compiler follows a sequence of checks. Can each step of the sequence be named, operations categorized? If so, the compiler can communicate what steps were checked, which are pending, etc.