OT: Seven Ineffective Coding Habits of Many Programmers
J. Landman Gay
jacque at hyperactivesw.com
Fri Oct 12 14:12:56 EDT 2018
On 10/11/18 5:57 PM, Mark Wieder via use-livecode wrote:
> On 10/09/2018 11:05 AM, Sannyasin Brahmanathaswami via use-livecode wrote:
>
>> ITT 2016 - Kevlin Henney - Seven Ineffective Coding Habits of Many
>> Programmers
>>
>> https://www.youtube.com/watch?v=ZsHMHukIlJY
>
> Kevlin Henney is always an entertaining speaker.
>
I watched some of this and he talked about a couple of my personal pet
peeeves. The first is excessive commenting, and while I'm all in favor
of commenting code, sometimes it tends to the ridiculous. I agree with
Henney's remark that good code is self-descriptive, and LC does that
better than anything else. I've seen 20 lines of comment above a 10-line
handler, sometimes set off in a fancy ascii rectangle. Each to his own,
I guess. It's mildly annoying but I can ignore it.
The one the bothers me more though is what he calls "LegoNaming." I
remember being irritated when MC introduced "blendLevel" because it was
too long to type quickly, and at the time was one of the longest entries
in the dictionary. I got over that pretty quick when we started to see
things like windowBoundingRect and fullScreenMode. But some of the new
commands and messages are approaching unusability because they are
impossible to remember and hard to type correctly, and usually require a
dictionary lookup/copy/paste. We've got iphoneGetNotificationBadgeValue
and AVPlayerItemFailedToPlayToEndTimeNotification. But the top entry in
this category is mergBLEPeripheralDiscoverDescriptorsForCharacteristic.
That's not a term, it's a sentence.
C'mon guys. I understand how descriptive, specific names that indicate
precise usage may be desirable, but if the term runs off the right edge
of the dictionary it's gone too far.
--
Jacqueline Landman Gay | jacque at hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
More information about the use-livecode
mailing list