Thread overview | |||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
November 15, 2020 [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
What do we mean when we say that one programming language is "more expressive" than another? Is it just a matter of opinion and personal taste, or is there some underlying objective truth? And is more expressiveness necessarily a good thing? Based on a 1991 paper by Matthias Felleisen, this presentation by Shriram Krishnamurthi is an accessible and easy-to-digest introduction to some of the programming-language theory that goes into answering the above questions. If you have even a passing interest in programming-language design, it's well worth your time to give this a watch. https://www.youtube.com/watch?v=43XaZEn2aLc |
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Paul Backus | On Sunday, 15 November 2020 at 01:01:09 UTC, Paul Backus wrote:
> What do we mean when we say that one programming language is "more expressive" than another? Is it just a matter of opinion and personal taste, or is there some underlying objective truth? And is more expressiveness necessarily a good thing?
I am not sure what is meant by expressiveness in general.
For instance, Rust seems to be the first and only language where the lifetime of objects in memory can be expressed at compile time. Is Rust expressive or not?
|
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dibyendu Majumdar | On Sunday, 15 November 2020 at 01:40:08 UTC, Dibyendu Majumdar wrote:
> I am not sure what is meant by expressiveness in general.
>
> For instance, Rust seems to be the first and only language where the lifetime of objects in memory can be expressed at compile time. Is Rust expressive or not?
Expressive compared to what? I think pretty much everyone would agree that Rust is more expressive than, say, Brainfuck, but some would probably argue that it is less expressive than Lisp.
Of course, that's a rather hand-wavy explanation. If you want to understand how this kind of intuitive sense of relative expressiveness can be modeled mathematically, that's what the linked presentation is all about. :)
|
November 14, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Paul Backus | On 11/14/20 6:01 PM, Paul Backus wrote:
> What do we mean when we say that one programming language is "more expressive" than another? Is it just a matter of opinion and personal taste, or is there some underlying objective truth? And is more expressiveness necessarily a good thing?
>
> Based on a 1991 paper by Matthias Felleisen, this presentation by Shriram Krishnamurthi is an accessible and easy-to-digest introduction to some of the programming-language theory that goes into answering the above questions. If you have even a passing interest in programming-language design, it's well worth your time to give this a watch.
>
> https://www.youtube.com/watch?v=43XaZEn2aLc
I quite enjoyed watching this, thank you.
|
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Dibyendu Majumdar | On 15.11.20 02:40, Dibyendu Majumdar wrote: > Rust seems to be the first and only language where the lifetime of objects in memory can be expressed at compile time. It only seems that way because it is the first and only one that was marketed to you. http://web.cs.ucla.edu/~palsberg/tba/papers/tofte-talpin-iandc97.pdf In programming languages, theory is quite far ahead of and detached from practice. I would be surprised to find any type theory concept that is less than 20 years old in any popular language. |
November 14, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Paul Backus | On Sun, Nov 15, 2020 at 01:55:49AM +0000, Paul Backus via Digitalmars-d wrote: [...] > Expressive compared to what? I think pretty much everyone would agree that Rust is more expressive than, say, Brainfuck, but some would probably argue that it is less expressive than Lisp. [...] By what are you measuring expressiveness here? Mathematically speaking, BF has the same expressiveness as Lisp, and Lisp has the same expressiveness as D: they are all Turing-complete. I have not seen a *mathematical* definition of expressiveness that would measure these languages differently. OTOH, if by expressiveness you mean conciseness of expressing common computations, then you can probably argue BF is the least expressive of them all, since you need to write a LOT of BF just to express what can probably be expressed in a few lines of D; and Lisp is probably somewhere up there above D. But that would require that you define what you mean by "common", and that's where you'll get into a tarpit because reasonable people will disagree on what exactly constitutes a "common computation". Also, trying to find the "most expressive" language in terms of conciseness is futile task, because that's equivalent to finding a language whose constructs let you express any computation in the shortest form possible, and this can be reduced to finding the optimal compression algorithm. But finding the optimal compression algorithm is equivalent to the halting problem, which is unsolvable. T -- It only takes one twig to burn down a forest. |
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Paul Backus Attachments:
| Paul, On Sun, 2020-11-15 at 01:01 +0000, Paul Backus via Digitalmars-d wrote: > What do we mean when we say that one programming language is "more expressive" than another? Is it just a matter of opinion and personal taste, or is there some underlying objective truth? And is more expressiveness necessarily a good thing? […] I'd say it is a matter of personal prejudice, so most likely different for each individual. Where two people agree on the "expressiveness" of different programming languages, you have the beginnings of a clique. -- Russel. =========================================== Dr Russel Winder t: +44 20 7585 2200 41 Buckmaster Road m: +44 7770 465 077 London SW11 1EN, UK w: www.russel.org.uk |
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Russel Winder | On Sunday, 15 November 2020 at 12:31:15 UTC, Russel Winder wrote:
> Paul,
>
> On Sun, 2020-11-15 at 01:01 +0000, Paul Backus via Digitalmars-d wrote:
>> What do we mean when we say that one programming language is "more expressive" than another? Is it just a matter of opinion and personal taste, or is there some underlying objective truth? And is more expressiveness necessarily a good thing?
> […]
>
> I'd say it is a matter of personal prejudice, so most likely different for each individual.
>
> Where two people agree on the "expressiveness" of different programming languages, you have the beginnings of a clique.
I completely agree.
Also different languages express different things better - and that was my point about Rust being expressive in a particular scenario.
|
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to H. S. Teoh | On Sunday, 15 November 2020 at 06:36:16 UTC, H. S. Teoh wrote:
> On Sun, Nov 15, 2020 at 01:55:49AM +0000, Paul Backus via Digitalmars-d wrote: [...]
>> Expressive compared to what? I think pretty much everyone would agree that Rust is more expressive than, say, Brainfuck, but some would probably argue that it is less expressive than Lisp.
> [...]
>
> By what are you measuring expressiveness here? Mathematically speaking, BF has the same expressiveness as Lisp, and Lisp has the same expressiveness as D: they are all Turing-complete. I have not seen a *mathematical* definition of expressiveness that would measure these languages differently.
Then you haven't watched the talk. :)
|
November 15, 2020 Re: [OT] On the Expressive Power of Programming Languages | ||||
---|---|---|---|---|
| ||||
Posted in reply to Russel Winder | On Sunday, 15 November 2020 at 12:31:15 UTC, Russel Winder wrote:
> I'd say it is a matter of personal prejudice, so most likely different for each individual.
>
> Where two people agree on the "expressiveness" of different programming languages, you have the beginnings of a clique.
What if I told you there's a way to mathematically formalize the idea of "expressiveness" while preserving many of our intuitions about which programming languages are more expressive than others?
Are you curious? If so, watch the talk--it's all in there. :)
|
Copyright © 1999-2021 by the D Language Foundation