All things programming - language and framework agnostic.
Applying the Linus Torvalds “Good Taste” Coding Requirement
Applying the Linus Torvalds "Good Taste" Coding Requirement
To the best of my ability to discern, the crux of the "good taste" requirement is the elimination of edge cases, which tend to reveal themselves as conditional statements. The fewer conditions you test for, the better your code " tastes". Here is one particular example of an improvement I made that I wanted to share.
bartobri




The improvement here is that the code has less paths to travel down. Therefore there are less edge cases, and it becomes easier to comprehend.
I think the highlight is perhaps overreaching though: "The fewer conditions you test for, the better your code 'tastes'". Your code should, in general, explain your logic and thinking. There are very few situations where the speedup caused by removing a conditional is noticeable. Therefore, you should code for ease of understanding - by yourself, and whoever comes after. If the code works, but you don't understand it, or someone else would have to think hard to get it, then that is bad code.