Skip to content

Commit e9d5c9d

Browse files
committed
[cppyy] Remove now irrelevant load_cpp_backend() call
As we don't have a separate `cppyy_backend` anymore (neither as a Python package, nor as a shared library), trying to load the backend library will always give an exception that will be caught as an `ImportError`. It would be cleaner if this code branch is not even taken.
1 parent a9f0f9b commit e9d5c9d

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

bindings/pyroot/cppyy/cppyy/python/cppyy/_cpython_cppyy.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,24 +19,12 @@
1919
'_end_capture_stderr'
2020
]
2121

22-
# First load the dependency libraries of the backend, then pull in the libcppyy
23-
# extension module. If the backed can't be loaded, it was probably linked
24-
# statically into the extension module, so we don't error out at this point.
25-
try:
26-
from cppyy_backend import loader
27-
c = loader.load_cpp_backend()
28-
except ImportError:
29-
c = None
30-
3122
if platform.system() == "Windows":
3223
# On Windows, the library has to be searched without prefix
3324
import libcppyy as _backend
3425
else:
3526
import cppyy.libcppyy as _backend
3627

37-
if c is not None:
38-
_backend._cpp_backend = c
39-
4028
# explicitly expose APIs from libcppyy
4129
_w = ctypes.CDLL(_backend.__file__, ctypes.RTLD_GLOBAL)
4230

0 commit comments

Comments
 (0)