We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
version
0.3.32 and master
platform
macOS 12.4 / Nodejs v18.3.0
problem
The behavior of (extend-type default ,,,) and (extend-protocol IFoo default ,,,) is different than vanilla CLJS.
(extend-type default ,,,)
(extend-protocol IFoo default ,,,)
repro
There are few different cases.
extend-type:
(defprotocol IFoo (foo [_])) (extend-type default IFoo (foo [_] :default)) (map #(vector (satisfies? IFoo %) (foo %)) [#js {} "" 1 #js [] inc true (js/Object.create nil)])
extend-protocol:
(defprotocol IFoo (foo [_])) (extend-protocol IFoo default (foo [_] :default)) (map #(vector (satisfies? IFoo %) (foo %)) [#js {} "" 1 #js [] inc true (js/Object.create nil)])
expected behavior
The extend-type example should return:
([true :default] [true :default] [true :default] [true :default] [true :default] [true :default] [true :default])
but it will work only for #js {} and does not implement the protocol on any other type.
#js {}
The extend-protocol example should return the same, but will try and resolve the symbol default and fail.
default
The text was updated successfully, but these errors were encountered:
Extend protocols to JS built ins using CLJS "type symbols", fix exten…
3e068bb
…ding protocols to default & Object (#784) Fixes #781, #782 and #783
No branches or pull requests
version
0.3.32 and master
platform
macOS 12.4 / Nodejs v18.3.0
problem
The behavior of
(extend-type default ,,,)
and(extend-protocol IFoo default ,,,)
is different than vanilla CLJS.repro
There are few different cases.
extend-type:
extend-protocol:
expected behavior
The extend-type example should return:
but it will work only for
#js {}
and does not implement the protocol on any other type.The extend-protocol example should return the same, but will try and resolve the symbol
default
and fail.The text was updated successfully, but these errors were encountered: