Re: An interesting observation that emerged at lunch

On Thu, Feb 11, 2016 at 4:14 PM, Henry S. Thompson <ht@inf.ed.ac.uk> wrote:
> ht writes:
>
>>   2) New ones: XProc language port variables, bound with various arrows.
>
> If we thought about (2) as naming pipes, not ports, then we might think
> of changing
>
>   $in -> xinclude() >> $temp
>   $temp >> "included.xml"

While the existing syntax in the proposal has the nice property that
we use one syntax with the exception that @1, @2, etc. is used for
output ports in blocks.   I'm not particular happy wth that oddity nor
the use of the at-sign.

>
> to something a little clearer. We call 'temp' a *pipe name*,
> and write the above this way
>
>   $in -> xinclude() >> @temp
>   $temp >> @"included.xml"
>
> where $temp is the name for the downstream end of the pipe named
> 'temp' and @temp is the name for its upstream end.

We could make this idea work and then have a consistent story for the
right-hand side of the append operator for ordinal output ports (i.e.,
@1, @2, etc.)

$in is always an input port
@in is always an output port.

We do fix up by matching inputs and outputs.

>
> We can go on to play with the characters, and where they go:
>
>   in$ -> xinclude() >> @temp
>   temp$ >> @"included.xml"

No, I don't think in$ is going to be acceptable.  I certainly don't like it.

>
> or even
>
>   in> -> xinclude() >> >temp
>   temp> >> >"included.xml"

That looks difficult to parse by humans.

>
> At which point either the -> or the > is redundant:
>
>   in> xinclude() >temp
>   temp>  >"included.xml"

We considered that ... It looks odd to me.

>
> or
>
>   in-> xinclude() >>temp
>   temp->  >>"included.xml"
>

That won't parse as '-' is part of the name syntax.

-- 
--Alex Miłowski
"The excellence of grammar as a guide is proportional to the paucity of the
inflexions, i.e. to the degree of analysis effected by the language
considered."

Bertrand Russell in a footnote of Principles of Mathematics

Received on Thursday, 11 February 2016 16:51:57 UTC