WTF

Started by
20 comments, last by Lifepower 19 years, 4 months ago
Delphi was never alive. Geeks.
Advertisement
Quote:Original post by Anonymous Poster
Delphi was never alive. Geeks.


How amusing.

Quote:As long as there are still people programming in Delphi, it will not die and I happen to know quite a few people who still use it as their only IDE/compiler.


I'm one of them ;)
And aslong as people like me use Borland C Builder, Delphi won't die as it is the backbone that makes C Builder more powerful than all MS compilers.
Beer - the love catalystgood ol' homepage
I seriously doubt thats the main reason though. However from a business/industry standpoint it is an encouraging point. However, there is more to Object Pascal developers than meerly that. And it is something that I find that is sorely underestimated in the past and to this day.
This is a slightly modified version of

Top 10 reasons why Pascal is better than C

found at:
http://www.pascal-central.com/top10.html

Top 10 reasons why Pascal/Delphi is better than C

1. Delphi, noble language as it is, was named after the famous ancient Greek oracle Delphi. C was named after a Sesame Street character.

2. Pascal's inventor, Nicholas Wirth, and parameter passing conventions coalesce to form a nifty pun: You can pronounce his name by reference: Wirth or by value: Worth. C was invented at Bell Labs, where they wouldn't know a joke from a transistor.

3. There is only one Pascal, as defined by Wirth, while C has (shall we say?) several fathers: Kernighan & Ritchie, Harbison & Steele, Barnum & Bailey, and Laurel & Hardy.

4. In C, the following variable names are all different: thesame, TheSame, theSame, and THESAME. Nuff said.

5. In Pascal, when you fool with a pointer or handle, you know you're fooling around with a pointer or handle. In C, you could be fooling around with anything. C is the ultimate language for computational promiscuity.

6. In Pascal, we *know* how big an integer is.

7. C is used by liberal, Democratic, Mike Dukakis types of programmers. Delphi/Pascal is a favorite of the GOP. Hey, we know what the big language at Berkeley is, don't we?

8. C is the only language in the civilized world that still refuses to recognize the $ sign for a hexadecimal constant and continues to promote that base pretender to the throne: 0x00.

9. Delphi/Pascal has well-defined rules for Scope, while C appears to be using Listerine. This accounts for the medicine breath of many C programmers.

10. In C, you can do this:
for(;P("\n").R-;P("|"))for(e=3DC;e-;P("_"+(*u++/8)%2))P("| "+(*u/4)%2);
In Pascal, you CAN'T do this :
for(;P("\n").R-;P("|"))for(e=3DC;e-;P("_"+(*u++/8)%2))P("| "+(*u/4)%2);

