Fork me on GitHub
Alex Miller (Clojure team)13:04:04

bronsa: we're talking about your proposal, will update on the ticket. re "2- no please. that would make the proposed syntax useless for e.g. Datomic schemas, for which I think this would be a good fit to reduce noise" I don't get what you're saying there at all and I suspect I just didn't communicate the question well


gah, nevermind about that, I read an only that isn't there


thought you were asking whether we should only support auto-resolving to existing namespaces

Alex Miller (Clojure team)13:04:49

no, just the fallback behavior that auto-resolved keywords support (which I think is weird for keywords actually)


@alexmiller: I'm not understanding -- are you talking of e.g. ::clojure.core/foo ?


why is that weird?


ah, I guess because the :: is useless?

Alex Miller (Clojure team)13:04:27

yeah, I totally don't get the point of that


well, it ensures that the ns does exist


which :clojure.core/foo doesn't


not sure if that ever matters simple_smile

Alex Miller (Clojure team)13:04:03

have you ever seen that used? I can't say I have


but I'd say it's ok as is, as a matter of consistency. the way I see it, aliases are a superset of the alias targets


so if (alias 'c.c 'clojure.core) ::c.c/foo works, I'd expect the mechanical un-aliased form ::clojure.core/foo to work aswell

Alex Miller (Clojure team)13:04:40

rich asked if in your proposal there is any way to autoresolve keys to the current namespace (since you removed #::) ?


::foo does that already

Alex Miller (Clojure team)13:04:24

so you just wouldn't use #: at all then

Alex Miller (Clojure team)13:04:33

we think it will be common for maps to have a mixture of current ns and some other ns which doesn't play as well this way


how would that work in your proposal? #:foo {:bar 1 ::baz 2} -> {:foo/bar 1 :user/baz 2}?


although I guess that's again, only true for clojure and not EDN, given the lack of pre-existing auto-resolving syntax macros, namely :: and "`" in EDN

Alex Miller (Clojure team)13:04:27

I think it's definitely a subtle part of Clojure where the "namespace part of a symbol" does and does not relate to "namespaces" (or "libs" as much of the Clojure docs calls them).


@alexmiller: your last point is to say being able to #:foo {:a 1 :b 2} -> #:bar {:a 1 :b 2} ?

Alex Miller (Clojure team)13:04:33

no to say you can go from {:a 1 :b 2} to #:foo{:a 1 :b 2} without changing all the keys


ah, gotcha


@alexmiller: what about #:foo{'bar 1} returning different results than '#:foo{bar 1}? that by design or an accident of the current impl?


the former has the advantage that the values don't need to be constants