Re:Applying the Linus Torvalds “Good Taste” Coding Requirement
by firethief on Wednesday October 26, 2016 @02:01PM
(#12798847)
There's a compromise enterprise developers should recognize from CS classes that's almost elegant enough for the kernel crowd: use a sentinel node for the element before the head. The edge case is eliminated, and no more &(*)->; ASCII Cthulhu.
[ Parent
| on HN ]
Re:Applying the Linus Torvalds “Good Taste” Coding Requirement
by zwieback on Wednesday October 26, 2016 @03:31PM
(#12799676)
That was my first thought, my basic algorithms book specifically mentions sentinel as a way to eliminate the head boundary condition.
Linus basic point stands although his example isn't very good.