Details
-
Type:
Enhancement
-
Status:
Closed
-
Priority:
Major
-
Resolution: Declined
-
Affects Version/s: Release 1.4
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
Description
Right now if I need to use a record defined in another name space, I need to do this:
(ns myproj.test.xyz
(:use [myproj.xyz])
(:import [myproj.xyz MyRecord])
Hope we can remove the need of ":import" clause.
Thanks for giving it a thought.
I think it is conceptually simple/consistent to say "if you use a namespace, then all the public symbols in that namespace is available without namespace qualification". It is unnecessary to remind people "Hey, record is an actually a Java class so the rules do not apply". I think it is the right choice for Clojure to integrate closely with the host language, but it is not the objective to expose the host details when not needed. If you say "this is a compromise due to some implementation consideration", then I can understand. But I disagree with the rationale you mentioned.