Skip to content

Instantly share code, notes, and snippets.

/gist:57fbb6f1637b30a2075d Secret
Created Dec 28, 2013

Embed
What would you like to do?
user> (read-string (pr-str (ecc2.model.projects/->ProjectSavedEvent {})))
{:project {}}
nil
user> (type (read-string (pr-str (ecc2.model.projects/->ProjectSavedEvent {}))))
ecc2.model.projects.ProjectSavedEvent
nil
user> (def e (ecc2.model.projects/->ProjectSavedEvent {}))
#<Var@1c3f417f: {:project {}}>
nil
user> (def e' (read-string (pr-str e)))
#<Var@1dd2c76a: {:project {}}>
nil
user> e
{:project {}}
nil
user> e'
{:project {}}
nil
user> (= e e')
false
nil
user> (defrecord Foo [bar])
user.Foo
nil
user> (let [e (->Foo {})] (= e (read-string (pr-str e))))
true
nil
user> (let [e (ecc2.model.projects/->ProjectSavedEvent {})] (= e (read-string (pr-str e))))
false
nil
user> (let [e (ecc2.model.projects/->ProjectSavedEvent {})] (= e (read-string (pr-str e))))
false
nil
user> e'
{:project {}}
nil
user> e
{:project {}}
nil
user> (type e)
ecc2.model.projects.ProjectSavedEvent
nil
user> (type e')
ecc2.model.projects.ProjectSavedEvent
nil
user> (class e')
ecc2.model.projects.ProjectSavedEvent
nil
user> (class e)
ecc2.model.projects.ProjectSavedEvent
nil
user> (= (class e) (class e'))
false
nil
user>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.