Skip to content

Commit

Permalink
Fix identity decorator for when Numba unavailable (#220)
Browse files Browse the repository at this point in the history
Co-authored-by: Mike Boyle <[email protected]>
  • Loading branch information
eufrizz and moble committed Nov 30, 2023
1 parent 7113a90 commit c697de5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ license = "MIT"
authors = ["Michael Boyle <[email protected]>"]
homepage = "https://github.com/moble/quaternion"

[build-system]
requires = ["setuptools!=50.0", "wheel", "oldest-supported-numpy"]
build-backend = "setuptools.build_meta"

[tool.pytest.ini_options]
minversion = "6.0"
norecursedirs = ".* build dist *.egg-info install ENV"
junit_family="xunit2"
addopts = "-v --tb=short --doctest-glob='' --cov=quaternion --cov-branch --cov-report xml"

[build-system]
requires = ["setuptools!=50.0", "wheel", "oldest-supported-numpy"]
build-backend = "setuptools.build_meta"
6 changes: 3 additions & 3 deletions src/quaternion/numba_wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@
# "may wish to install numba." + \
# "\n" + "!" * 53 + "\n"
# warnings.warn(warning_text)
def _identity_decorator_outer(*args, **kwargs):
def _identity_decorator_inner(fn):
return fn
def _identity_decorator_outer(fn):
def _identity_decorator_inner(*args, **kwargs):
return fn(*args, **kwargs)
return _identity_decorator_inner
njit = _identity_decorator_outer
jit = _identity_decorator_outer
Expand Down

0 comments on commit c697de5

Please sign in to comment.