bug-make
[Top][All Lists]
Advanced

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

Re: Unexpected failure in tricky use of eval


From: Eldar Abusalimov
Subject: Re: Unexpected failure in tricky use of eval
Date: Sat, 12 May 2012 18:41:24 +0400

Stefano,

This is a bug, and it has been described and fixed here: https://savannah.gnu.org/patch/?7534


2012/5/12 Stefano Lattarini <address@hidden>
Hello.

While trying to implement a kind of memoization of lazy macros in GNU make
(needed for my work on Automake-NG), I've been encountering some strange
failure in GNU make (present in all of 3.80, 3.81, 3.82).  Here is the
minimal reproducer I've been able to find:

   mufoofoo = \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx \
     xxxxxxxxxxxx
   var = $(eval var := $$(mufoofoo))$(var)
   dummy:
       : $(firstword $(var))

Running the above, make dies with the following message:

 Makefile:13: *** unterminated variable reference.  Stop.

And any of the following minimal and *apparently irrelevant* changes to the
Makefile above that cause the error to disappear:

 - changing 'var' with 'va' everywhere
 - changing 'mufoofoo' with 'mfoofoo'
 - removing *just one 'x'* from the value of mufoofoo

Any idea of what's going on here?

Regards,
 Stefano

_______________________________________________
Bug-make mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/bug-make



--
Best regards,
Eldar Sh. Abusalimov

reply via email to

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