Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions include/pybind11/pybind11.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,15 @@
*/

#pragma once

// See Issue #5956. This fixes compilation failure with MSVC 17.12 (v14.44) and C++20:
// '_BACKUP_ITERATOR_DEBUG_LEVEL' undeclared when including span header from STL.
#if defined(_MSC_VER)
# ifndef _BACKUP_ITERATOR_DEBUG_LEVEL
# define _BACKUP_ITERATOR_DEBUG_LEVEL 0
# endif
#endif

#include "detail/class.h"
#include "detail/dynamic_raw_ptr_cast_if_possible.h"
#include "detail/exception_translation.h"
Expand Down
Loading