Re: New Programming Language: Salmon

Kaz Kylheku <kaz@kylheku.com>
Thu, 3 Nov 2011 04:37:18 +0000 (UTC)

          From comp.compilers

Related articles
New Programming Language: Salmon chris@chriswilson.info (Chris) (2011-11-02)
Re: New Programming Language: Salmon kaz@kylheku.com (Kaz Kylheku) (2011-11-03)
Re: New Programming Language: Salmon chris@chriswilson.info (Chris) (2011-11-03)
| List of all articles for this month |
From: Kaz Kylheku <kaz@kylheku.com>
Newsgroups: comp.compilers
Date: Thu, 3 Nov 2011 04:37:18 +0000 (UTC)
Organization: A noiseless patient Spider
References: 11-11-016
Keywords: design
Posted-Date: 03 Nov 2011 15:48:16 EDT

On 2011-11-02, Chris <chris@chriswilson.info> wrote:
> I've created a new general purpose programming language and a full
> interpreter for it. I'm looking for early adopters to give it a try
> and give feedback.


I had a good look at your reference manual, etc.


My honest opinion is that you've created a fairly uninteresting 'blub'
language, with new syntax and terminology for doing pretty ordinary things.


For instance:


quarks: objects that enumerate and identify, such that two quarks are
either equal or unequal. New term for "symbol", with limitations.


tagalongs: your new term for "property lists" that can be attached to objects,
easily created with a couple of macros in Lisp and either weak hash tables
or finalizations (non-ANSI, but common extensions) to build the assocation
in a way that doesn't prevent garbage collection of unused objects.
In about 15 minutes of coding, I can make myself the syntax which supports
the following:


    (define-tagalong foo nil) ;; establish default value


    ;; associate some-object with 42 under the key 'foo
    (setf (get-tagalong some-object 'foo) 42)


    ;; retrieve it:
    (get-tagalong some-object 'foo)


    ;; retrieve unassigned tagalong
    (get-tagalong "string" 'foo) ;; yields nil, the default value


    ;; retrieve undeclared tatalong
    (get-tagalong "string" 'blah) ;; error: blah has no default value


    ;; shorthand macro
    (with-tagalongs (foo bar) some-object
        ;; now local symbols foo and bar alias for tagalongs 'foo and 'bar
        ;; of some-object


        (setf foo 42) ;; same as (setf (get-tagalong some-object 'foo) 42)
      )


    (do-tagalongs some-object (indicator value)
          ;; this body iterates over the key/value tagalog pairs of some-object
            )


You've bogged down tagalongs with the possiblity of static type declarations,
which don't really add much value; they are just ways to make the language
get in your way.


> I believe there's always room for new ideas,


Why don't you introduce Salmon on Rosetta Code and try implementing
a few of the tasks, so people can get some rough idea for how it stacks up
against numerous other languages?


In Rosetta, on the same page, people can see how a given task is solved in
Python, Lisp, SNOBOL 4 (!), Visual Basic, Salmon, C++, you name it.


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.