lout-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Arguments before or after command?


From: Cedric Sodhi
Subject: Re: Arguments before or after command?
Date: Tue, 4 Sep 2012 19:12:18 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Sun, Sep 02, 2012 at 02:34:03PM +0200, Cedric Sodhi wrote:
> What doesn't quite seem to fit in with Lout being a clean, consistent
> language is how arguments are passed to @Commands . By which logic do
> commands take arguments { Before } @TheCommand or @TheCommand { And then
> the Argument } or even
> 
> @TheCommand { And then } { multiple } { Arguments } ?
> 
> Sadly, this reminds me a bit of the problems I had with Groff and
> especially LaTeX, where sometimes, there appears to be no rule for how
> commands are called. Could you shed a bit of light onto that? For
> example, why are not all commands constructed according to one syntax
> where @TheCommand {Is followed by one object of {possibly subgrouped}
> arguments} ?

Further, it appears there appears to be a distinction as to "named
arguments", which appear to be those in a syntax like

@ACommand @ANamedArgument { ValueOfArgument }

Which raises the question how to prevent clashes between the names of
"named arguments" and normal commands (for they same to share one
namespace). This seems to defy the principle of (named) arguments living
in the scope of the function, rather than the embedding scope (to allow
defining functions regardless of the environment in which those are
called).

Even further, why do we sometimes have @Something ... @EndSomething
(e.g. List) and sometimes @Something @Begin ... @End @Something
(e.g. Section)?

And even further, why do certain commands require their arguments to be
enclosed in braces? Naively, one would think that xyz and { xyz } are
the same thing (where in the latter the braces are redundant}, but many
arguments fail if their (one and only) arguments are not enclosed in
braces, for example

@SysInclude math

fails.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]