....The best candidate I have been able to come up with is the C/Unix/Posix use of NUL-terminated text strings. The choice was really simple: Should the C language represent strings as an address + length tuple or just as the address with a magic character (NUL) marking the end? This is a decision that the dynamic trio of Ken Thompson, Dennis Ritchie, and Brian Kernighan must have made one day in the early 1970s, and they had full freedom to choose either way. I have not found any record of the decision, which I admit is a weak point in its candidacy: I do not have proof that it was a conscious decision.
As far as I can determine from my research, however, the address + length format was preferred by the majority of programming languages at the time, whereas the address + magic_marker format was used mostly in assembly programs. As the C language was a development from assembly to a portable high-level language, I have a hard time believing that Ken, Dennis, and Brian gave it no thought at all.
Using an address + length format would cost one more byte of overhead than an address + magic_marker format, and their PDP computer had limited core memory. In other words, this could have been a perfectly typical and rational IT or CS decision, like the many similar decisions we all make every day; but this one had quite atypical economic consequences......
.......To a lot of people, C is a dead language, and ${lang} is the language of the future, for ever-changing transient values of ${lang}. The reality of the situation is that all other languages today directly or indirectly sit on top of the Posix API and the NUL-terminated string of C.
When your Java, Python, Ruby, or Haskell program opens a file, its runtime environment passes the filename as a NUL-terminated string to open(3), and when it resolves queue.acm.org to an IP number, it passes the host name as a NUL-terminated string to getaddrinfo(3). As long as you keep doing that, you retain all the advantages when running your programs on a PDP/11, and all of the disadvantages if you run them on anything else.
I could write a straw man API proposal here, suggest representations, operations, and error-handling strategies, and I am quite certain that it would be a perfectly good waste of a nice afternoon. Experience shows that such proposals go nowhere because backwards compatibility with the PDP/11 and the finite number of programs written are much more important than the ability to write the potentially infinite number of programs in the future in an efficient and secure way.
Thus, the costs of the Ken, Dennis, and Brian decision will keep accumulating, like the dust that over the centuries has almost buried the monuments of ancient Rome.
The Most Expensive One-byte Mistake
The Most Expensive One-byte Mistake
http://queue.acm.org/detail.cfm?id=2010365
This is typical of the way things go in general...
The worst method is invariably the one that`s used, over and over.
Example:
The cost of roads in any country is enormous. Enough to bankrupt Rome.
After WWII most countries should have built a rail transit system, not roads.
If the nations of the world could cooperate... Build a "World Class" rail system.
But it`s this way because people who make the decisions want things this way.
It benefits them and they won`t allow it to be changed. Follow the money.!
Examine most any inequity at all, and you`ll find that someone`s profiting from it.
The worst method is invariably the one that`s used, over and over.
Example:
The cost of roads in any country is enormous. Enough to bankrupt Rome.
After WWII most countries should have built a rail transit system, not roads.
If the nations of the world could cooperate... Build a "World Class" rail system.
But it`s this way because people who make the decisions want things this way.
It benefits them and they won`t allow it to be changed. Follow the money.!
Examine most any inequity at all, and you`ll find that someone`s profiting from it.
-
- Posts: 15
- Joined: Sat 28 Aug 2010, 14:37
Good points... With improvements must come changes to the way things are done.
A rail system would make commerce and product delivery "hands free".
Meaning that the semi truck drivers would all loose their jobs in a capitalist economy.
It doesn`t have to be that way, but we all know the reality of it is not good for average citizens.
Simply stated... In an advanced rational society the people are taken care of.
They`re not cogs in the industrialist`s machinery or lab rats to experiment on.
A few nations do a fairly good job of providing for the welfare of it`s people.
All the other nations of the world it`s easily said are run by self serving monsters.
NOTE: Elected officials are not[/n] the ones running the show, they`re puppets.
It`s not speculation, it`s not an opinion, it`s not propaganda, it`s the truth!
A rail system would make commerce and product delivery "hands free".
Meaning that the semi truck drivers would all loose their jobs in a capitalist economy.
It doesn`t have to be that way, but we all know the reality of it is not good for average citizens.
Simply stated... In an advanced rational society the people are taken care of.
They`re not cogs in the industrialist`s machinery or lab rats to experiment on.
A few nations do a fairly good job of providing for the welfare of it`s people.
All the other nations of the world it`s easily said are run by self serving monsters.
NOTE: Elected officials are not[/n] the ones running the show, they`re puppets.
It`s not speculation, it`s not an opinion, it`s not propaganda, it`s the truth!