3 ms·
At work we're maintaining a rather big software written in C (not that much, <1M loc). It's a bit odd: there's no brackets at all (only BEGIN and END), and the
by bpizzi 8y ago
At work we're maintaining a rather big software written in C (not that much, <1M loc).
It's a bit odd: there's no brackets at all (only BEGIN and END), and the majority of names (functions and variables) are 6 characters long.
Guess what, it's was ported from Pascal. There's a '#define BEGIN {' in a header.
- olavk 8y agoDidn't editors have search-replace back then? Although I can understand this if the developers hated C and was forced to port against their will.
- bpizzi 8y agoThey were not forced, it was their choice, and the choosen editor (vs6) do have search/replace. My personal guess is that keeping those BEGIN/END was seen as a smart move.
- solarkraft 8y agoI guess they just liked the way it looked & felt? Really doesn't seem to make a difference to the development other than it feeling more familiar to Pascal devs.
- bpizzi 8y agoIt doesn't harm the development, indeed. However it does harm the developer's freedom in choosing his tools, for example Vim will try to fold regions delimited by brackets in C files. Nothing unbearable in the end.
- pix64 8y agoSo why not fix it?
- bpizzi 8y agoYou know why: some organizations are simply not meant to be fixed. People get hurt for silly reasons and one may not want to hurt the wrong people.