Skip to content

Commit f4afc53

Browse files
tiranzooba
andauthored
bpo-45893: Add missing extern C to initconfig.h (GH-29761)
Co-authored-by: Steve Dower <steve.dower@python.org>
1 parent d71c7bc commit f4afc53

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ jobs:
9595
runs-on: windows-latest
9696
needs: check_source
9797
if: needs.check_source.outputs.run_tests == 'true'
98+
env:
99+
IncludeUwp: 'true'
98100
steps:
99101
- uses: actions/checkout@v2
100102
- name: Build CPython
@@ -109,6 +111,8 @@ jobs:
109111
runs-on: windows-latest
110112
needs: check_source
111113
if: needs.check_source.outputs.run_tests == 'true'
114+
env:
115+
IncludeUwp: 'true'
112116
steps:
113117
- uses: actions/checkout@v2
114118
- name: Register MSVC problem matcher

Include/cpython/initconfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
#ifndef Py_PYCORECONFIG_H
22
#define Py_PYCORECONFIG_H
33
#ifndef Py_LIMITED_API
4+
#ifdef __cplusplus
5+
extern "C" {
6+
#endif
47

58
/* --- PyStatus ----------------------------------------------- */
69

@@ -243,5 +246,8 @@ PyAPI_FUNC(PyStatus) PyConfig_SetWideStringList(PyConfig *config,
243246
See also PyConfig.orig_argv. */
244247
PyAPI_FUNC(void) Py_GetArgcArgv(int *argc, wchar_t ***argv);
245248

249+
#ifdef __cplusplus
250+
}
251+
#endif
246252
#endif /* !Py_LIMITED_API */
247253
#endif /* !Py_PYCORECONFIG_H */

0 commit comments

Comments
 (0)