Skip to content

Commit 25945a8

Browse files
committed
Add pybind11/compat/README.txt and a couple source code comments.
1 parent 4e45a46 commit 25945a8

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

include/pybind11/compat/README.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
NOTE
2+
----
3+
4+
The C++ code here
5+
6+
** only depends on <Python.h> **
7+
8+
and nothing else.
9+
10+
DO NOT ADD CODE WITH OTHER EXTERNAL DEPENDENCIES TO THIS DIRECTORY.

include/pybind11/compat/pybind11_platform_abi_id.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22

33
// Copyright (c) 2024 The pybind Community.
44

5+
// To maximize portability:
6+
// DO NOT ADD CODE THAT REQUIRES C++ EXCEPTION HANDLING.
7+
58
#include "wrap_include_python_h.h"
69

710
// Implementation detail. DO NOT USE ELSEWHERE.

include/pybind11/compat/wrap_include_python_h.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
// the standard headers on some systems, you must include Python.h before
1313
// any standard headers are included.
1414

15+
// To maximize portability:
16+
// DO NOT ADD CODE THAT REQUIRES C++ EXCEPTION HANDLING.
17+
1518
// Disable linking to pythonX_d.lib on Windows in debug mode.
1619
#if defined(_MSC_VER) && defined(_DEBUG) && !defined(Py_DEBUG)
1720
// Workaround for a VS 2022 issue.

0 commit comments

Comments
 (0)