This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-05-13
Channels
- # aleph (6)
- # announcements (10)
- # asami (3)
- # babashka (111)
- # babashka-sci-dev (20)
- # beginners (28)
- # calva (28)
- # clj-http (2)
- # clj-kondo (23)
- # cljs-dev (16)
- # cljsrn (23)
- # clojure (116)
- # clojure-czech (3)
- # clojure-europe (33)
- # clojure-nl (1)
- # clojure-norway (7)
- # clojure-uk (5)
- # clojurescript (41)
- # community-development (2)
- # cursive (5)
- # datahike (4)
- # datomic (13)
- # figwheel-main (3)
- # fulcro (11)
- # google-cloud (1)
- # gratitude (8)
- # hyperfiddle (14)
- # jobs (2)
- # lsp (22)
- # malli (4)
- # off-topic (4)
- # other-languages (4)
- # pathom (13)
- # portal (40)
- # rdf (11)
- # reitit (1)
- # sci (15)
- # shadow-cljs (7)
- # specter (1)
- # sql (6)
- # xtdb (4)
something i can’t explain: somehow during a full run of sexps, something like the following (pr-str (sci/eval-string "(completing conj count)"))
which returns "#function[clojure.core/completing/fn--8528]"
, begins returning "#object[clojure.core$completing$fn__8528 0x2f2a24dc \"clojure.core$completing$fn__8528@2f2a24dc\"]"
and my gut is telling me that this is some kind of host access scenario, but i cannot track it down. any ideas?
@devn SCI re-uses the clojure core functions, that's what you are seeing here, the printed version of a function in completing
hmm, i think i’m still missing something/am not following. i can’t seem to produce that #object…
string in my code
im having trouble understanding how #object[...]
shows up in these strings when something like (pr-str (sci/eval-string "(comp)"))
produces "#function[…]"
.
No, can you spell it out more explicit? Please code as if I'm starting my editor from scratch
What you are seeing is just functions / closures being printed - what else do you expect?
sorry, had to step away. i’m totally failing at understanding this/providing a code example to demonstrate.
maybe this is a more fundamental clojure question.
what causes it to be printed as #object[…]
?
when i run a function via lein run -m foo.core
, they look like "#object[sci.impl.fns$fun$arity_1__26730 0x41167e79 \"sci.impl.fns$fun$arity_1__26730@41167e79\"]"
.
if I run it from a repl they look like "#function[sci.impl.fns/fun/arity-1--33946]"
took me a lot of banging my head against the wall to finally narrow it down to REPL v not: https://github.com/clojure-emacs/cider-nrepl/blob/master/src/cider/nrepl/print_method.clj#L12