This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
adding __COUNTER__ to gcc
- From: olenz <lenz dot oron at gmail dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Sat, 16 Sep 2006 12:26:33 -0700 (PDT)
- Subject: adding __COUNTER__ to gcc
Hi,
I was trying to add __COUNTER__ support to the gcc compiler but my
implementation (same as __LINE__) is not good for pre compiled headers.
any idea how to implement this? one optiion is to add a global variable to
each program, initialized to 0, and to replace the __COUNTER__ with
something like (myGlobal++). any idea how do i add such a global varibale
and use it later?
Thanks,
Oron.
--
View this message in context: http://www.nabble.com/adding-__COUNTER__-to-gcc-tf2283398.html#a6343128
Sent from the gcc - patches forum at Nabble.com.