RE: [Dev-C++] #DEFINE versus cont variables in array inicializations
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Ioannis V. <iv...@te...> - 2003-05-30 19:24:30
|
> -----Original Message----- > From: Per Westermark [mailto:pw...@ia...] > Sent: Saturday, May 31, 2003 1:45 AM > To: Ioannis Vranos > Cc: Dev-C++ Mailing List > Subject: RE: [Dev-C++] #DEFINE versus cont variables in array > inicializations > > > If you try to compare the address of SIZE from two different > modules, you > will - I haven't tested for different compilers - probably > get a linker > error, since both object files will contain a _SIZE symbol. But that would be broken behaviour. So I do not think we will get a linker error. > But then again > - 'a const &int = <value>' is a complicated declaration just to get a > "magic" address to compare against. I do not understand the above. The compiler has to produce an address when we use that address, the same way that inline functons do have an address. Ioannis Vranos * Programming pages: http://www.noicys.freeurl.com * Alternative URL 1: http://run.to/noicys * Alternative URL 2: http://www.noicys.cjb.net |