X-Git-Url: https://scm.cri.ensmp.fr/git/linpy.git/blobdiff_plain/7b93cea1daf2889e9ee10ca9c22a1b5124404937..98edd00eb4b05e85f7cb1b85cff2f4d733909c57:/linpy/islhelper.py?ds=sidebyside diff --git a/linpy/islhelper.py b/linpy/islhelper.py index c38e734..b0dffe7 100644 --- a/linpy/islhelper.py +++ b/linpy/islhelper.py @@ -16,6 +16,7 @@ # along with LinPy. If not, see . import ctypes, ctypes.util +import re from . import _islhelper from ._islhelper import * @@ -38,7 +39,8 @@ libisl = ctypes.CDLL(ctypes.util.find_library('isl')) libisl.isl_dim_set = _islhelper.dim_set libisl.isl_version.restype = ctypes.c_char_p -isl_version = libisl.isl_version().decode().strip()[len('isl-'):] +isl_version = libisl.isl_version().decode().strip() +isl_version = re.sub(r'^isl-', '', isl_version) mainctx = libisl.isl_ctx_alloc()