;; Once upon a time I opened a REPL and wrote a protocol ;; definition: (defprotocol SomeProtocol (f [this])) ;; And a record: (defrecord SomeRecord [] SomeProtocol (f [this] "I don't do a whole lot.")) ;; And a very useful side-effect free function! (defn some-function [] (f (SomeRecord.))) ;; I call my function... (some-function) ;; ...to see exactly what I expect: ;; user=> "I don't do a whole lot." ;; Unsatisfied with the result, I tweak my record a little bit: (defrecord SomeRecord [] SomeProtocol (f [this] "I do a hell of a lot!")) (some-function) ;; user=> "I don't do a whole lot."
Looks like a mistake. I just can't be sure to see a lot of false compiler error reports in a C ++ user group.
source share