http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46488
--- Comment #30 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-11-30 10:15:02 UTC --- >From a quick look I can see that with -fstrict-aliasing we will never consider ptr->link.next to alias ptr->list.next (so if they are made to alias via casting the testcase is invalid). Which I can see here: brigade_move(apr_bucket_brigade *b, apr_bucket_brigade *a, apr_bucket *e) { apr_bucket *f; if (e != (struct apr_bucket *)((char *)(&(&(b)->list)->next) - ((long) (((char *) (&(((struct apr_bucket*)0)->link))) - ((char *) 0))))) (struct apr_bucket *)((char *)(&(&(b)->list)->next) does exactly this (would be nice to rewrite the testcase to use offsetof btw).