Better and more correct comment.
This commit is contained in:
parent
2bdbfd334b
commit
1020d56934
@ -47,14 +47,20 @@ Created 9/5/1995 Heikki Tuuri
|
|||||||
#include "ha_prototypes.h"
|
#include "ha_prototypes.h"
|
||||||
#include "my_cpu.h"
|
#include "my_cpu.h"
|
||||||
|
|
||||||
/* There is a bug in Visual Studio 2010
|
/* There is a bug in Visual Studio 2010.
|
||||||
Visual Studio has a feature "Checked Iterators". In a debug build, every
|
Visual Studio has a feature "Checked Iterators". In a debug build, every
|
||||||
iterator operation is checked at runtime for errors, e g, out of range.
|
iterator operation is checked at runtime for errors, e.g., out of range.
|
||||||
|
Because of bug there is runtime error on following code
|
||||||
|
for (std::vector<sync_level_t>::iterator it = array->elems.begin(); it !=
|
||||||
|
array->elems.end(); ++it) and runtime check fails on comparison
|
||||||
|
it != array->elems.end() that is correct and standard way to do end
|
||||||
|
of range comparison.
|
||||||
Disable this "Checked Iterators" for Windows and Debug if defined.
|
Disable this "Checked Iterators" for Windows and Debug if defined.
|
||||||
*/
|
*/
|
||||||
#ifdef UNIV_DEBUG
|
#ifdef UNIV_DEBUG
|
||||||
#ifdef __WIN__
|
#ifdef __WIN__
|
||||||
#ifdef _ITERATOR_DEBUG_LEVEL
|
#ifdef _ITERATOR_DEBUG_LEVEL
|
||||||
|
#undef _ITERATOR_DEBUG_LEVEL
|
||||||
#define _ITERATOR_DEBUG_LEVEL 0
|
#define _ITERATOR_DEBUG_LEVEL 0
|
||||||
#endif /* _ITERATOR_DEBUG_LEVEL */
|
#endif /* _ITERATOR_DEBUG_LEVEL */
|
||||||
#endif /* __WIN__*/
|
#endif /* __WIN__*/
|
||||||
|
@ -48,14 +48,20 @@ Created 9/5/1995 Heikki Tuuri
|
|||||||
#include "ha_prototypes.h"
|
#include "ha_prototypes.h"
|
||||||
#include "my_cpu.h"
|
#include "my_cpu.h"
|
||||||
|
|
||||||
/* There is a bug in Visual Studio 2010
|
/* There is a bug in Visual Studio 2010.
|
||||||
Visual Studio has a feature "Checked Iterators". In a debug build, every
|
Visual Studio has a feature "Checked Iterators". In a debug build, every
|
||||||
iterator operation is checked at runtime for errors, e g, out of range.
|
iterator operation is checked at runtime for errors, e.g., out of range.
|
||||||
|
Because of bug there is runtime error on following code
|
||||||
|
for (std::vector<sync_level_t>::iterator it = array->elems.begin(); it !=
|
||||||
|
array->elems.end(); ++it) and runtime check fails on comparison
|
||||||
|
it != array->elems.end() that is correct and standard way to do end
|
||||||
|
of range comparison.
|
||||||
Disable this "Checked Iterators" for Windows and Debug if defined.
|
Disable this "Checked Iterators" for Windows and Debug if defined.
|
||||||
*/
|
*/
|
||||||
#ifdef UNIV_DEBUG
|
#ifdef UNIV_DEBUG
|
||||||
#ifdef __WIN__
|
#ifdef __WIN__
|
||||||
#ifdef _ITERATOR_DEBUG_LEVEL
|
#ifdef _ITERATOR_DEBUG_LEVEL
|
||||||
|
#undef _ITERATOR_DEBUG_LEVEL
|
||||||
#define _ITERATOR_DEBUG_LEVEL 0
|
#define _ITERATOR_DEBUG_LEVEL 0
|
||||||
#endif /* _ITERATOR_DEBUG_LEVEL */
|
#endif /* _ITERATOR_DEBUG_LEVEL */
|
||||||
#endif /* __WIN__*/
|
#endif /* __WIN__*/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user