Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MINOR - abs warning on clojure 1.11+ #129

Open
cnuernber opened this issue Sep 15, 2022 · 3 comments
Open

MINOR - abs warning on clojure 1.11+ #129

cnuernber opened this issue Sep 15, 2022 · 3 comments

Comments

@cnuernber
Copy link

cnuernber commented Sep 15, 2022

1.11 and beyond include an abs function leading to these warning:

WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.math, being replaced by: #'uncomplicate.neanderthal.math/abs
Warning: protocol #'uncomplicate.neanderthal.internal.api/VectorMath is overwriting function abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.api, being replaced by: #'uncomplicate.neanderthal.internal.api/abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.host.buffer-block, being replaced by: #'uncomplicate.neanderthal.internal.api/abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.common, being replaced by: #'uncomplicate.neanderthal.internal.api/abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.printing, being replaced by: #'uncomplicate.neanderthal.internal.api/abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.navigation, being replaced by: #'uncomplicate.neanderthal.internal.api/abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.host.mkl, being replaced by: #'uncomplicate.neanderthal.internal.api/abs
WARNING: abs already refers to: #'clojure.core/abs in namespace: uncomplicate.neanderthal.internal.host.lapack, being replaced by: #'uncomplicate.neanderthal.math/abs
@blueberry
Copy link
Member

Thank you for reporting. I am aware of this, but I am not sure how to remove this warning, since the (vectorized) function abs is not covered by Clojure's abs, and if I exclude Clojure's abs, it would only work with Clojure 1.11+ (Clojure didn't have abs at the time when I introduced it), and the earlier Clojure will throw error. Any suggestions welcome.

@cnuernber
Copy link
Author

10.X according to my testing will not throw an error:

(base) chrisn@chrisn-lt3:~$ clj --version
Clojure CLI version 1.10.3.1075
(base) chrisn@chrisn-lt3:~$ clj
Clojure 1.10.3
(ns foo (:refer-clojure :exclude [a b c d e f g]))
nil
foo=>

So it kind of depends on how far back you want to go - my fix for dtype-next which has abs and finite? and infinite? was to just exclude them. I did not test this with 10.9.

@blueberry
Copy link
Member

Thanks for the solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants