mirror of
https://github.com/boostorg/python.git
synced 2026-01-19 16:32:16 +00:00
Compare commits
12 Commits
boost-1.78
...
actions
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ada99f4687 | ||
|
|
c3c6f7065d | ||
|
|
0474de0f6c | ||
|
|
6c3f3ecacf | ||
|
|
47d5bc76f6 | ||
|
|
508da1d198 | ||
|
|
271bcea8bf | ||
|
|
fdd3e8b2c1 | ||
|
|
a218babc8d | ||
|
|
41e208ecb5 | ||
|
|
f028aa4076 | ||
|
|
a060d43bf2 |
2
.github/workflows/deploy-documentation.yml
vendored
2
.github/workflows/deploy-documentation.yml
vendored
@@ -1,6 +1,6 @@
|
||||
name: deploy documentation
|
||||
|
||||
on: [push, pull_request]
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
|
||||
6
.github/workflows/test-osx.yml
vendored
6
.github/workflows/test-osx.yml
vendored
@@ -9,14 +9,14 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: [3.6]
|
||||
python-version: ['3.10']
|
||||
cxx: [clang++]
|
||||
std: [c++98, c++11, c++14] # TODO: c++17 is failing !
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v4
|
||||
- name: setup python
|
||||
uses: actions/setup-python@v2
|
||||
uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: setup prerequisites
|
||||
|
||||
18
.github/workflows/test-windows.yml
vendored
18
.github/workflows/test-windows.yml
vendored
@@ -15,16 +15,26 @@ jobs:
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- uses: microsoft/setup-msbuild@v1.1
|
||||
- name: setup boost prerequisites
|
||||
uses: lukka/run-vcpkg@v6
|
||||
with:
|
||||
vcpkgGitCommitId: '8a9a97315aefb3f8bc5d81bf66ca0025938b9c91'
|
||||
vcpkgGitCommitId: '88b1071e39f13b632644d9d953738d345a4ac055'
|
||||
vcpkgDirectory: '${{ runner.workspace }}/vcpkg'
|
||||
vcpkgTriplet: x64-windows
|
||||
vcpkgArguments: boost-config boost-core boost-function boost-graph boost-iterator boost-lexical-cast boost-mpl boost-preprocessor boost-smart-ptr boost-static-assert boost-align
|
||||
|
||||
vcpkgArguments: >
|
||||
boost-config
|
||||
boost-core
|
||||
boost-function
|
||||
boost-graph
|
||||
boost-iterator
|
||||
boost-lexical-cast
|
||||
boost-mpl
|
||||
boost-preprocessor
|
||||
boost-smart-ptr
|
||||
boost-static-assert
|
||||
boost-align
|
||||
- name: setup faber
|
||||
#shell: 'bash'
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
python -m pip install setuptools faber numpy
|
||||
|
||||
@@ -59,7 +59,7 @@ call_method(PyObject* self, char const* name
|
||||
)
|
||||
{
|
||||
PyObject* const result =
|
||||
PyEval_CallMethod(
|
||||
PyObject_CallMethod(
|
||||
self
|
||||
, const_cast<char*>(name)
|
||||
, const_cast<char*>("(" BOOST_PP_REPEAT_1ST(N, BOOST_PYTHON_FIXED, "O") ")")
|
||||
|
||||
@@ -57,9 +57,15 @@
|
||||
****************************************************************************/
|
||||
|
||||
// backwards compatibility:
|
||||
#ifdef BOOST_PYTHON_STATIC_LIB
|
||||
# define BOOST_PYTHON_STATIC_LINK
|
||||
# elif !defined(BOOST_PYTHON_DYNAMIC_LIB)
|
||||
#if defined(BOOST_PYTHON_STATIC_LINK) && !defined(BOOST_PYTHON_STATIC_LIB)
|
||||
# define BOOST_PYTHON_STATIC_LIB
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_PYTHON_DYNAMIC_LINK) && !defined(BOOST_PYTHON_DYNAMIC_LIB)
|
||||
# define BOOST_PYTHON_DYNAMIC_LIB
|
||||
#endif
|
||||
|
||||
#if !defined(BOOST_PYTHON_STATIC_LIB) && !defined(BOOST_PYTHON_DYNAMIC_LIB)
|
||||
# define BOOST_PYTHON_DYNAMIC_LIB
|
||||
#endif
|
||||
|
||||
|
||||
@@ -109,8 +109,8 @@ object BOOST_PYTHON_DECL exec_file(char const *filename, object global, object l
|
||||
PyObject *fo = Py_BuildValue("s", f);
|
||||
PyObject *fb = Py_None;
|
||||
PyUnicode_FSConverter(fo, &fb);
|
||||
f = PyBytes_AsString(fb);
|
||||
FILE *fs = fopen(f, "r");
|
||||
char *f_as_uft = PyBytes_AsString(fb);
|
||||
FILE *fs = fopen(f_as_uft, "r");
|
||||
Py_DECREF(fo);
|
||||
Py_DECREF(fb);
|
||||
#elif PY_VERSION_HEX >= 0x03000000
|
||||
@@ -129,6 +129,7 @@ object BOOST_PYTHON_DECL exec_file(char const *filename, object global, object l
|
||||
f,
|
||||
Py_file_input,
|
||||
global.ptr(), local.ptr());
|
||||
fclose(fs);
|
||||
if (!result) throw_error_already_set();
|
||||
return object(detail::new_reference(result));
|
||||
}
|
||||
|
||||
@@ -98,7 +98,13 @@ python::detail::new_reference dtype::convert(object const & arg, bool align)
|
||||
return python::detail::new_reference(reinterpret_cast<PyObject*>(obj));
|
||||
}
|
||||
|
||||
int dtype::get_itemsize() const { return reinterpret_cast<PyArray_Descr*>(ptr())->elsize;}
|
||||
int dtype::get_itemsize() const {
|
||||
#if NPY_ABI_VERSION < 0x02000000
|
||||
return reinterpret_cast<PyArray_Descr*>(ptr())->elsize;
|
||||
#else
|
||||
return PyDataType_ELSIZE(reinterpret_cast<PyArray_Descr*>(ptr()));
|
||||
#endif
|
||||
}
|
||||
|
||||
bool equivalent(dtype const & a, dtype const & b) {
|
||||
// On Windows x64, the behaviour described on
|
||||
|
||||
@@ -113,7 +113,6 @@ static PyTypeObject enum_type_object = {
|
||||
#if PY_VERSION_HEX < 0x03000000
|
||||
| Py_TPFLAGS_CHECKTYPES
|
||||
#endif
|
||||
| Py_TPFLAGS_HAVE_GC
|
||||
| Py_TPFLAGS_BASETYPE, /* tp_flags */
|
||||
0, /* tp_doc */
|
||||
0, /* tp_traverse */
|
||||
|
||||
Reference in New Issue
Block a user