Hey! I like Listerine. Half of your 'Top 10' reasons are petty, ridiculus statements. 1-5. Every language has a purpose (sorta), and you use the one that best fits your needs. The topic of this thread was "Delphi is Dead?" (WTF actually), not language A is better than language B.
The topic of this thread was rediculous, as well as some (most) of its content. Also, speaking of "Top 10 reasons" mentioned above, I must agree with anonymous poster that half of them are really stupid. Still, C++ is more popular due to commercial stuff but as a language even though powerful, I think it has significant drawbacks for developing large applications. My major complaint is the case sensitiveness which leads to ambiguity in code (hard to understand), allows ambiguous statements like "if (a = b)" which leads to run-time errors that are difficult to find. On the other hand, Pascal language was designed to be more didactic language - to explain the user *what is going on* in the code and this makes it more suitable for big applications where a lot of people are involved. I believe both languages can be used to create exactly THE SAME thing (in the contrary to what Anonymous poster said) and if used correctly, both languages provide a good way of developing applications.
Still, I don't know if it's just me, but most C/C++ code I have seen on the Internet, including the one provided by Sun Microsystems and others (for instance, communication-related standards from ITU) - is very bad written. No or useless comments, one or two letter variables (e.g. "a, b, t, zZ, ae, gj, ...etc") and number constants integrated in the code (like "if (a>31) ja=jb+44;" -> here, what 31 and 44 mean?!) and hardly packed code makes very BAD example of C/C++ usage. So in general, my critics towards C/C++ languages usually goes to the programmers rather than to the language itself. The reason for that, I think is because there are much more C/C++ inexperienced users (compared to Pascal) due to the same commercial stuff. These users can be teachers or employees dedicated to mathematics or physics that do not have enough knowledge of writing good programs so the source code made by them is just a bunch of equations resolving some sort of problem completely wired.
As an example, I invite you to take the sources of well known OGG Vorbis file format. I've just grabbed the source, opened a random file and saw this part of code:
while(i<n){    int j,k=map;    unsigned long pi=46341; /* 2**-.5 in 0.16 */    unsigned long qi=46341;    int qexp=0,shift;    long wi=vorbis_coslook_i(k*65536/ln);    qi*=labs(ilsp[0]-wi);    pi*=labs(ilsp[1]-wi);    for(j=3;j<m;j+=2){      if(!(shift=MLOOP_1[(pi|qi)>>25]))	if(!(shift=MLOOP_2[(pi|qi)>>19]))	  shift=MLOOP_3[(pi|qi)>>16];      qi=(qi>>shift)*labs(ilsp[j-1]-wi);      pi=(pi>>shift)*labs(ilsp[j]-wi);      qexp+=shift; } 

This code from Ogg Vorvis source illustrates each part of the critics I specified before. If you want something more convincing, here is a code from "g72x.c", a product of Sun Microsystems, which also has all the problems mentioned before:
if (tr == 1) {			/* reset a's and b's for modem signal */		state_ptr->a[0] = 0;		state_ptr->a[1] = 0;		state_ptr->b[0] = 0;		state_ptr->b[1] = 0;		state_ptr->b[2] = 0;		state_ptr->b[3] = 0;		state_ptr->b[4] = 0;		state_ptr->b[5] = 0;		a2p = 0 ;	} else {			/* update a's and b's */		pks1 = pk0 ^ state_ptr->pk[0];		/* UPA2 */		/* update predictor pole a[1] */		a2p = state_ptr->a[1] - (state_ptr->a[1] >> 7);		if (dqsez != 0) {			fa1 = (pks1) ? state_ptr->a[0] : -state_ptr->a[0];			if (fa1 < -8191)	/* a2p = function of fa1 */				a2p -= 0x100;			else if (fa1 > 8191)				a2p += 0xFF;			else				a2p += fa1 >> 5;			if (pk0 ^ state_ptr->pk[1])				/* LIMC */				if (a2p <= -12160)					a2p = -12288;				else if (a2p >= 12416)					a2p = 12288;				else					a2p -= 0x80;			else if (a2p <= -12416)				a2p = -12288;			else if (a2p >= 12160)				a2p = 12288;			else				a2p += 0x80;		}		/* TRIGB & DELAY */		state_ptr->a[1] = a2p;		/* UPA1 */		/* update predictor pole a[0] */		state_ptr->a[0] -= state_ptr->a[0] >> 8;		if (dqsez != 0)			if (pks1 == 0)				state_ptr->a[0] += 192;			else				state_ptr->a[0] -= 192;		/* LIMD */		a1ul = 15360 - a2p;		if (state_ptr->a[0] < -a1ul)			state_ptr->a[0] = -a1ul;		else if (state_ptr->a[0] > a1ul)			state_ptr->a[0] = a1ul;		/* UPB : update predictor zeros b[6] */		for (cnt = 0; cnt < 6; cnt++) {			if (code_size == 5)		/* for 40Kbps G.723 */				state_ptr->b[cnt] -= state_ptr->b[cnt] >> 9;			else			/* for G.721 and 24Kbps G.723 */				state_ptr->b[cnt] -= state_ptr->b[cnt] >> 8;			if (dq & 0x7FFF) {			/* XOR */				if ((dq ^ state_ptr->dq[cnt]) >= 0)					state_ptr->b[cnt] += 128;				else					state_ptr->b[cnt] -= 128;			}		}	}

I write all this because I hope that people finally decide to write better code (especially if they plan on releasing it to public) rather than flaming other languages (like "Top 10 reasons why Pascal is better than C"). If your handwriting is ugly it's not the pen - it's how you use it!

Edit: As an example, I also include the first part of C/C++ code translated to Pascal by our "C to Pascal compiler". In Pascal, the code is still hard to understand:
var pi: Longword; qi: Longword; qexp: Longint; shift: Longint; wi: Longint;begin pi:= 46341; qi:= 46341; qexp:= 0; wi:= vorbis_coslook_i(k * 65536 div ln); qi:= qi * labs(ilsp[0] - wi); pi:= pi * labs(ilsp[1] - wi); j:= 3; while (j < m) do  begin   shift:= MLOOP_1[(pi or qi) shr 25];   if (shift <> 0) then    begin     shift:= MLOOP_2[(pi or qi) shr 19];     if (shift <> 0) then      shift:= MLOOP_3[(pi or qi) shr 16];    end;   qi:= (qi shr shift) * labs(ilsp[j - 1] - wi);   pi:= (pi shr shift) * labs(ilsp[j] - wi);   qexp:= qexp + (shift);   j:= j + 2;  end; // while (c++ for)
Delphi is more than alive fools!

:)

As long as I'm around, there will be at least 1 Delphi/Pascal user.
I ask for help and you give me a book? I hate book. Book is stupid.Also known as Yellow at the Dark Basic forums.
I wish Borland would make C++ Builder 7.
Author Freeworld3Dhttp://www.freeworld3d.org
Quote:Original post by Basic
Delphi is more than alive fools!

:)

As long as I'm around, there will be at least 1 Delphi/Pascal user.


Another one is me! You're not alone!

This topic is closed to new replies.

Advertisement