Closed vemv closed 3 years ago
Fixes https://github.com/jonase/eastwood/issues/385
This false positive's origin can be tracked down to this commit:
https://github.com/jonase/eastwood/commit/7c0f432ee1be4748fb6cb765089872cd7640d27e
I think that commit made the mistake of conflating "this pattern should not trigger an exception" with "with pattern should trigger a linter fault".
Usages in the wild such as the following show that in fact the pattern is functional:
https://github.com/mikera/core.matrix/blob/0a35f6e3d6d2335cb56f6f3e5744bfa1dd0390aa/src/main/clojure/clojure/core/matrix/impl/double_array.clj#L124
https://github.com/immutant/immutant/blob/6ff8fa03acf73929f61f2ca75446cb559ddfc1ef/web/src/immutant/web/async.clj#L198
https://github.com/sunng87/ring-jetty9-adapter/blob/95bf989216cb01986615c40b4cc50178d1578db1/src/ring/adapter/jetty9/websocket.clj#L44
https://github.com/funcool/catacumba/blob/a493843176ee8defa2f3c6afa23c720f495d9341/src/clojure/catacumba/impl/handlers.clj#L128
[x] You've updated the changelog (if adding/changing user-visible functionality)
[ ] You've updated the readme (if eg adding a new linter)
This false positive's origin can be tracked down to this commit:
https://github.com/jonase/eastwood/commit/7c0f432ee1be4748fb6cb765089872cd7640d27e
I think that commit made the mistake of conflating "this pattern should not trigger an exception" with "with pattern should trigger a linter fault".
Usages in the wild such as the following show that in fact the pattern is functional:
https://github.com/mikera/core.matrix/blob/0a35f6e3d6d2335cb56f6f3e5744bfa1dd0390aa/src/main/clojure/clojure/core/matrix/impl/double_array.clj#L124
https://github.com/immutant/immutant/blob/6ff8fa03acf73929f61f2ca75446cb559ddfc1ef/web/src/immutant/web/async.clj#L198
https://github.com/sunng87/ring-jetty9-adapter/blob/95bf989216cb01986615c40b4cc50178d1578db1/src/ring/adapter/jetty9/websocket.clj#L44
https://github.com/funcool/catacumba/blob/a493843176ee8defa2f3c6afa23c720f495d9341/src/clojure/catacumba/impl/handlers.clj#L128
[x] You've updated the changelog (if adding/changing user-visible functionality)
[ ] You've updated the readme (if eg adding a new linter)