From: Pascal Costanza
Subject: X#
Date: 
Message-ID: <6toeb5Fbjeu1U1@mid.individual.net>
LOL: http://www.xsharp.org/samples/

-- 
My website: http://p-cos.net
Common Lisp Document Repository: http://cdr.eurolisp.org
Closer to MOP & ContextL: http://common-lisp.net/project/closer/

From: jimka
Subject: Re: X#
Date: 
Message-ID: <34a35aac-dfd5-4687-8646-40f75858e27e@v5g2000pre.googlegroups.com>
hi pascal, i'm not so familiar with xml, but is it sounds like all we
need now is a DTD
which introduces s-expression syntax.   so i could write


<with-sexp>
(xsp:append-child target="document('smtp://smtp.gmail.com')"
    (mail subject="Report" ··········@gmail.com"
·············@xsharp.org"
        (contents
            (body Contents go here)
            (file name="report.xls"
                (xsp:with
                    (xsp:context
                        (workbook
                            (sheet name="My Report"
                                (row
                                    (cell Name)
                                    (cell Earnings)
                                    (cell Quarter))
                                (row
                                    (cell John Doe)
                                    (cell 900873.44)
                                    (cell Q1)))))
                    (xsp:execute select="/library/excel/pi
('export')"))))))
</with-sexp>

--- RATHER THAN ---


 <xsp:append-child target="document('smtp://smtp.gmail.com')">
     <mail subject="Report" ··········@gmail.com"
·············@xsharp.org">
         <contents>
             <body>Contents go here</body>
             <file name="report.xls">
                 <xsp:with>
                     <xsp:context>
                         <workbook>
                             <sheet name="My Report">
                                 <row>
                                     <cell>Name</cell>
                                     <cell>Earnings</cell>
                                     <cell>Quarter</cell>
                                 </row>
                                 <row>
                                     <cell>John Doe</cell>
                                     <cell>900873.44</cell>
                                     <cell>Q1</cell>
                                 </row>
                             </sheet>
                         </workbook>
                     </xsp:context>
                     <xsp:execute select="/library/excel/pi('export')"/
>
                 </xsp:with>
             </file>
         </contents>
     </mail>
 </xsp:append-child>





On 21 Jan, 12:13, Pascal Costanza <····@p-cos.net> wrote:
> LOL:http://www.xsharp.org/samples/
>
> --
> My website:http://p-cos.net
> Common Lisp Document Repository:http://cdr.eurolisp.org
> Closer to MOP & ContextL:http://common-lisp.net/project/closer/
From: ······@corporate-world.lisp.de
Subject: Re: X#
Date: 
Message-ID: <11d684ca-6ba6-43e5-b227-26af0c46f759@r36g2000prf.googlegroups.com>
On 21 Jan., 12:13, Pascal Costanza <····@p-cos.net> wrote:
> LOL:http://www.xsharp.org/samples/
>
> --
> My website:http://p-cos.net
> Common Lisp Document Repository:http://cdr.eurolisp.org
> Closer to MOP & ContextL:http://common-lisp.net/project/closer/

As a Lisper we should not laugh about s-expression syntax, even if it
is
in XML form. ;-) It may come back to us...

We should also not stay on the surface, but try to
get the ideas behind the surface. Actually I found it interesting.

http://www.codeglide.com/xsharp/

The description how easy it makes everything is marketing speech.

But it trys to define some primitive actions (select, append, remove,
update) to exchange symbolic descriptions, to find descriptions for
items,
yo update them and to remove them.

So we have:

* using symbolic expressions in programs to represent data and code
  and a bunch of primitive actions

Look at the mail sending example.

* there are lots of objects and we can query the system for those
  this if for example how frame systems work, typical
  interfaces were tell and ask. TELL 'tells' the system a fact,
  ASK retrieves them with a query language.

  For example if the system knows about mail servers, I would
  ask for the mail server frame, if there is none, I would
  create one.

* now we have one. We need to create a mail.
  We can for example create a mail by creating
  a symbolic description of the mail.

  (:mail :sender joswig :recipient costanza
         :subject "X#, look again"
         :message ("hi there, look again at the examples"
                   :attachment joswig.vcard))

* now we send the mail. Typically one would call a send mail function.
  (send-mail mail server)
  but the interface could also look different

  (push-item server.queue mail)

  and a if-added-daemon on the mail-queue would send
  the thing.
From: Pascal Costanza
Subject: Re: X#
Date: 
Message-ID: <6tp2ooFc31s7U1@mid.individual.net>
······@corporate-world.lisp.de wrote:
> On 21 Jan., 12:13, Pascal Costanza <····@p-cos.net> wrote:
>> LOL:http://www.xsharp.org/samples/
>>
>> --
>> My website:http://p-cos.net
>> Common Lisp Document Repository:http://cdr.eurolisp.org
>> Closer to MOP & ContextL:http://common-lisp.net/project/closer/
> 
> As a Lisper we should not laugh about s-expression syntax, even if it
> is
> in XML form. ;-) It may come back to us...

Sure.

It just reminded me too much of this:

http://web.archive.org/web/20061209210228/http://homepages.inf.ed.ac.uk/wadler/language.pdf

;)


Pascal


-- 
My website: http://p-cos.net
Common Lisp Document Repository: http://cdr.eurolisp.org
Closer to MOP & ContextL: http://common-lisp.net/project/closer/
From: ······@corporate-world.lisp.de
Subject: Re: X#
Date: 
Message-ID: <49007328-3a5a-42a0-a8cd-fcde7e2e57dc@a39g2000prl.googlegroups.com>
On 21 Jan., 18:02, Pascal Costanza <····@p-cos.net> wrote:
> ······@corporate-world.lisp.de wrote:
> > On 21 Jan., 12:13, Pascal Costanza <····@p-cos.net> wrote:
> >> LOL:http://www.xsharp.org/samples/
>
> >> --
> >> My website:http://p-cos.net
> >> Common Lisp Document Repository:http://cdr.eurolisp.org
> >> Closer to MOP & ContextL:http://common-lisp.net/project/closer/
>
> > As a Lisper we should not laugh about s-expression syntax, even if it
> > is
> > in XML form. ;-) It may come back to us...
>
> Sure.
>
> It just reminded me too much of this:
>
> http://web.archive.org/web/20061209210228/http://homepages.inf.ed.ac....

Haha, right.

> ;)
>
> Pascal
>
> --
> My website:http://p-cos.net
> Common Lisp Document Repository:http://cdr.eurolisp.org
> Closer to MOP & ContextL:http://common-lisp.net/project/closer/
From: GP lisper
Subject: Re: X#
Date: 
Message-ID: <slrngnenef.i4.spambait@phoenix.clouddancer.com>
On Wed, 21 Jan 2009 18:02:16 +0100, <··@p-cos.net> wrote:
>
> It just reminded me too much of this:
>
> http://web.archive.org/web/20061209210228/http://homepages.inf.ed.ac.uk/wadler/language.pdf


Except the X# samples are not trivial multiplies.

------------------------------------------------------------------
Retrieve all RSS Feeds from NY Times and save those entries containing the word oil in a MySQL database titled oil_news:
<xsp:append-child target="document('xdbc:mysql://192.168.1.27:3306/maindb')/oil_news">  
    <xsp:for-each select="(document('http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml')/text() >> /library/xml/pi('import'))/channel/item[contains(title,'oil')]">  
        <row>  
            <title><xsp:text value="{title}"/></title>  
            <description><xsp:text value="{description}"/></description>  
            <link><xsp:text value="{link}"/></link>  
        </row>  
    </xsp:for-each>  
</xsp:append-child>  
------------------------------------------------------------------

Where is the _shorter_ lispy version?


-- 
"Most programmers use this on-line documentation nearly all of the
time, and thereby avoid the need to handle bulky manuals and perform
the translation from barbarous tongues."  CMU CL User Manual
From: Kaz Kylheku
Subject: Re: X#
Date: 
Message-ID: <20090127091841.606@gmail.com>
On 2009-01-21, GP lisper <········@CloudDancer.com> wrote:
> On Wed, 21 Jan 2009 18:02:16 +0100, <··@p-cos.net> wrote:
>>
>> It just reminded me too much of this:
>>
>> http://web.archive.org/web/20061209210228/http://homepages.inf.ed.ac.uk/wadler/language.pdf
>
>
> Except the X# samples are not trivial multiplies.
>
> ------------------------------------------------------------------
> Retrieve all RSS Feeds from NY Times and save those entries containing the word oil in a MySQL database titled oil_news:
><xsp:append-child target="document('xdbc:mysql://192.168.1.27:3306/maindb')/oil_news">  
>     <xsp:for-each select="(document('http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml')/text() >> /library/xml/pi('import'))/channel/item[contains(title,'oil')]">  
>         <row>  
>             <title><xsp:text value="{title}"/></title>  
>             <description><xsp:text value="{description}"/></description>  
>             <link><xsp:text value="{link}"/></link>  
>         </row>  
>     </xsp:for-each>  
></xsp:append-child>  
> ------------------------------------------------------------------
>
> Where is the _shorter_ lispy version?

I'm bating my breath for w_a_x_man's Ruby. :)
From: GP lisper
Subject: Re: X#
Date: 
Message-ID: <slrngnfciv.25g.spambait@phoenix.clouddancer.com>
On Wed, 21 Jan 2009 21:26:49 +0000 (UTC), <········@gmail.com> wrote:
>
>
> On 2009-01-21, GP lisper <········@CloudDancer.com> wrote:
>> On Wed, 21 Jan 2009 18:02:16 +0100, <··@p-cos.net> wrote:
>>>
>>> It just reminded me too much of this:
>>>
>>> http://web.archive.org/web/20061209210228/http://homepages.inf.ed.ac.uk/wadler/language.pdf
>>
>>
>> Except the X# samples are not trivial multiplies.
>>
>> ------------------------------------------------------------------
>> Retrieve all RSS Feeds from NY Times and save those entries containing the word oil in a MySQL database titled oil_news:
>><xsp:append-child target="document('xdbc:mysql://192.168.1.27:3306/maindb')/oil_news">  
>>     <xsp:for-each select="(document('http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml')/text() >> /library/xml/pi('import'))/channel/item[contains(title,'oil')]">  
>>         <row>  
>>             <title><xsp:text value="{title}"/></title>  
>>             <description><xsp:text value="{description}"/></description>  
>>             <link><xsp:text value="{link}"/></link>  
>>         </row>  
>>     </xsp:for-each>  
>></xsp:append-child>  
>> ------------------------------------------------------------------
>>
>> Where is the _shorter_ lispy version?
>
> I'm bating my breath for w_a_x_man's Ruby. :)

