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

Line spacing #14

Open
lukepuplett opened this issue Feb 27, 2024 · 0 comments
Open

Line spacing #14

lukepuplett opened this issue Feb 27, 2024 · 0 comments

Comments

@lukepuplett
Copy link

lukepuplett commented Feb 27, 2024

The worst code has bizarre line-space grouping so you think you see blocks of logic where there are none. The best place for this is anything in a book or sample, where suckers who are learning don’t know any better.

It should also rename things, but subtly. So, remove any verbs so the caller can't tell if the call might mutate state or have side-effects.

Also, where you have e.g. a count of cats, call that variable just cats so it appears as if it could reasonably contain the actual iterable of cats, but also contain the count of cats such that you're bound to lose in an argument with the author.

This could be part of a new tool call refuctor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant