Re: C ethics question
- From: Richard Heathfield <rjh@xxxxxxxxxxxxxxx>
- Date: Sat, 31 Mar 2007 11:26:12 +0000
Servé Laurijssen said:
Recently, I found myself in the following situation:
There is library software written in C which declares some externals
like:
struct METER m1;
struct METER m2;
[...]
static void OnChangemeter(struct METER *m)
{
if (m == &m1) ...
if (m == &m2) ...
}
Now the comparison of these pointers is UB in C
Why?
--
Richard Heathfield
"Usenet is a strange place" - dmr 29/7/1999
http://www.cpax.org.uk
email: rjh at the above domain, - www.
.
- References:
- C ethics question
- From: Servé Laurijssen
- C ethics question
- Prev by Date: Re: Visual C++ support of C99 by using "C++ mode" (/TP)
- Next by Date: Re: C99 library part of C++ TR1
- Previous by thread: Re: C ethics question
- Next by thread: Re: C ethics question
- Index(es):