Re: Ancient Philosophy And Programming Languages
by japhy (Canon) on May 01, 2004 at 14:23 UTC
|
Very interesting. I'm curious (and I'm being serious) if you have any thoughts as to how philosophers might have distinguished or defined in general terms the concepts of functional, imperative, procedural, etc. languages.
_____________________________________________________
Jeff [japhy]Pinyan:
Perl,
regex,
and perl
hacker, who'd like a job (NYC-area)
s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;
| [reply] |
|
|
| [reply] |
|
|
No rush. Philosophers didn't have all the answers right away either; they spent their time finding them.
As a starting point for you (and other readers), I direct you to WikiPedia's entry on programming paradigms, which lists, among others: structured, imperative, procedural, functional, object-oriented, and event-driven.
_____________________________________________________
Jeff [japhy]Pinyan:
Perl,
regex,
and perl
hacker, who'd like a job (NYC-area)
s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;
| [reply] |
|
|
| [reply] |
|
|
Though this isn't classical philosophy, you might look at some of the modern "analytic" philosophers who have thought a lot about language itself. For Wittgenstein, for example, words don't have any intrinsic meaning, but are just ways of getting something done, provoking a certain kind of reaction. If you are in a place where you don't understand the langage, but you see people saying "I'll take a cheeseburger" and getting cheeseburgers, you don't have to understand the words, you just have to be able to make the sounds to get the results you want in that particular situation.
You could compare this view of language (perhaps) to the "black box" in functional and OO programing. You don't need to know what a function "means", you just have to know when and how to use it to get the results you want.
| [reply] |
Re: Ancient Philosophy And Programming Languages
by biosysadmin (Deacon) on May 01, 2004 at 17:27 UTC
|
Cool meditation. My brain looks favorably upon ideas which merge concepts from different disciplines, such as molecular biology and computer science, evolution and algorithm development, or in this case philosophy and programming language design. This allows you to play interesting games with your mind by transferring concepts across disciplines and seeing how well they hold up. I think that the comparison Greek Philosophies goes very well.
One minor criticism though: I believe that your "Aristotilian" should be spelled "Aristotelean," that's the way I've always seen it in my logic and history books.
Good meditation though, I enjoyed reading it quite a bit. | [reply] |
|
|
| [reply] |
Re: Ancient Philosophy And Programming Languages
by weierophinney (Pilgrim) on May 01, 2004 at 18:44 UTC
|
And what do we make of the fact that a language such as Perl is written in C...? That would suggest that a pure Platonic language cannot exist without an Arisotelian world to build from. | [reply] |
|
|
I would reply like this and I may be wrong on this point. As long as the language is completely self-hosting, this should not be a problem. The language would be able to compile itself and avoid the whole problem. Now Perl may be a Platonic language run by an Arisotelian world because of its reliance on C.
| [reply] |
Re: Ancient Philosophy And Programming Languages
by jdporter (Paladin) on May 01, 2004 at 19:38 UTC
|
I would disagree with your classification of C/C++ as Aristotlean. Int, char, etc. are still just types. The fact that they're intrinsic in the language is of no importance here. An Aristotlean language would be one which does not have abstract types, at least for its "object" system. Of such languages, Self is perhaps the best example. In Self, you don't create an object of type X by instantiating an abstract definition of class X, you clone the prototype of X, which is itself a concrete object.
However, I would argue that no computer language is truly Aristotlean, because Aristotle's model does not (AFAIK) separate the representation from the behavior -- or, in procedural terms, the data from the code.
| [reply] |
|
|
Good point. That's actually the case for both philosophies. The major difference in ancient thought was that ideas already have their own independent existence in the world and that people "receive" them by getting in tune with the universe. The idea is identical to the thing.
Modern thought involves an internalization of ideas to humans, producing a split between things and ideas. Ideas are the domain of thought and things are "in the world". This distinction is necessary to do OO, as far as I can tell. Programming is at least at the abstraction level of Enlightenment thought. :)
| [reply] |
|
|
I disagree that the seperation between Mind and Body was an Enlightenment idea. I refer you to the beginning of discussion where Plato sets out his Theory of Forms (just hit the little blue arrow to get the rest of the discussion). He makes a clear distinction between what is thought and what is seen; in essence, between the Mind and the Body.
| [reply] |
|
|
|
|
|
|
Re: Ancient Philosophy And Programming Languages
by theon (Beadle) on May 01, 2004 at 18:00 UTC
|
Looks like you're not talking about C++ but C only. C++ has a string type, and you can easily have everything as an Object (just like Java does for int -> Integer). I'd say C++ has some Aristotilian characteristics because of the C compatibility, but what was added (real C++, not C-style C++) is far more Platonic oriented. Imho not a good example to illustrate your (interesting, btw :)) discussion. | [reply] |
|
|
The only reason that I added C++ to the list was because of its status as a super-set of C. This also illustrates the problem with Java nicely. Both C++ and Java have object structures but only Java requires an Object Oriented paradigm. C++ does not since it must support all of C. However, both languages have primitive data-types. I am still open to debate and discussion about how to seperate the types of languages.
| [reply] |
|
|
Well I think "types of languages" can not be strict, unless a language is crafted to follow one-and-only-one paradigm. If you have types of languages, some languages will perfectly fit one type, but others (particularly C++) may allow several paradigms, I wouldn't give them only one type.
Then, think of such examples : a Java program using only static members (or singletons) vs a good POO C++ program. The former is closer to C-style modules than the latter. And there are examples of OO C programs (glib/gtk).
It can be tricky. I think your categories apply to actual programs rather than languages. Then some languages are designed to provide one paradigm, so programs in this language will probably end up in only one of your categories, but not all of them (badly designed ones or other exceptions).
| [reply] |
|
|
|
|
|
|
|
Re: Ancient Philosophy And Programming Languages
by Jenda (Abbot) on May 03, 2004 at 14:45 UTC
|
If you try hard enough, anything may resemble anything else. Which is IMHO exactly what you just did.
Jenda
Current philosophy is what you got left when all sciences separated out.
| [reply] |
Re: Ancient Philosophy And Programming Languages
by etcshadow (Priest) on May 02, 2004 at 01:52 UTC
|
BrainF*ck: very Aristotilean (by your definition).
------------
:Wq
Not an editor command: Wq
| [reply] [d/l] |
Aristotle the Atomist?
by BorgCopyeditor (Friar) on May 06, 2004 at 04:09 UTC
|
While I wouldn't want to discourage the use of philosophy as a tool for meditating on the logical differences between programming languages, I can't help pointing out that there's a basic problem with your analogy: Aristotle (the ancient one, of course) was emphatically not an "atomist." He roundly criticized both Democritus and Leucippus.
BCE --Your punctuation skills are insufficient!
| [reply] |
|
|
Aristotle (the ancient one, of course) was emphatically not an "atomist." He roundly criticized both Democritus and Leucippus.
That is correct. Also, Aristotle more or less invented scientific taxonimy, like the system of phylla, genres, and species, which is probably closer to the true inspiration of the OO "description of the universe". From that standpoint, Aristotle would be "Platonic" too.
I however think that this is really a great topic, because it seems obvious (and significant) that programming languages are subtly based on traditional Western logic and ontology.
| [reply] |