Fix clj-kondo warnings

This commit is contained in:
Joshua Suskalo 2021-09-15 11:23:12 -05:00
parent ae99c534c2
commit ce29d1e9ee

View file

@ -19,12 +19,16 @@
Any new allocations made during the serialization should be tied to the given Any new allocations made during the serialization should be tied to the given
`scope`, except in extenuating circumstances." `scope`, except in extenuating circumstances."
(fn [type obj segment scope] (fn
#_{:clj-kondo/ignore [:unused-binding]}
[type obj segment scope]
type)) type))
(defmulti deserialize (defmulti deserialize
"Deserializes the given object into a Clojure data structure." "Deserializes the given object into a Clojure data structure."
(fn [type obj] (fn
#_{:clj-kondo/ignore [:unused-binding]}
[type obj]
type)) type))
(defmulti size-of (defmulti size-of
@ -32,39 +36,39 @@
(fn [type] type)) (fn [type] type))
(defmethod size-of ::byte (defmethod size-of ::byte
[type] [_]
Byte/SIZE) Byte/SIZE)
(defmethod size-of ::short (defmethod size-of ::short
[type] [_]
Short/SIZE) Short/SIZE)
(defmethod size-of ::integer (defmethod size-of ::integer
[type] [_]
Integer/SIZE) Integer/SIZE)
(defmethod size-of ::long (defmethod size-of ::long
[type] [_]
Long/SIZE) Long/SIZE)
(defmethod size-of ::long-long (defmethod size-of ::long-long
[type] [_]
Long/SIZE) Long/SIZE)
(defmethod size-of ::char (defmethod size-of ::char
[type] [_]
Byte/SIZE) Byte/SIZE)
(defmethod size-of ::float (defmethod size-of ::float
[type] [_]
Float/SIZE) Float/SIZE)
(defmethod size-of ::double (defmethod size-of ::double
[type] [_]
Double/SIZE) Double/SIZE)
(defmethod size-of ::pointer (defmethod size-of ::pointer
[type] [_]
(.byteSize MemoryLayouts/ADDRESS)) (.byteSize MemoryLayouts/ADDRESS))
(def c-layout (def c-layout