Many of our daemons (and a few non-daemon tools) contain a a particular
parse.y parser for their domain-specific-languages.

This is how variables work in that parser.  This is kind of like a
historical mistake that would be hard to repair, because everytime we
looked into changing the way it works (by moving the expansion to a different
stage) it would break other user patterns.

Jordan Geoghegan <jor...@geoghegan.ca> wrote:

> Hello,
> 
> I was playing around with my bgpd.conf and I noticed some interesting
> behaviour with macros.
> 
> A quick example:
> 
> # This parses fine:
> IP1="192.0.2.1"
> MYIP=$IP1
> 
> # This throws a syntax error:
> ASN1="65001"
> MYASN=$ASN1
> 
> # This also parses fine:
> ASN1="65001a"
> MYASN=$ASN1
> 
> In short, it appears that having a numerical value for macro2=$macro1
> breaks something in the config parser, or at the very least the
> behaviour is undocumented.
> 
> Any insight or advice would be much appreciated.
> 
> Regards,
> 
> Jordan
> 
> 
> 
> 

Reply via email to