OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help



   Re: [xml-dev] Using The Principle of Least Power As A Razor

[ Lists Home | Date Index | Thread Index ]
  • To: Rick Marshall <rjm@zenucom.com>
  • Subject: Re: [xml-dev] Using The Principle of Least Power As A Razor
  • From: bryan rasmussen <rasmussen.bryan@gmail.com>
  • Date: Thu, 16 Feb 2006 10:59:55 +0100
  • Cc: "Bullard, Claude L (Len)" <len.bullard@intergraph.com>, XML Developers List <xml-dev@lists.xml.org>
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=mYx8bca2u+U2761elbpDs7sEYvX7+c3U+1YH6qvEIL1FJnKW85jlaoi4lBIr+sD3ba1far+UCLg0on+gQFYyDAtGf7TOK/x84Ccs/PoKAYv4GPhhpgDSdZR970gqG7qVP8nI+2HIcr0b8+37zlMeoBJANtK7X3OO+KX2jD7nWLU=
  • In-reply-to: <43F3FC2E.4080407@zenucom.com>
  • References: <15725CF6AFE2F34DB8A5B4770B7334EE0BB1FDC5@hq1.ingr-corp.com> <43F3FC2E.4080407@zenucom.com>

> 1. a is more powerful than b if it cannot be mapped directly to >machine code (ie compiled)

Is the "it" in this sentence referring to a or b? Because it seems
that it could not be referring to a, but in all your other examples it
refers to a.

The thing here is that, well

1. I would suppose anything that can be interpreted can theoretically
be compiled, especially if we were to allow a source to source
compilation (I know that you do not allow that but given that most
source to source is to C and C can obviously be compiled it seems
reasonable to me).

2. if you're just discussing languages that have actual compilers then
you seem to mean that XSLT is more powerful than C. This is somewhat
opposed to normal usage of the term power.

> 2. a is more powerful than b if contains more concepts

What if it contains different concepts?

> 3. a is more powerful than b if it requires less typing

Okay, I would say as follows:

1. Any language that is not Turing Complete will not be more powerful
than any language that is Turing Complete.

2. Turing completeness is generally not the most important aspect for
determining power. What is more important is connection to the
computing environment it is contained in.

Connections to the computing environment is determined by inputs and outputs.

1. Determination of power for inputs would be a formula of the number
of possible input streams callable from within the language multiplied
by the number of possible input formats.

2. Determination of power for outputs would be a formula of the number
of possible output streams generated from within the language
multiplied by the number of possible output formats.

3. Can one from within the language do an output such a way that it
feeds into an input, the example would be to open a port, send data
out from the port, and read data in. How many various ways can these
connections between outputs and inputs be managed.

4. Can processes of inputs and outputs be run parallel.

These things can be used to determine relative disproportion of power
between languages, and of course also when languages are relatively
proportionate in power. I'm sure there could be other factors, but
lets run with these for now.

Outputs and input streams could be in reference to such things as:
files from the filesystem, manipulation of various protocols, opening
ports directly, connection to the underlying operating system.

Output and input formats could be in reference to such things as
encoding and so forth. Are formats normalized in some way before being
passed to the program, or are they accessable in their raw state. 
XSLT 1.0 can be seen to have more powerful output possibilities than
it has input possibilities where formats are concerned, otherwise
less. I haven't determined which is more important.

The rest of the factors mentioned earlier are not what would be
considered as power, but ease of controlling the power.

The principle of least power as I understand it is that one should use
the less powerful language so as to limit the chance of screwing
something up.

Obviously using these factors Assembler and C are basically equally
powerful, which goes along with the old saying that C gives you all
the power of Assembler with all the ease of use of Assembler.

Bryan Rasmussen


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS