Re: [exim] expanding variables in macro name

Top Page
Delete this message
Reply to this message
Author: Artjom Gora
Date:  
To: exim-users
Subject: Re: [exim] expanding variables in macro name
Hello Ian,
Thank you for your reply.

I've tried to resolve expansions in such way but it still doesn't work
as expected.
After expansion Exim treats 'MACRO1' literally and doesn't look
what MACRO1 is defined for.

On Wed, Nov 24, 2010 at 12:35 PM, Ian Eiloart <iane@???> wrote:
>
>
> --On 23 November 2010 19:54:57 +0200 Artjom Gora <dr.tibibo@???>
> wrote:
>
>> Hello, exim-users!
>> Is there are any possibility to expand an arbitrary variable into the
>> macro name?
>> For instance, Ihave several macros defined lke this
>> MACRO1=some data
>> MACRO2=another data
>> MACRO3=some other data
>>
>> then have acl like this
>>
>> warn set acl_c1 = ${some expansion}
>>
>> where acl_c1={1..3}
>>
>> Can  I  use my macros in the follow way?
>>
>> MACRO${acl_c1}
>
> I think that won't work, because MACRO expansions occur first. Why not have
> the expansion resolve to MACRO1, MACRO2, or MACRO3?
>
>
> --
> Ian Eiloart
> IT Services, University of Sussex
> 01273-873148 x3148
> For new support requests, see http://www.sussex.ac.uk/its/help/
>
>
>