KF'ed awhile ago.

Actually, the number of lines of code isn't important.  I'd happily
take pages in order to avoid learning
'yet-another-new-world-shaking-system' that will be dead in a few
months.


-- 
"Most programmers use this on-line documentation nearly all of the
time, and thereby avoid the need to handle bulky manuals and perform
the translation from barbarous tongues."  CMU CL User Manual
From: J Kenneth King
Subject: Re: X#
Date: 
Message-ID: <85hc3shdyo.fsf@dozer.localdomain>
Pascal Costanza <··@p-cos.net> writes:

> LOL: http://www.xsharp.org/samples/

"Why did you do it?"

"Because we can."
From: Didier Verna
Subject: Re: X#
Date: 
Message-ID: <muxd4eg1xiv.fsf@uzeb.lrde.epita.fr>
J Kenneth King <·····@agentultra.com> wrote:

> Pascal Costanza <··@p-cos.net> writes:
>
>> LOL: http://www.xsharp.org/samples/
>
> "Why did you do it?"
>
> "Because we can."

  Yes we can !!

-- 
Resistance is futile. You will be jazzimilated.

Scientific site:   http://www.lrde.epita.fr/~didier
Music (Jazz) site: http://www.didierverna.com

EPITA/LRDE, 14-16 rue Voltaire, 94276 Le Kremlin-Bic�tre, France
Tel. +33 (0)1 44 08 01 85       Fax. +33 (0)1 53 14 59 22
From: Alexander Lehmann
Subject: Re: X#
Date: 
Message-ID: <gl71s2$o1b$1@online.de>
Pascal Costanza wrote:
> LOL: http://www.xsharp.org/samples/

