Join Date: 10 2001
Blog Entries: 1
Uploads: 0Reputation: 110 | 5
YOU MUST READ IT !!!!
I aplogize to the administrator for this great article. But i think that programmers will be interested about it. I am also programmer in C++ and am very pleased to find such a interesting forum in the Arm NET
<BR>This came my way courtesy of a good friend of mine who spends alot of time<BR>doing ab inito mathematically modelling of complex systems.
If you are into conspiracies and conspriacy theories, you can tell me how<BR>plausible this is. As if anyone would make a language obtuse and difficult<BR>to use, in order to secure their own position. Can't believe it
On the 1st of January, 1998, Bjarne Stroustrup gave an interview to the <BR>IEEE's 'Computer' magazine.
Naturally, the editors thought he would be giving a retrospective view of <BR>seven years of object-oriented design, using the language he created.
By the end of the interview, the interviewer got more than he had <BR>bargained for and, subsequently, the editor decided to suppress its <BR>contents, 'for the good of the industry' but, as with many of these things, <BR>there was a leak.
Here is a complete transcript of what was said, unedited, and <BR>unrehearsed, so it isn't as neat as planned interviews.
You will find it interesting.
Interviewer: Well, it's been a few years since you changed the world of <BR>software design, how does it feel, looking back?
<BR>Stroustrup: Actually, I was thinking about those days, just before you <BR>arrived. Do you remember? Everyone was writing 'C' and, the trouble <BR>was, they were pretty damn good at it. Universities got pretty good at <BR>teaching it, too. They were turning out competent - I stress the word <BR>'competent' - graduates at a phenomenal rate. That's what caused the<BR> <BR>problem.
Stroustrup: Yes, problem. Remember when everyone wrote Cobol?
Interviewer: Of course, I did too
Stroustrup: Well, in the beginning, these guys were like demi-gods. <BR>Their salaries were high, and they were treated like royalty.
Interviewer: Those were the days, eh?
Stroustrup: Right. So what happened? IBM got sick of it, and invested <BR>millions in training programmers, till they were a dime a dozen.
Interviewer: That's why I got out. Salaries dropped within a year, to the <BR>point where being a journalist actually paid better.
Stroustrup: Exactly. Well, the same happened with 'C' programmers.
Interviewer: I see, but what's the point?
Stroustrup: Well, one day, when I was sitting in my office, I thought of <BR>this little scheme, which would redress the balance a little. I thought 'I <BR>wonder what would happen, if there were a language so complicated, so <BR>difficult to learn, that nobody would ever be able to swamp the market <BR>with programmers? Actually, I got some of the ideas from X10, you <BR>know, X windows. That was such a bitch of a graphics system, that it <BR>only just ran on those Sun 3/60 things. They had all the ingredients for <BR>what I wanted. A really ridiculously complex syntax, obscure functions, <BR>and pseudo-OO structure. Even now, nobody writes raw X-windows <BR>code. Motif is the only way to go if you want to retain your sanity..
Interviewer: You're kidding ?
Stroustrup: Not a bit of it. In fact, there was another problem. Unix was <BR>written in 'C', which meant that any 'C' programmer could very easily <BR>become a systems programmer. Remember what a mainframe systems <BR>programmer used to earn?
Interviewer: You bet I do, that's what I used to do.
Stroustrup: OK, so this new language had to divorce itself from Unix, <BR>by hiding all the system calls that bound the two together so nicely. This <BR>would enable guys who only knew about DOS to earn a decent living <BR>too.
Interviewer: I don't believe you said that.
Stroustrup: Well, it's been long enough, now, and I believe most people <BR>have figured out for themselves that C++ is a waste of time but, I must <BR>say, it's taken them a lot longer than I thought it would.
Interviewer: So how exactly did you do it?
Stroustrup: It was only supposed to be a joke, I never thought people <BR>would take the book seriously. Anyone with half a brain can see that <BR>object-oriented programming is counter-intuitive, illogical and <BR>inefficient.
Stroustrup: And as for 're-useable code' - when did you ever hear of a <BR>company re-using its code?
Interviewer: Well, never, actually, but.
Stroustrup: There you are then. Mind you, a few tried, in the days. <BR>There was this Oregon company - Mentor Graphics, I think they were <BR>called - really caught a cold trying to rewrite everything in C++ in about <BR>'90 or '91. I felt sorry for them really, but I thought people would learn <BR>from their mistakes.
Interviewer: Obviously, they didn't?
Stroustrup: Not in the slightest. Trouble is, most companies hush-up all <BR>their major blunders, and explaining a $30 million loss to the <BR>shareholders would have been difficult. Give them their due, though, <BR>they made it work in the end.
Interviewer: They did? Well, there you are then, it proves O-O works.
Stroustrup: Well, almost. The executable was so huge, it took five <BR>minutes to load, on an HP workstation, with 128MB of RAM. Then it <BR>ran like treacle. Actually, I thought this would be a major stumbling-<BR>block, and I'd get found out within a week, but nobody cared. Sun and <BR>HP were only too glad to sell enormously powerful boxes, with huge <BR>resources just to run trivial programs. You know, when we had our first <BR>C++ compiler, at AT&T, I compiled 'Hello World', and couldn't believe <BR>the size of the executable. 2.1MB
Interviewer: What? Well, compilers have come a long way, since then.
Stroustrup: They have? Try it on the latest version of C++ - you won't <BR>get much change out of half a megabyte. Also, there are several quite <BR>recent examples for you, from all over the world. British Telecom had a <BR>major disaster on their hands but, luckily, managed to scrap the whole <BR>thing and start again. They were luckier than Australian Telecom. Now <BR>I hear that Siemens is building a dinosaur, and getting more and more <BR>worried as the size of the hardware gets bigger, to accommodate the <BR>executables. Isn't multiple inheritance a joy?
Interviewer: Yes, but C++ is basically a sound language.
Stroustrup: You really believe that, don't you? Have you ever sat down <BR>and worked on a C++ project? Here's what happens: First, I've put in <BR>enough pitfalls to make sure that only the most trivial projects will work <BR>first time. Take operator overloading. At the end of the project, almost <BR>every module has it, usually, because guys feel they really should do it, <BR>as it was in their training course. The same operator then means <BR>something totally different in every module. Try pulling that lot <BR>together, when you have a hundred or so modules. And as for data <BR>hiding. God, I sometimes can't help laughing when I hear about the <BR>problems companies have making their modules talk to each other. I <BR>think the word 'synergistic' was specially invented to twist the knife in a <BR>project manager's ribs.
Interviewer: I have to say, I'm beginning to be quite appalled at all<BR>this. <BR>You say you did it to raise programmers' salaries? That's obscene.
Stroustrup: Not really. Everyone has a choice. I didn't expect the thing <BR>to get so much out of hand. Anyway, I basically succeeded. C++ is <BR>dying off now, but programmers still get high salaries - especially those <BR>poor devils who have to maintain all this crap. You do realise, it's <BR>impossible to maintain a large C++ software module if you didn't <BR>actually write it?
Interviewer: How come?
Stroustrup: You are out of touch, aren't you? Remember the typedef?
Interviewer: Yes, of course.
Stroustrup: Remember how long it took to grope through the header <BR>files only to find that 'RoofRaised' was a double precision number? <BR>Well, imagine how long it takes to find all the implicit typedefs in all the <BR>Classes in a major project.
Interviewer: So how do you reckon you've succeeded?
Stroustrup: Remember the length of the average-sized 'C' project? <BR>About 6 months. Not nearly long enough for a guy with a wife and kids <BR>to earn enough to have a decent standard of living. Take the same <BR>project, design it in C++ and what do you get? I'll tell you. One to two <BR>years. Isn't that great? All that job security, just through one mistake<BR>of <BR>judgement. And another thing. The universities haven't been teaching <BR>'C' for such a long time, there's now a shortage of decent 'C' <BR>programmers. Especially those who know anything about Unix systems <BR>programming. How many guys would know what to do with 'malloc', <BR>when they've used 'new' all these years - and never bothered to check the <BR>return code. In fact, most C++ programmers throw away their return <BR>codes. Whatever happened to good ol' '-1'? At least you knew you had <BR>an error, without bogging the thing down in all that 'throw' 'catch' 'try' <BR>stuff.
Interviewer: But, surely, inheritance does save a lot of time?
Stoustrup: Does it? Have you ever noticed the difference between 'C' <BR>project plan, and a C++ project plan? The planning stage for a C++ <BR>project is three times as long. Precisely to make sure that everything <BR>which should be inherited is, and what shouldn't isn't. Then, they still <BR>get it wrong. Whoever heard of memory leaks in a 'C' program? Now <BR>finding them is a major industry. Most companies give up, and send the <BR>product out, knowing it leaks like a sieve, simply to avoid the expense of <BR>tracking them all down.
Interviewer: There are tools.
Stroustrup: Most of which were written in C++.
Interviewer: If we publish this, you'll probably get lynched, you do <BR>realise that?
Stroustrup: I doubt it. As I said, C++ is way past its peak now, and no <BR>company in its right mind would start a C++ project without a pilot trial. <BR>That should convince them that it's the road to disaster. If not, they <BR>deserve all they get. You know, I tried to convince Dennis Ritchie to <BR>rewrite Unix in C++.
Interviewer: Oh my God. What did he say?
Stroustrup: Well, luckily, he has a good sense of humor. I think both he <BR>and Brian figured out what I was doing, in the early days, but never let <BR>on. He said he'd help me write a C++ version of DOS, if I was <BR>interested.
Interviewer: Were you?
Stroustrup: Actually, I did write DOS in C++, I'll give you a demo <BR>when we're through. I have it running on a Sparc 20 in the computer <BR>room. Goes like a rocket on 4 CPU's, and only takes up 70 megs of <BR>disk.
Interviewer: What's it like on a PC?
Stroustrup: Now you're kidding. Haven't you ever seen Windows '95? <BR>I think of that as my biggest success. Nearly blew the game before I was <BR>ready, though.
Interviewer: You know, that idea of a Unix++ has really got me <BR>thinking. Somewhere out there, there's a guy going to try it.
Stroustrup: Not after they read this interview.
Interviewer: I'm sorry, but I don't see us being able to publish any of <BR>this.
Stroustrup: But it's the story of the century. I only want to be <BR>remembered by my fellow programmers, for what I've done for them. <BR>You know how much a C++ guy can get these days?
Interviewer: Last I heard, a really top guy is worth $70 - $80 an hour.
Stroustrup: See? And I bet he earns it. Keeping track of all the gotchas <BR>I put into C++ is no easy job. And, as I said before, every C++ <BR>programmer feels bound by some mystic promise to use every damn <BR>element of the language on every project. Actually, that really annoys <BR>me sometimes, even though it serves my original purpose. I almost like <BR>the language after all this time.
Interviewer: You mean you didn't before?
Stroustrup: Hated it. It even looks clumsy, don't you agree? But when <BR>the book royalties started to come in... well, you get the picture.
Interviewer: Just a minute. What about references? You must admit, <BR>you improved on 'C' pointers.
Stroustrup: Hmm. I've always wondered about that. Originally, I <BR>thought I had. Then, one day I was discussing this with a guy who'd <BR>written C++ from the beginning. He said he could never remember <BR>whether hi
<BR>Forwarded from DC-STUFF [email protected] mailing list
Արատտայի ու Խալդեյի հովանավոր .