Hacker News new | past | comments | ask | show | jobs | submit login

I doubt it. Natural language agglutination tends to have all kinds of nasty side effects, modifying the letters at the boundary, which makes parsing hard and therefore would have created problems writing a decent parser in the early days. COBOL famously tried to follow English syntax, but most other languages deviate from it. Look at early languages such as RPG or SNOBOL. They follow the machine instruction set much more closely than the English grammar.

But look at your smalltalk example: does that look like English syntax? First, the word order is wrong, and second, "onTopOf" already is a concatenation. It doesn't really support the idea that your native language shapes your programming.




> Natural language agglutination tends to have all kinds of nasty side effects …

Oh, sure; morphophonological processes do tend to mess up everything. (This is why Valentine doesn’t give a morpheme-by-morpheme gloss of the example I included.) This is why I don’t claim that such a programming language will be _exactly_ like human agglutination — only that it will have a very different structure to our languages. The complexities of human languages will always need to be simplified and regularised in order to create a programming language.

> But look at your smalltalk example: does that look like English syntax? First, the word order is wrong, and second, "onTopOf" already is a concatenation.

I agree that Smalltalk syntax doesn’t look at all like English syntax, at least in terms of word order. (If anything, it looks a lot more like Burmese.) And it is true that early languages like RPG and SNOBOL — and I should include assembly here as well — have little to do with any human language. But that’s not the central component of my claim. What’s important here is that, for most if not all modern programming languages, you can construct a syntax tree, like this:

        ┌────────┴─────────┐
        │            ┌─────┴────┐
     ┌──┴──┐         │       ┌──┴──┐
    you lieDown; position: (table onTopOf)
This is a very English-like trait, in that English sentences also consist of isolated words organised in a syntax tree:

        ┌───┴───┐
        │    ┌──┴───┐
     ┌──┴─┐  │   ┌──┴──┐
    Lie down on the table
This structure is of course common crosslinguistically, but agglutinative and polysynthetic languages such as Cree are structured differently. In these languages, words are composed of a stem, surrounded by affixes expressing their relationships to other words. e.g. Koasati verbs (which are reasonably straightforward in this regard) have the following structure (Kimball 1985):

    incorporated.noun - directional - instrumental - distributive - indirect.object - direct.object - specific.locative - general.locative - 1A.prefixes - STEM - adverb - diminutive - intention - ability - mood - deduction - modality - dubitative - hearsay - auditory - tense - consequence - sent.func = enclitics
Due to this extensive marking, word order is extremely free; in many languages with this amount of marking, words within a sentence may be arranged in pretty much any order. Though linguists can still draw out syntax trees for these languages, it is unclear to what extent such an abstraction is useful: the affixes within a word have a rigid and non-hierarchical order, while the words themselves have few constraints on ordering. This is a characteristic unlike all programming languages I am aware of, and is what I refer to when I say that programming languages today are more like English and French than they are like Cree and Koasati.


This is a very interesting post, thanks for sharing. If you come across anything definitely give us an update




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: