Skip to content

Commit 96df3a3

Browse files
committed
Remove dead code and enable release on windows.
1 parent b4af2ab commit 96df3a3

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

.github/workflows/windows-test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
# {build: debug, sanitizer: memory-sanitizer},
3333

3434
# TODO: https://github.com/metacall/core/issues/461
35-
# {build: release, sanitizer: without-sanitizer}
35+
{build: release, sanitizer: without-sanitizer}
3636
]
3737

3838
steps:

source/loaders/py_loader/source/py_loader_dict.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
#define Py_BUILD_CORE
4444
#endif
4545
#include <internal/pycore_dict.h>
46+
#undef Py_BUILD_CORE
4647

4748
/* Disable warnings from Python */
4849
#if defined(__clang__)

source/loaders/py_loader/source/py_loader_impl.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2396,7 +2396,6 @@ int py_loader_impl_initialize_thread_background_module(loader_impl_py py_impl)
23962396
"import asyncio\n"
23972397
"import threading\n"
23982398
"import sys\n"
2399-
// "import atexit; atexit.register(getattr(sys.modules.get('py_port_impl_module'), 'py_loader_port_atexit', lambda: None))\n"
24002399
"class ThreadLoop:\n"
24012400
" def __init__(self, loop, t):\n"
24022401
" self.loop = loop\n"
@@ -2433,9 +2432,7 @@ int py_loader_impl_initialize_thread_background_module(loader_impl_py py_impl)
24332432
" tl.t.join()\n"
24342433
"def atexit_background_loop(tl):\n"
24352434
/* Checks if py_port_impl_module contains py_loader_port_atexit and executes it */
2436-
// " py_loader_port_atexit = getattr(sys.modules.get('py_port_impl_module'), 'py_loader_port_atexit', lambda: None)\n"
24372435
" getattr(sys.modules.get('py_port_impl_module'), 'py_loader_port_atexit', lambda: None)()\n"
2438-
// " tl.loop.call_soon_threadsafe(stop_background_loop, tl, False)\n"
24392436
"def register_atexit_background_loop(tl):\n"
24402437
" threading._register_atexit(atexit_background_loop, tl)\n";
24412438

0 commit comments

Comments
 (0)