Not your computer? Use a private browsing window to sign in. Learn more
Not your computer? Use a private browsing window to sign in. Learn more
Clojure | 18:34 | Clojureのマルチメソッドを使っていると、自分で定義した型でディスパッチしたいと思うことがある。しかしdefstructを使ってもうまくいかない。 user> (defstruct Foo :a :b) #'user/Foo user> (struct Foo 1 2) {:a 1, :b 2} user> (class *1) clojure.lang.PersistentStructMap user> (defmulti my-println class) #'user/my-println user> (defmethod my-println Foo [foo] (println "foo")) # user> (my-println (struct Foo 1 2)) ;=> error ; Evaluation aborted. defs
I am Baishampayan, a technologist & entrepreneur. I know, my name can be a bit difficult to pronounce; you are welcome to call me ‘beegee’ /biːdʒiː/. I am currently founder & cto at TeamOhana where we are working on solving the problem of headcount management for enterprises undergoing rapid growth. Previously, I was co-founder & cto at Helpshift where we pioneered the now ubiquitous in-app custom
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く