m4-discuss
[Top][All Lists]
Advanced

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

Re: How to patsubst the result of an include?


From: Stepan Kasal
Subject: Re: How to patsubst the result of an include?
Date: Wed, 2 Feb 2005 11:11:23 +0100
User-agent: Mutt/1.4.1i

Hello.

On Mon, Jan 31, 2005 at 10:02:35PM -0800, Matthew Braithwaite wrote:
> 
>   patsubst(`include(`file')',`searchstring',`replacement')
...
> (What I want is a macro that expands to a pattern substitution run
> over the contents of a given file.)

It seems to be as simple as

    patsubst(include(`file'),`searchstring',`replacement')

so it fully expands the contents of `file', then does the substitution,
and then expands the result again.

I hope your definitions are simple enough so that you don't mind the
second expansion.

Have a nice day,
        Stepan Kasal




reply via email to

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