bug-make
[Top][All Lists]
Advanced

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

Re: Tail call elimination


From: Kevin R. Bulgrien
Subject: Re: Tail call elimination
Date: Thu, 21 May 2020 11:40:26 -0500 (CDT)

> I plan to bow out of this discussion as I'm not vested in it, but, a
> distinguishing significant functional or interpretive difference
> between these two forms is not self-evident:
> 
> 1)
> 
>    FILE_SIZES := 5 2 1 4
>    TOTAL :- $(math +, $(FILE_SIZES))
> 
> 2)
> 
>   FILE_SIZES := 5 2 1 4
>   TOTAL :- $(+ $(FILE_SIZES))
> 
> In my mind, TOTAL obviously ends up with the same value, but, 1) is
> more readable in the same way that almost any language is more
> readable than perl with all its non-alpha shortcuts.

And I forgot to add that large vocabulary sets can be off-putting
(think FORTH which you either HATE or LOVE with little in between).
For one, think documentation, and how much easier it would be to
edit the existing list of functions and see a list of operators
documented in one funcction location.  It could be easier to
jump to $(math ) in help and see relevant details listed
together rather than in separate function definitions
$(+ ), $(/ ), $(^ ), $(* ), etc.

Of course these could be all in their own "grouping" in the manual,
but again, sometimes using existing structures is better when
possible, particularly as we tend to know that people kind of
love to code new things and not spend as much effort on the
documentation.  In this case, I do concede, however, that a
manual section called "Math", or whatever, could be a good
thing if this ever comes to fruition.

Oh, and yes, I think simple integer math in make is very
intriguing as I routinely use make for implementing
recipes that do all sorts of things that presently
require shell code to keep thing readable.



reply via email to

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