This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author mark.dickinson
Recipients amaury.forgeotdarc, eric.smith, mark.dickinson, pitrou, rhettinger, stutzbach
Date 2010-10-07.21:00:35
SpamBayes Score 8.675515e-05
Marked as misclassified No
Message-id <>
> Technically arbitrary relational comparisons of pointers are undefined,
> but in practice Antoine's assumptions here are very modest.

I disagree:  there's a very real practical danger here.  Namely, optimizing compilers are free to assume that code doesn't involve any undefined behaviour and optimize accordingly.  gcc for one is known to make extensive use of this freedom.  I wouldn't be at all surprised to find some current or future version of gcc optimizing an (p >= start_of_array) check to 'always true', on the basis that it *will* always be true in legal code.

Please don't introduce undefined behaviour here---it's asking for trouble.
Date User Action Args
2010-10-07 21:00:38mark.dickinsonsetrecipients: + mark.dickinson, rhettinger, amaury.forgeotdarc, pitrou, eric.smith, stutzbach
2010-10-07 21:00:38mark.dickinsonsetmessageid: <>
2010-10-07 21:00:36mark.dickinsonlinkissue10044 messages
2010-10-07 21:00:35mark.dickinsoncreate