Absolutely.
--
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
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send em
Could you please file a bug report with both your example, the JS code
and the explanation?
Thanks,
Rich
On Jul 27, 2011, at 9:48 PM, Anthony Grimes wrote:
Hah! That was it! You, sir, are one clever fellow. Thank you very
much.
--
You received this message because you are subscribed to t
On Wed, Jul 27, 2011 at 9:48 PM, Anthony Grimes wrote:
> Hah! That was it! You, sir, are one clever fellow. Thank you very much.
Damn. I didn't think of that. In normal Clojure, defn'ing x.y/x
doesn't clobber the Java package named x with a function named x. But
it looks like in JS packages and f
Hah! That was it! You, sir, are one clever fellow. Thank you very much.
--
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
Note that posts from new members are moderated - please be patient wi
Is it possible that the new function called portal is overwriting the
namespace called portal? Could you try renaming the function called
portal to something else? Like portal2?
On Wed, Jul 27, 2011 at 6:05 PM, Anthony Grimes wrote:
> That's actually what I thought at first, but the node example
Right, I have an ns form. I just didn't post it.
(ns portal.core
(:require [cljs.nodejs :as node]
[clojure.string :as string]
[goog.date.DateTime :as time]))
This is all part of a bigger application. I just pulled stuff out to make a
minimal example (that does fail, by
On Wed, Jul 27, 2011 at 9:30 PM, Anthony Grimes wrote:
> It looks like main is called the same way. Like I said, my example is not
> much different than the one that comes with cljs.
>
> (ns nodels
> (:require [cljs.nodejs :as nodejs]))
> (def fs (nodejs/require "fs"))
> (def path (nodejs/requir
It looks like main is called the same way. Like I said, my example is not
much different than the one that comes with cljs.
(ns nodels
(:require [cljs.nodejs :as nodejs]))
(def fs (nodejs/require "fs"))
(def path (nodejs/require "path"))
(defn file-seq [dir]
(tree-seq
(fn [f] (.isDirect
On Wed, Jul 27, 2011 at 9:21 PM, Anthony Grimes wrote:
> The first argument to Javascript's 'call' is a 'this' argument. All
> generated functions are called like this.
If portal.core.net is an instance rather than a class variable then a
null "this" would explain it not resolving. Is "_main" cal
The first argument to Javascript's 'call' is a 'this' argument. All
generated functions are called like this.
--
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
Note that posts from new membe
On Wed, Jul 27, 2011 at 9:05 PM, Anthony Grimes wrote:
> That's actually what I thought at first, but the node example that ships
> with ClojureScript actually does the same thing (uses a node function
> outside of -main and then calls that function from -main) I did and it works
> fine.
> Here is
That's actually what I thought at first, but the node example that ships
with ClojureScript actually does the same thing (uses a node function
outside of -main and then calls that function from -main) I did and it works
fine.
Here is the generated JavaScript for the failing -main and such:
por
On Wed, Jul 27, 2011 at 8:38 PM, Anthony Grimes wrote:
> Sorry for the terrible subject line. I couldn't think of an easy way to
> describe the problem in a single line.
> (def net (node/require "net"))
> (defn portal
> [port host] (.createConnection net port host))
> (defn -main [& args] ; Note
Yeah. To the extent that I can read Javascript, the calls look exactly the
same and it looks fine.
--
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
Note that posts from new members are mod
have you looked at the generated javascript?
On Wed, Jul 27, 2011 at 5:44 PM, Anthony Grimes wrote:
> Yep, just double checked. No extra spaces.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@goo
Yep, just double checked. No extra spaces.
--
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
Note that posts from new members are moderated - please be patient with your
first post.
To unsub
are you sure you don't have an extra space in there?
(. createConnection net …) vs. (.createConnection net …)
On Wed, Jul 27, 2011 at 5:38 PM, Anthony Grimes wrote:
> Sorry for the terrible subject line. I couldn't think of an easy way to
> describe the problem in a single line.
> (def net (node/
"It's odd that it works fine in the first one but no the second."
You'd think with that post button being so small that it'd be difficult
to... yeah.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@google
18 matches
Mail list logo