Skip to content

Commit

Permalink
Fix reflection warning (#61)
Browse files Browse the repository at this point in the history
* Fix reflection warning

* Fix warning: 'Bad method signature in protocol implementation, IFn does not declare method called invoke'

---------

Co-authored-by: CreativeQuantum <>
  • Loading branch information
CreativeQuantum authored Jan 4, 2024
1 parent f3ead46 commit 86bbc46
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/robertluo/fun_map/core.cljc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
(:import #?(:clj [clojure.lang
IMapEntry
IPersistentMap
ITransientMap])))
ITransientMap
ATransientMap])))

#?(:clj
;;Marker iterface for a funmap
Expand All @@ -17,7 +18,7 @@

;;Support transient
#?(:clj
(deftype TransientDelegatedMap [^ITransientMap tm fn-entry]
(deftype TransientDelegatedMap [^ATransientMap tm fn-entry]
ITransientMap
(conj [_ v] (TransientDelegatedMap. (.conj tm v) fn-entry))
(persistent [_] (->DelegatedMap (persistent! tm) fn-entry))
Expand Down Expand Up @@ -178,8 +179,8 @@
(fn-entry this (-find m k))))

IFn
(invoke [this k] (-lookup this k))
(invoke [this k not-found] (-lookup this k not-found))
(-invoke [this k] (-lookup this k))
(-invoke [this k not-found] (-lookup this k not-found))

ILookup
(-lookup
Expand Down

0 comments on commit 86bbc46

Please sign in to comment.