Plus: "Since there are no functions to learn and everything is done intuitively,
even inexperienced developers can create complex Web applications and services
in record time." ;-)
From: Majorinc Kazimir
Subject: Re: X#
Date: 
Message-ID: <gl737m$6lu$1@ss408.t-com.hr>
Design of the site is excellent. Especially the
superhero on the bottom of the page.
From: Espen Vestre
Subject: Re: X#
Date: 
Message-ID: <m11vuwluno.fsf@vestre.net>
Pascal Costanza <··@p-cos.net> writes:

> LOL: http://www.xsharp.org/samples/

I'm still trying to figure out whether this is irony or not.
-- 
  (espen)
From: Joost Diepenmaat
Subject: Re: X#
Date: 
Message-ID: <87wscor6zo.fsf@zeekat.nl>
Pascal Costanza <··@p-cos.net> writes:

> LOL: http://www.xsharp.org/samples/

That's amazing. But not in a good way.

-- 
Joost Diepenmaat | blog: http://joost.zeekat.nl/ | work: http://zeekat.nl/
From: GP lisper
Subject: Re: X#
Date: 
Message-ID: <slrngnen11.i4.spambait@phoenix.clouddancer.com>
On Wed, 21 Jan 2009 16:52:59 +0100, <·····@zeekat.nl> wrote:
> Pascal Costanza <··@p-cos.net> writes:
>
>> LOL: http://www.xsharp.org/samples/
>
> That's amazing. But not in a good way.


Well, I looked at the samples, saw something I wanted and thought
about my prior attempt to create an RSS listener in lisp.  I'm
downloading X# to look it over now.  A lisp wrapper might do it.
From: Xah Lee
Subject: which language has syntax that visually represent a tree? [was X#]
Date: 
Message-ID: <258b8081-9265-4c47-b23a-132e0ff696c0@r37g2000prr.googlegroups.com>
syntax that represent a tree purely [was X#]

On Jan 21, 3:13 am, Pascal Costanza <····@p-cos.net> wrote:
> LOL: http://www.xsharp.org/samples/

Today, i was nosing about some blogs, which made me come to:
http://blog.fogus.me/2009/02/06/yegge-clojure-arc-and-lolita-or-days-of-future-past

in which he wrote: «Now I’m not a LISP expert, but it seems to me that
the S-Expression is generally regarded as the canonical representation
of the LISP AST (and many other languages for that matter). That is,
the LISP syntax is as close to an AST as one can get. Perhaps the
presence of macros, #, `, ‘, and , muddy the waters a bit, but not
much.»

that is technically not true. Although you mentioned lisp syntax
irregularities like “# , ,@ '”, but in general this sentiment that
lisp has regular syntax, or that its syntax is closest to abstract
syntax tree, is perpetuating a myth.

Mathematica language's syntax, XML, and XML derived general purpose
languages (e.g. O:XML, X#), are in fact more regular and closest to a
pure tree representation of the abstract syntax tree.

For detail, see:

• Fundamental Problems of Lisp
  http://xahlee.org/UnixResource_dir/writ/lisp_problems.html
  (the first section; on syntax irregularity)

• The Concepts and Confusions of Prefix, Infix, Postfix and Fully
Nested Notations
  http://xahlee.org/UnixResource_dir/writ/notations.html

also note, nesting matching delimiters is not the only way to
represent a tree. Indentation, such as used in Python or ascii-picture
tree used to represent directories and sub dirs and files, is another
form, arguably has more clarity than nesting with delimiters. As far
as i known, there were a couple such proposal/spec/library with
working implementation of this syntax that works for Scheme lisp.

in general, the question is what are ways to represent a tree
structure visually using text. The lisp, Mathematica approach is
nesting matching pairs. Ascii-picture approch is using lines to
represent a tree node and indentation to represent their level.
(python's syntax borrows this idea, however not in a pure form, in the
sense that the source code's visual representation does not correspond
to python's AST, far from it)

Note here, one of the important aspect here is VISUALLY. Because
otherwise any syntax is abstract syntax tree by definition. This
criterion can be formalized mathematically, by saying that the parser
for such a syntax should be very simple as having just one heuristics
that is based on recursion. (i dont have expertise in parsing, but in
parser jargon, i think there are simple terms to describe this class
of syntax, something like: its lexical grammar can be parsed by
parsing expression grammar)

Another important aspect here is that the source code of lang with
such syntax also needs to remain human readable and practically usable
for programers to type conveniently. This is the reason, lisp has few
irregular syntax introduced. Mathematica, take the approach of a layer
of syntax on top of the regular. This in my opinion has 2 major
advantages: A: the regularity of the syntax is unadulterated. B:
arbitrary shorter, traditional, or algebraic syntax can be introduced.
This is also why, python's syntax isn't a pure representation of its
abstract syntax tree, else, to code “print 3+4*5” becomes:

 print
  +
   3
   *
    4
    5

As for XML derived languages, the problem of verbosity and nesting
largely remains. The practiced solution seems to head towards a
specialized editor so that programers work on the editor's simpler
representation instead of the source code. (e.g. much of MathML, and
conversely Microsoft Word with its XML file format)

  Xah
∑ http://xahlee.org/

☄