Don't include wx/utils.h from wx/vector.h.
This will allow to include wx/vector.h from wx/list.h which is itself included from wx/utils.h by breaking this circular dependency. Don't use wxMin(), defined in wx/utils.h, in order to do this. See #14814. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73002 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -28,7 +28,6 @@ inline void wxVectorSort(wxVector<T>& v)
|
|||||||
|
|
||||||
#else // !wxUSE_STD_CONTAINERS
|
#else // !wxUSE_STD_CONTAINERS
|
||||||
|
|
||||||
#include "wx/utils.h"
|
|
||||||
#include "wx/scopeguard.h"
|
#include "wx/scopeguard.h"
|
||||||
#include "wx/meta/movable.h"
|
#include "wx/meta/movable.h"
|
||||||
#include "wx/meta/if.h"
|
#include "wx/meta/if.h"
|
||||||
@@ -245,7 +244,9 @@ public:
|
|||||||
// NB: casts to size_type are needed to suppress mingw32 warnings about
|
// NB: casts to size_type are needed to suppress mingw32 warnings about
|
||||||
// mixing enums and ints in the same expression
|
// mixing enums and ints in the same expression
|
||||||
const size_type increment = m_size > 0
|
const size_type increment = m_size > 0
|
||||||
? wxMin(m_size, (size_type)ALLOC_MAX_SIZE)
|
? m_size < ALLOC_MAX_SIZE
|
||||||
|
? m_size
|
||||||
|
: ALLOC_MAX_SIZE
|
||||||
: (size_type)ALLOC_INITIAL_SIZE;
|
: (size_type)ALLOC_INITIAL_SIZE;
|
||||||
if ( m_capacity + increment > n )
|
if ( m_capacity + increment > n )
|
||||||
n = m_capacity + increment;
|
n = m_capacity + increment;
|
||||||
|
Reference in New Issue
Block a user