pre-processor string replacement
- From: sam_cit@xxxxxxxxxxx
- Date: 14 Jan 2007 00:00:20 -0800
Hi Everyone,
I have the following question regarding string replacement
pre-processor statement,
#define status "23"
#define status "44"
int main()
{
printf("%s\n", status);
}
this works fine and prints 44
where as
#define status "23"
#define status1 status
int main()
{
printf("%s\n", status);
}
prints 23, string replacement occurs on the pre-processor statement
itself, which is not in case 1, why is it so?
Can anyone help me on this?
.
- Follow-Ups:
- Re: pre-processor string replacement
- From: Richard Heathfield
- Re: pre-processor string replacement
- From: Ian Collins
- Re: pre-processor string replacement
- From: sam_cit
- Re: pre-processor string replacement
- Prev by Date: Re: Strange bit corruption in a double
- Next by Date: Re: pre-processor string replacement
- Previous by thread: Strange bit corruption in a double
- Next by thread: Re: pre-processor string replacement
- Index(es):
Relevant Pages
|