On 9 jan, 07:54, lpetit <laurent.pe...@gmail.com> wrote:
> On 9 jan, 04:03, Stuart Sierra <the.stuart.sie...@gmail.com> wrote:
> > > Later on, if I call (load) (from a fresh clojure environment) from the
> > > compiled classes, the top level (println)s are not executed, since not
> > > compiled.
>
> > Yes, that's the expected behavior.   "compile" only saves the things
> > defined in the namespace.
>
> Well, I easily understand that it is the compiled behaviour. And in
> the same time, I don't feel it "right" that loading the same lib from
> source file or from compiled files can have different results.

Because then, it's not correct to say that we can interchange a source
version and a compiled version of a lib.
So maybe it should be expressed that libs should not do anything but
define things in the namespace (maybe it's also stated in the doc and
I skipped it, if so, my apologies).
-> And that could be a distinction between libs and plain namespaces.
And in that case, do you think it could be interesting to mark the
namespace with a "is-a-lib" meta-data to (for example) :
- prevent the compiler to compile it by default (or emit a warning, or
compile only if some :force flag is set)
- allow automatic tools to explicitly see the difference between a lib
and a PON (plain old namespace)

Thanks in advance for your answers,

--
Laurent

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To post to this group, send email to clojure@googlegroups.com
To unsubscribe from this group, send email to 
clojure+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to