Re: [ANN] 美味しいClojure

2013-10-03 Thread Alan Busby
Hi Dave,

Regarding Clojure events in Tokyo, I'm only aware of Tokyo.clj at the
moment and it's held in Japanese. It sounds like we have a few expats here
in Tokyo using Clojure though, so it might be worth putting something
together (in English?).

I can likely host something at the Gracenote office here in Shibuya if
there is enough interest. If schedules work out Mr. Ambrose may be able to
give us a quick intro / Q+A on core.typed as well.

Anyone interested?


Thanks,
   Alan Busby



On Thu, Oct 3, 2013 at 2:32 PM, Dave Della Costa wrote:

> Speaking of, is there anything other than Tokyo.clj (which seems pretty
> infrequent based on this: http://atnd.org/event/tokyoclj) going on for
> Clojurians in Tokyo?   I work remotely, using Clojure, and would love to
> get together more frequently with other Clojure developers if possible.
>  If anyone is interested in doing something like co-working on a more
> regular basis, let me know!
>
> Cheers,
> DD
>
> (2013/10/03 9:44), Alan Busby wrote:
> > On Thu, Oct 3, 2013 at 9:30 AM, Marek Kubica  > > wrote:
> >
> > On Tue, 1 Oct 2013 22:01:02 -0700 (PDT)
> > Nicolas Modrzyk mailto:hellon...@gmail.com>>
> > wrote:
> >
> > > The whole text has also been written in English, so I guess there
> > > could be a chance to put it out there.
> > > But we have had no contacts with US/UK publishers so far.
> >
> > Did you try the usual suspects like O'Reilly or PragProg? They are
> > surprisingly approachable.
> >
> >
> > The O'Reilly Tokyo office is on the ground floor of where Tokyo.clj is
> > hosted too!
> >
> > --
> > --
> > 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 email to
> > clojure+unsubscr...@googlegroups.com
> > For more options, visit this group at
> > http://groups.google.com/group/clojure?hl=en
> > ---
> > You received this message because you are subscribed to the Google
> > Groups "Clojure" group.
> > To unsubscribe from this group and stop receiving emails from it, send
> > an email to clojure+unsubscr...@googlegroups.com.
> > For more options, visit https://groups.google.com/groups/opt_out.
>
> --
> --
> 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 email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [ANN] 美味しいClojure

2013-10-03 Thread Ambrose Bonnaire-Sergeant
Me! :)

Ambrose


On Thu, Oct 3, 2013 at 3:07 PM, Alan Busby  wrote:

> Hi Dave,
>
> Regarding Clojure events in Tokyo, I'm only aware of Tokyo.clj at the
> moment and it's held in Japanese. It sounds like we have a few expats here
> in Tokyo using Clojure though, so it might be worth putting something
> together (in English?).
>
> I can likely host something at the Gracenote office here in Shibuya if
> there is enough interest. If schedules work out Mr. Ambrose may be able to
> give us a quick intro / Q+A on core.typed as well.
>
> Anyone interested?
>
>
> Thanks,
>Alan Busby
>
>
>
> On Thu, Oct 3, 2013 at 2:32 PM, Dave Della Costa wrote:
>
>> Speaking of, is there anything other than Tokyo.clj (which seems pretty
>> infrequent based on this: http://atnd.org/event/tokyoclj) going on for
>> Clojurians in Tokyo?   I work remotely, using Clojure, and would love to
>> get together more frequently with other Clojure developers if possible.
>>  If anyone is interested in doing something like co-working on a more
>> regular basis, let me know!
>>
>> Cheers,
>> DD
>>
>> (2013/10/03 9:44), Alan Busby wrote:
>> > On Thu, Oct 3, 2013 at 9:30 AM, Marek Kubica > > > wrote:
>> >
>> > On Tue, 1 Oct 2013 22:01:02 -0700 (PDT)
>> > Nicolas Modrzyk mailto:hellon...@gmail.com>>
>> > wrote:
>> >
>> > > The whole text has also been written in English, so I guess there
>> > > could be a chance to put it out there.
>> > > But we have had no contacts with US/UK publishers so far.
>> >
>> > Did you try the usual suspects like O'Reilly or PragProg? They are
>> > surprisingly approachable.
>> >
>> >
>> > The O'Reilly Tokyo office is on the ground floor of where Tokyo.clj is
>> > hosted too!
>> >
>> > --
>> > --
>> > 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 email to
>> > clojure+unsubscr...@googlegroups.com
>> > For more options, visit this group at
>> > http://groups.google.com/group/clojure?hl=en
>> > ---
>> > You received this message because you are subscribed to the Google
>> > Groups "Clojure" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> > an email to clojure+unsubscr...@googlegroups.com.
>> > For more options, visit https://groups.google.com/groups/opt_out.
>>
>> --
>> --
>> 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 email to
>> clojure+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/clojure?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "Clojure" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to clojure+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>  --
> --
> 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 email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Type hints for clojure.set functions

2013-10-03 Thread Andy Fingerhut
I created a slightly modified version of clojure.set and have released it
as funjible.set

More info here, if you are curious:

https://github.com/jafingerhut/funjible

Andy


On Mon, Sep 30, 2013 at 8:00 PM, splondike  wrote:

> If it's a case of prioritization, that makes sense. I was going to suggest
> raising a bug, and then triaging it as low priority, but I notice that
> there is already a declined JIRA 
> issue.
> I apologize for not checking there before adding this thread.
>
> I'm very new to Clojure which is why I wasn't sure whether this kind of
> runtime defensive programming was the norm, and you seem to suggest that
> it's not. A static checker/lint would of course be preferable if it could
> catch these kinds of programmer errors.
>
> I notice that there's a very successful crowdsource fund going toward
> core.typed , perhaps
> this static checker will be a reality this time next year.
>
> On Monday, September 30, 2013 5:55:01 PM UTC-4, stuart@gmail.comwrote:
>
>> Hi splondike,
>>
>> I disagree with your arguments about what is sensible -- *any* behavior
>> is sensible when you violate the contract of an API.
>>
>> Of course everybody could get behind the "throwing the error" plan if the
>> cost of throwing that error was zero:  zero assessment cost, zero
>> development cost, zero runtime cost, and zero maintenance cost.  But those
>> costs are not zero, so as a screener I have to ask myself "should I spend
>> my next half hour looking at this issue, which impacts only broken
>> programs, or one of the (currently 20) screenable tickets, many of which
>> impact *correct* programs?
>>
>> That said, perhaps core.typed can help us here.  I believe core.typed can
>> allow us to check programs and detect these kinds of errors, without
>> runtime impact (and without any change to Clojure at all.)  I am doing some
>> experiments with exactly this case, and will follow up on a separate thread.
>>
>> Regards,
>> Stu
>>
>>
>> On Mon, Sep 30, 2013 at 2:20 PM, splondike  wrote:
>>
>>> Thanks for the comment. The current behaviour is sensible for the code
>>> branch where the second argument is the same length or shorter than the
>>> first (see my first post). It is the other branch that does not do what you
>>> would expect. My real issue though is how the behaviour changes
>>> dramatically once we hit this branch (for non set args).
>>>
>>> The original author of the 
>>> patchwhich
>>>  produced this behaviour noted
>>> this shortcoming himself ,
>>> and only refrained from implementing the check due to being unsure about
>>> the performance penalty.
>>>
>>> I think that people who are currently relying on this function working
>>> for non set arguments are playing a risky game (which, like me, they're
>>> probably not aware of) due to this sudden change in behaviour. I would
>>> argue that existing users would be better served by having an error thrown
>>> rather than having unexpected data generated which is hard to track down.
>>>
>>> On Sunday, September 29, 2013 7:05:17 PM UTC-4, stuart@gmail.comwrote:

 I think the bar for such an enhancement is fairly high, and the value
 delivered fairly low.  It isn't so much the impact of assessing this single
 change, as the impact of managing the universe of such changes.

 Regards,
 Stu

>>> --
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Clojure" group.
>>> To post to this group, send email to clo...@googlegroups.com
>>>
>>> Note that posts from new members are moderated - please be patient with
>>> your first post.
>>> To unsubscribe from this group, send email to
>>> clojure+u...@googlegroups.com
>>>
>>> For more options, visit this group at
>>> http://groups.google.com/group/clojure?hl=en
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "Clojure" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to clojure+u...@googlegroups.com.
>>>
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>
>>
>>  --
> --
> 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 email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> For

Re: my first clojure "wat" moment - misunderstanding or bug?

2013-10-03 Thread James Warren
Thank you for your responses, Marek and Elias.

Elias, you hit it square on the head - I was using Java 6, and changing to 
Java 7 corrected the issue. If you don't mind me asking, how did you even 
know about this behavior? This isn't the type of information you typically 
see on Hacker News, albeit much more helpful! :)

On Wednesday, October 2, 2013 7:17:40 PM UTC-7, Elias Zaretsky wrote:
>
> Are you using Java 6 by any chance? This issue may be due to a gotcha in 
> java.util.EnumMap. The implementation of the entry set iterator in EnumMap 
> in Java 6 is unorthodox [1]. Its next() method always returns the same 
> object, which is mutated to "point" to different entries in the map as the 
> iterator moves forward. This explains the behavior you are observing. Try 
> switching to Java 7 or make sure you call the keys function every time you 
> need the sequence of keys.
>
> [1] 
> http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/EnumMap.java#EnumMap.EntryIterator
>
> Thanks,
> Elias.
>
> On Wednesday, October 2, 2013 5:19:31 PM UTC-4, James Warren wrote:
>>
>> I've been using Clojure for a couple months, so while I feel comfortable 
>> with it, I'm not certain whether some unusual behavior I encountered is a 
>> bug or a lack of understanding on my part.  (I suspect the latter.)
>>
>> The context arose from using Clojure reflection to inspect a class 
>> generated by Apache Thrift . Such classes have 
>> a static, unmodifiable map describing the members of the class. I wrote a 
>> function to extract the keys of this map; it initially appears to work, but 
>> "def"ing the results to a symbol and repeatedly using that symbol returns 
>> inconsistent results.
>>
>> I've boiled it down to a smaller example that replicates the result: (gist 
>> available )
>>
>> // Java class
>>
>> public class DummyClass {
>> public enum DummyEnum {
>> FIRST, SECOND, THIRD
>>   }
>>  
>>   public static final Map dummyMap;
>>   static {
>> Map tmpMap = new EnumMap> String>(DummyEnum.class);
>> tmpMap.put(DummyEnum.FIRST, "first");
>> tmpMap.put(DummyEnum.SECOND, "second");
>> tmpMap.put(DummyEnum.THIRD, "third");
>> dummyMap = Collections.unmodifiableMap(tmpMap);
>>   }
>> }
>>
>> // Clojure ns
>>
>> (ns refbug.core
>>   (:import [refbug DummyClass]))
>>  
>> (defn foo [^Class c]
>> ;; note: (into [] (keys (clojure.lang.Reflector/getStaticField c 
>> "dummyMap" works
>>   (keys (clojure.lang.Reflector/getStaticField c "dummyMap")))
>>  
>> (def m (foo DummyClass))
>> (println m)
>> ;; (# # #)
>> (println m)
>> ;; (# # #)
>>
>> Two different values upon successive calls using m.  Is this expected?  And 
>> if so, why?
>>
>> Many thanks,
>> -James
>>
>>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: API management in Clojure

2013-10-03 Thread Jozef Wagner
Hi,

No URL yet, it's in a design phase now. It's an experiment on replacing 
sequences with reducers where possible and one of its part is a reducible 
I/O. I've said complected because I like to separate the resource itself 
from e.g. the way it is accessed (async or blocking). If your defapi is a 
composition of some more primitive functionality, I would like to 
brainstorm these first.

Resources which are not readable of course do not implement CollReduce. So 
far the only fn guaranteed to be implemented by every resource is uri, 
which returns resource's URI. Most resources are Openable, and opened 
resources can be further reducible (can be read from) and/or drainable 
(consumes a reducible coll).

JW

On Thursday, October 3, 2013 3:10:36 AM UTC+2, Mikera wrote:
>
> Hi Jozef,
>
> Sounds interesting - is it open source / can you give a URL?
>
> Design question: Why are you interpreting resources as a reducible? I can 
> see that making sense for some resources, but not for others.
>
> As for "complected" - be careful not to confuse this with "composed". It's 
> perfectly reasonable to create higher order functionality by composing 
> simpler components (which is what I am proposing in this case).
>
> On Tuesday, 1 October 2013 15:50:53 UTC+8, Jozef Wagner wrote:
>>
>> Hi,
>>
>> Your approach seems very complected to me. What I'm currently working on 
>> is the following concept:
>> A resource type, which can be a file, url, some remote REST/SOAP resource 
>> or e.g. a kestrel queue. Each resource has URI and can be used in following 
>> ways:
>> - as a regular reducible collection: resource is opened when reduce/fold 
>> starts and closed after reduce is finished. 
>> - as a normal function: opens resource, sends data, then returns the 
>> response as an above reducible.
>> - in an asynchronous way, in which case the 'async open' function returns 
>> two channels, one for input and other for output. closed when you close the 
>> output channel. 
>>
>> It provides all features you've mentioned. API in that case will be just 
>> a collection of such resources. You can put them in a map, namespace, or 
>> serialize them.
>>
>> Data format which is sent/recieved is resource-specific, but it is often 
>> a byte collection. You can apply formatter on a resource that translate 
>> between data formats (e.g. utf-8<->char, json<->clj-objects)
>>
>> JW
>>
>>
>> On Tue, Oct 1, 2013 at 5:46 AM, Mikera  wrote:
>>
>>> Hi all,
>>>
>>> I'm curious about the options for managing APIs in Clojure code in a 
>>> relatively idiomatic / consistent / functional way. The features I'm 
>>> roughly interested in are:
>>> - ability to "wrap" a remote API in a regular Clojure function
>>> - abstraction away from the details of how the API is implemented (REST, 
>>> SOAP etc.)
>>> - sane handling for both async and synchronous calls (ideally building 
>>> on core.async)
>>> - possible serialisation of API references (e.g. you can send an API 
>>> function to another machine that can then call it)
>>> - sane default handling for standard stuff like timeouts, errors etc?
>>>
>>> I'm thinking of syntax roughly like:
>>>
>>> (defapi foo 
>>>   :call (fn [x] (do-rest-call "http://some.host/api/foo"; x other-param))
>>>   :timeout 1000
>>>   :async true
>>>   :on-error (fn [ex] (handle-exception ex)))
>>> => [an API object, probably a defrecord-like structure that implements 
>>> IFn] 
>>>
>>> (foo "hello")
>>> => core.asyc channel that returns result of calling foo API
>>>
>>> ((sync foo) "hello")
>>> => result of synchronously calling foo API
>>>
>>> (async? foo)
>>> => true
>>>
>>> ((modify foo {:timeout 100}) "quick hello")
>>> => like (foo "hello") but with a shorter timeout
>>>
>>>
>>> Has anyone built or seen anything like this? 
>>> If not, would this be a useful library / contrib?
>>>
>>>  -- 
>>> -- 
>>> You received this message because you are subscribed to the Google
>>> Groups "Clojure" group.
>>> To post to this group, send email to clo...@googlegroups.com
>>> Note that posts from new members are moderated - please be patient with 
>>> your first post.
>>> To unsubscribe from this group, send email to
>>> clojure+u...@googlegroups.com
>>> For more options, visit this group at
>>> http://groups.google.com/group/clojure?hl=en
>>> --- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Clojure" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to clojure+u...@googlegroups.com.
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>
>>
>>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google

Re: Type hints for clojure.set functions

2013-10-03 Thread Gavin Sinclair
Looks great, Andy.

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Clojure at Netflix by Dave Ray

2013-10-03 Thread Angel Java Lopez
https://speakerdeck.com/daveray/clojure-at-netflix

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: (Clojure-related book) Seven Concurrency Models in Seven Weeks

2013-10-03 Thread Sean Johnson
According to page 11 of 
this: http://media.pragprog.com/titles/pb7con/intro.pdf

They are:

1. Threads & Locks (old school)
2. Actors (Erlang and its clones)
3. Functional Programming (no mutable state)
4. Separate State and Identity (Clojure)
5. Data Parallelism (something about GPU's)
6. Lambda Architecture (map/reduce on streams apparently)
7. Tuple Spaces (all the rage 13 years ago)

I don't have any experience with 5 and 6. The rest seem pretty straight 
forward.


On Sunday, September 29, 2013 9:16:46 AM UTC-4, sailor...@gmail.com wrote:
>
> What are those 7 models ?
>
>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [ANN] 美味しいClojure

2013-10-03 Thread Raoul Duke
an olide: http://www.starling-software.com/en/tsac.html. i went once
when in town years back. it was fun. wish it were still going on.

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: my first clojure "wat" moment - misunderstanding or bug?

2013-10-03 Thread Elias Zaretsky
James, I was surprised myself that I knew the answer. I had a guess as to 
the origin of this information so I Googled to confirm. The problem was 
mentioned in one of the Java Puzzlers [1] talks [2] by Joshua Bloch and Bob 
Lee. The same issue was also discussed on Stack Overflow [3] (which I 
discovered in the process of the aforementioned Googling).

[1] http://www.javapuzzlers.com/
[2] 
http://strangeloop2010.com/system/talks/presentations/000/014/450/BlochLee-JavaPuzzlers.pdf?1290462274
 
- See puzzle #5
[3] 
http://stackoverflow.com/questions/8630279/why-cant-i-hold-enummap-entries-via-a-for-loop-even-if-i-use-final-best-w

Thanks,
Elias.

On Thursday, October 3, 2013 5:29:24 AM UTC-4, James Warren wrote:
>
> Thank you for your responses, Marek and Elias.
>
> Elias, you hit it square on the head - I was using Java 6, and changing to 
> Java 7 corrected the issue. If you don't mind me asking, how did you even 
> know about this behavior? This isn't the type of information you typically 
> see on Hacker News, albeit much more helpful! :)
>
> On Wednesday, October 2, 2013 7:17:40 PM UTC-7, Elias Zaretsky wrote:
>>
>> Are you using Java 6 by any chance? This issue may be due to a gotcha in 
>> java.util.EnumMap. The implementation of the entry set iterator in EnumMap 
>> in Java 6 is unorthodox [1]. Its next() method always returns the same 
>> object, which is mutated to "point" to different entries in the map as the 
>> iterator moves forward. This explains the behavior you are observing. Try 
>> switching to Java 7 or make sure you call the keys function every time you 
>> need the sequence of keys.
>>
>> [1] 
>> http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/EnumMap.java#EnumMap.EntryIterator
>>
>> Thanks,
>> Elias.
>>
>> On Wednesday, October 2, 2013 5:19:31 PM UTC-4, James Warren wrote:
>>>
>>> I've been using Clojure for a couple months, so while I feel comfortable 
>>> with it, I'm not certain whether some unusual behavior I encountered is a 
>>> bug or a lack of understanding on my part.  (I suspect the latter.)
>>>
>>> The context arose from using Clojure reflection to inspect a class 
>>> generated by Apache Thrift . Such classes 
>>> have a static, unmodifiable map describing the members of the class. I 
>>> wrote a function to extract the keys of this map; it initially appears to 
>>> work, but "def"ing the results to a symbol and repeatedly using that symbol 
>>> returns inconsistent results.
>>>
>>> I've boiled it down to a smaller example that replicates the result: (gist 
>>> available )
>>>
>>> // Java class
>>>
>>> public class DummyClass {
>>> public enum DummyEnum {
>>> FIRST, SECOND, THIRD
>>>   }
>>>  
>>>   public static final Map dummyMap;
>>>   static {
>>> Map tmpMap = new EnumMap>> String>(DummyEnum.class);
>>> tmpMap.put(DummyEnum.FIRST, "first");
>>> tmpMap.put(DummyEnum.SECOND, "second");
>>> tmpMap.put(DummyEnum.THIRD, "third");
>>> dummyMap = Collections.unmodifiableMap(tmpMap);
>>>   }
>>> }
>>>
>>> // Clojure ns
>>>
>>> (ns refbug.core
>>>   (:import [refbug DummyClass]))
>>>  
>>> (defn foo [^Class c]
>>> ;; note: (into [] (keys (clojure.lang.Reflector/getStaticField c 
>>> "dummyMap" works
>>>   (keys (clojure.lang.Reflector/getStaticField c "dummyMap")))
>>>  
>>> (def m (foo DummyClass))
>>> (println m)
>>> ;; (# # #)
>>> (println m)
>>> ;; (# # #)
>>>
>>> Two different values upon successive calls using m.  Is this expected?  And 
>>> if so, why?
>>>
>>> Many thanks,
>>> -James
>>>
>>>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Problems starting with Clojure and Leiningen and Light Table

2013-10-03 Thread Gary Verhaegen
That is because the repl is specific to a given project, so there would not
be much point in a general shortcut (or it would require more work than
juste wrapping the commandline repl, such as a gui to beowse the filesystem
to a given project).

You have to start the repl from the root folder of your project. Then the
repl loads all of the code from your project and can actually work as it is
intended.

On Thursday, 3 October 2013, Zeynel wrote:

> Ok. I created a project and there is core.clj file and I also ran the
> failing tests included in the project file. One thing I noticed the
> installer didn't do is that it did not put a shortcut to closure REPL on
> the start menu. I am just starting the windows command line from the start
> menu.
>
>
> On Wednesday, October 2, 2013 12:41:12 PM UTC-4, Peter Mancini wrote:
>>
>> Ok, so you did not get lein working. If it were working you would not
>> have problems creating a new project. I know you are eager to press
>> forward. Admirable. However, it is what we call initiative without
>> judgement. In the world of engineering that is considered ill-advised. So,
>> lets get back to square 1.
>>
>> Delete everything involving lein from your machine. Purge your path and
>> other env variables of it as well. Start again.
>>
>> First, validate you have Java 7.
>>
>> Second, follow this again, to the letter. http://leiningen-win-**
>> installer.djpowell.net/ 
>>
>> Third create a new project with "lein new myproject". Change directory to
>> myproject/src/myproject and see if it created a core.clj file.
>>
>> If anything fails return to that step and look to see what the issue is.
>> You have to be more methodical. Every time you make more than one change
>> you create branching error probabilities. Do that 3 times and you have 8
>> times as many possible root causes for errors. Do it more and the
>> perplexity increases geometrically.
>>
>  --
> --
> 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 'clojure@googlegroups.com');>
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com  'clojure%2bunsubscr...@googlegroups.com');>
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com  'clojure%2bunsubscr...@googlegroups.com');>.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: I could use some help getting "nrepl-ritz" working

2013-10-03 Thread Stephen Cagle
I can actually get ritz to load without error in emacs by using the 
aforementioned website's instructions and then, after ritz is pulled, going 
into  .emacs.d/elpa/nrepl-ritz-20130516.1339/nrepl-ritz.el and 
M-x replace-string RET nrepl-mode-map RET nrepl-repl-mode-map

Why? Not really sure.

On Monday, September 30, 2013 11:07:56 PM UTC-7, Stephen Cagle wrote:
>
> Basically, I get a error when I try to follow the directions at 
> http://ianeslick.com/2013/05/17/clojure-debugging-13-emacs-nrepl-and-ritz/ . 
> In my init.el, I get a error when evaluating: 
> *(require 'nrepl-ritz) ;;after (require 'nrepl)*
>
> the error is:
> *Debugger entered--Lisp error: (void-variable nrepl-mode-map)*
> *  byte-code("\302 \303\304#\210\302 \305\304#\207" 
> [nrepl-interaction-mode-map nrepl-mode-map define-key [3 134217844] 
> nrepl-ritz-threads [3 134217844]] 4)*
> *  require(nrepl-ritz)*
> *  eval((require (quote nrepl-ritz)) nil)*
> *  eval-last-sexp-1(nil)*
> *  eval-last-sexp(nil)*
> *  call-interactively(eval-last-sexp nil nil)*
>
> clearly, it has no idea what nrepl-mode-map is.  Why this is I do not know.
>
> The rest of this message is just all the things I could think of that you 
> might ask, and the contents of my init.el and profiles.clj file. If you 
> know what problem I am having already, there is  no reason to read it. I am 
> just trying to preemptively guess what you will ask.
>
> This is the warning when I start up emacs:
>
> *Warning (initialization): An error occurred while loading 
> `/home/stephen/.emacs.d/init.el':*
> *
> *
> *Symbol's value as variable is void: nrepl-mode-map*
> *
> *
> *To ensure normal operation, you should investigate and remove the*
> *cause of the error in your initialization file.  Start Emacs with*
> *the `--debug-init' option to view a complete error backtrace.*
>
> My emacs version is:
> M-x emacs-version => *GNU Emacs 24.3.1 (x86_64-pc-linux-gnu, GTK+ Version 
> 3.6.4) of 2013-08-22 on menkib, modified by Debian*
>
> I have the following in my ~/.lein/profile.clj
> *{:user {:plugins [;; [lein-marginalia "0.7.1"]*
> *  ;; [lein-try "0.3.1"]*
> *  ;; [lein-pprint "1.1.1"]*
> *  ;; [lein-ancient "0.4.4"]*
> *  ;; [lein-bikeshed "0.1.3"]*
> *  ;; [lein-cljsbuild "0.3.3"]*
> *  ;; [lein-ring "0.8.7"]*
> *  ;; [com.keminglabs/cljx "0.3.0"]*
> *  [lein-ritz "0.7.0"]]*
> *:dependencies [[nrepl-inspect "0.3.0"]*
> *   [ritz/ritz-nrepl-middleware "0.7.0"]]*
> *:repl-options {:nrepl-middleware*
> *   [inspector.middleware/wrap-inspect*
> *ritz.nrepl.middleware.javadoc/wrap-javadoc*
> *
> ritz.nrepl.middleware.simple-complete/wrap-simple-complete]}}}*
> *
> *
> and the folowing ~/.emacs.d/init.el file:
> *
> *
> *;;;-*
> *; From http://clojure.roboloco.net/?tag=paredit*
> *
> *
> *(setq inhibit-startup-message t) ;; No splash screen*
> *;; (setq initial-scratch-message nil) ;; No scratch message*
> *;; (tool-bar-mode nil) ;; No toolbars*
> *;; Create backup files in .emacs-backup instead of everywhere*
> *(defvar user-temporary-file-directory "~/.emacs-backup")*
> *(make-directory user-temporary-file-directory t)*
> *(setq backup-by-copying t)*
> *(setq backup-directory-alist*
> *  `(("." . ,user-temporary-file-directory)*
> * (,tramp-file-name-regexp nil)))*
> *(setq auto-save-list-file-prefix*
> *  (concat user-temporary-file-directory ".auto-saves-"))*
> *(setq auto-save-file-name-transforms*
> *  `((".*" ,user-temporary-file-directory t)))*
> *
> *
> *(set-face-attribute 'default nil :height 110)*
> *; http://www.emacswiki.org/emacs/ShowParenMode*
> *(require 'paren)*
> *(set-face-background 'show-paren-match-face (face-background 'default))*
> *(set-face-foreground 'show-paren-match-face "#0f0")*
> *(set-face-attribute 'show-paren-match-face nil :weight 'extra-bold)*
> *(show-paren-mode 1)*
> *
> *
> *;;;-*
> *
> *
> *(require 'package)*
> *(add-to-list 'package-archives*
> * '("marmalade" . "http://marmalade-repo.org/packages/";)*
> *  '("melpa" . "http://melpa.milkbox.net/packages/";))*
> *(package-initialize)*
> *
> *
> *(defvar my-packages '(;starter-kit*
> *  ;starter-kit-lisp*
> *  ;starter-kit-bindings*
> *  ;starter-kit-eshell*
> *   ac-nrepl*
> *  clojure-mode*
> *   clojure-test-mode*
> *
> *
> *  nrepl*
> *   nrepl-ritz*
> *   rainbow-delimiters*
> *   paredit*
> *   ))*
> *
> *
> *(dolist (p my-packages)*
> *  (when (not (package-installed-p p))*
> *(package-install p)))*
> *
> *
> *; from 
> http://ianeslick.com/2013/05/17/clojure-debugging-13-emacs-nrepl

Re: I could use some help getting "nrepl-ritz" working

2013-10-03 Thread Charles Comstock
So nrepl-mode was just renamed to nrepl-repl-mode, so nrepl-mode-map is 
likely now nrepl-repl-mode-map. My presumption is that this breaks 
compatability with nrepl-ritz. I don't understand why the rename happened 
either. But yea that should fix it.

https://github.com/clojure-emacs/nrepl.el/commit/1d92c44ed6e9a75ea60233b4afb638fa38e0bcf3

Charles Comstock

On Thursday, October 3, 2013 3:01:05 PM UTC-5, Stephen Cagle wrote:
>
> I can actually get ritz to load without error in emacs by using the 
> aforementioned website's instructions and then, after ritz is pulled, going 
> into  .emacs.d/elpa/nrepl-ritz-20130516.1339/nrepl-ritz.el and 
> M-x replace-string RET nrepl-mode-map RET nrepl-repl-mode-map
>
> Why? Not really sure.
>
> On Monday, September 30, 2013 11:07:56 PM UTC-7, Stephen Cagle wrote:
>>
>> Basically, I get a error when I try to follow the directions at 
>> http://ianeslick.com/2013/05/17/clojure-debugging-13-emacs-nrepl-and-ritz/ . 
>> In my init.el, I get a error when evaluating: 
>> *(require 'nrepl-ritz) ;;after (require 'nrepl)*
>>
>> the error is:
>> *Debugger entered--Lisp error: (void-variable nrepl-mode-map)*
>> *  byte-code("\302 \303\304#\210\302 \305\304#\207" 
>> [nrepl-interaction-mode-map nrepl-mode-map define-key [3 134217844] 
>> nrepl-ritz-threads [3 134217844]] 4)*
>> *  require(nrepl-ritz)*
>> *  eval((require (quote nrepl-ritz)) nil)*
>> *  eval-last-sexp-1(nil)*
>> *  eval-last-sexp(nil)*
>> *  call-interactively(eval-last-sexp nil nil)*
>>
>> clearly, it has no idea what nrepl-mode-map is.  Why this is I do not 
>> know.
>>
>> The rest of this message is just all the things I could think of that you 
>> might ask, and the contents of my init.el and profiles.clj file. If you 
>> know what problem I am having already, there is  no reason to read it. I am 
>> just trying to preemptively guess what you will ask.
>>
>> This is the warning when I start up emacs:
>>
>> *Warning (initialization): An error occurred while loading 
>> `/home/stephen/.emacs.d/init.el':*
>> *
>> *
>> *Symbol's value as variable is void: nrepl-mode-map*
>> *
>> *
>> *To ensure normal operation, you should investigate and remove the*
>> *cause of the error in your initialization file.  Start Emacs with*
>> *the `--debug-init' option to view a complete error backtrace.*
>>
>> My emacs version is:
>> M-x emacs-version => *GNU Emacs 24.3.1 (x86_64-pc-linux-gnu, GTK+ 
>> Version 3.6.4) of 2013-08-22 on menkib, modified by Debian*
>>
>> I have the following in my ~/.lein/profile.clj
>> *{:user {:plugins [;; [lein-marginalia "0.7.1"]*
>> *  ;; [lein-try "0.3.1"]*
>> *  ;; [lein-pprint "1.1.1"]*
>> *  ;; [lein-ancient "0.4.4"]*
>> *  ;; [lein-bikeshed "0.1.3"]*
>> *  ;; [lein-cljsbuild "0.3.3"]*
>> *  ;; [lein-ring "0.8.7"]*
>> *  ;; [com.keminglabs/cljx "0.3.0"]*
>> *  [lein-ritz "0.7.0"]]*
>> *:dependencies [[nrepl-inspect "0.3.0"]*
>> *   [ritz/ritz-nrepl-middleware "0.7.0"]]*
>> *:repl-options {:nrepl-middleware*
>> *   [inspector.middleware/wrap-inspect*
>> *ritz.nrepl.middleware.javadoc/wrap-javadoc*
>> *
>> ritz.nrepl.middleware.simple-complete/wrap-simple-complete]}}}*
>> *
>> *
>> and the folowing ~/.emacs.d/init.el file:
>> *
>> *
>> *;;;-*
>> *; From http://clojure.roboloco.net/?tag=paredit*
>> *
>> *
>> *(setq inhibit-startup-message t) ;; No splash screen*
>> *;; (setq initial-scratch-message nil) ;; No scratch message*
>> *;; (tool-bar-mode nil) ;; No toolbars*
>> *;; Create backup files in .emacs-backup instead of everywhere*
>> *(defvar user-temporary-file-directory "~/.emacs-backup")*
>> *(make-directory user-temporary-file-directory t)*
>> *(setq backup-by-copying t)*
>> *(setq backup-directory-alist*
>> *  `(("." . ,user-temporary-file-directory)*
>> * (,tramp-file-name-regexp nil)))*
>> *(setq auto-save-list-file-prefix*
>> *  (concat user-temporary-file-directory ".auto-saves-"))*
>> *(setq auto-save-file-name-transforms*
>> *  `((".*" ,user-temporary-file-directory t)))*
>> *
>> *
>> *(set-face-attribute 'default nil :height 110)*
>> *; http://www.emacswiki.org/emacs/ShowParenMode*
>> *(require 'paren)*
>> *(set-face-background 'show-paren-match-face (face-background 'default))*
>> *(set-face-foreground 'show-paren-match-face "#0f0")*
>> *(set-face-attribute 'show-paren-match-face nil :weight 'extra-bold)*
>> *(show-paren-mode 1)*
>> *
>> *
>> *;;;-*
>> *
>> *
>> *(require 'package)*
>> *(add-to-list 'package-archives*
>> * '("marmalade" . "http://marmalade-repo.org/packages/";)*
>> *  '("melpa" . "http://melpa.milkbox.net/packages/";))*
>> *(package-initialize)*
>> *
>> *
>> *(defvar my-packages '(;star

Re: [ANN] 美味しいClojure

2013-10-03 Thread Dave Della Costa
2010...bummer!  That sounds really interesting.

(2013/10/03 22:24), Raoul Duke wrote:
> an olide: http://www.starling-software.com/en/tsac.html. i went once
> when in town years back. it was fun. wish it were still going on.
> 

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [ANN] 美味しいClojure

2013-10-03 Thread Dave Della Costa
Ambrose, you're in Tokyo??

In any case, Alan, that sounds great and I'm definitely interested.  It
would be wonderful if we could keep it integrated somehow with the
Tokyo.clj folks--I know that a lot of Japanese devs want to speak and
hear more English, and I know that a good number of expats speak
Japanese, so maybe we could do some kind of joint thing.  The Ruby group
I joined a few times had that sort of setup and it was great for
cultural exchange (both in terms of ethnic culture and programming
community culture).

But whatever the case may be, I'm certainly interested and would love to
get more involved with the Clojure community here.  I would certainly be
interested in giving a talk too, or putting together some sort of
workshop or something if that appealed.  And I'd love to hear more about
core.typed from Ambrose!

Best,
Dave

(2013/10/03 16:43), Ambrose Bonnaire-Sergeant wrote:
> Me! :)
> 
> Ambrose
> 
> 
> On Thu, Oct 3, 2013 at 3:07 PM, Alan Busby  > wrote:
> 
> Hi Dave,
> 
> Regarding Clojure events in Tokyo, I'm only aware of Tokyo.clj at
> the moment and it's held in Japanese. It sounds like we have a few
> expats here in Tokyo using Clojure though, so it might be worth
> putting something together (in English?).
> 
> I can likely host something at the Gracenote office here in Shibuya
> if there is enough interest. If schedules work out Mr. Ambrose may
> be able to give us a quick intro / Q+A on core.typed as well.
> 
> Anyone interested?
> 
> 
> Thanks,
>Alan Busby
> 
> 
> 
> On Thu, Oct 3, 2013 at 2:32 PM, Dave Della Costa
> mailto:ddellaco...@gmail.com>> wrote:
> 
> Speaking of, is there anything other than Tokyo.clj (which seems
> pretty
> infrequent based on this: http://atnd.org/event/tokyoclj) going
> on for
> Clojurians in Tokyo?   I work remotely, using Clojure, and would
> love to
> get together more frequently with other Clojure developers if
> possible.
>  If anyone is interested in doing something like co-working on a
> more
> regular basis, let me know!
> 
> Cheers,
> DD
> 
> (2013/10/03 9:44), Alan Busby wrote:
> > On Thu, Oct 3, 2013 at 9:30 AM, Marek Kubica
> mailto:ma...@xivilization.net>
> >  >> wrote:
> >
> > On Tue, 1 Oct 2013 22:01:02 -0700 (PDT)
> > Nicolas Modrzyk    >>
> > wrote:
> >
> > > The whole text has also been written in English, so I
> guess there
> > > could be a chance to put it out there.
> > > But we have had no contacts with US/UK publishers so far.
> >
> > Did you try the usual suspects like O'Reilly or PragProg?
> They are
> > surprisingly approachable.
> >
> >
> > The O'Reilly Tokyo office is on the ground floor of where
> Tokyo.clj is
> > hosted too!
> >
> > --
> > --
> > 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 email to
> > clojure+unsubscr...@googlegroups.com
> 
> > For more options, visit this group at
> > http://groups.google.com/group/clojure?hl=en
> > ---
> > You received this message because you are subscribed to the Google
> > Groups "Clojure" group.
> > To unsubscribe from this group and stop receiving emails from
> it, send
> > an email to clojure+unsubscr...@googlegroups.com
> .
> > For more options, visit https://groups.google.com/groups/opt_out.
> 
> --
> --
> 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 email to
> clojure+unsubscr...@googlegroups.com
> 
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message bec

Re: [ANN] 美味しいClojure

2013-10-03 Thread Ambrose Bonnaire-Sergeant
Only through the magic of the internet! I'll be giving a video conference
talk + QA.

Ambrose


On Fri, Oct 4, 2013 at 8:54 AM, Dave Della Costa wrote:

> Ambrose, you're in Tokyo??
>
> In any case, Alan, that sounds great and I'm definitely interested.  It
> would be wonderful if we could keep it integrated somehow with the
> Tokyo.clj folks--I know that a lot of Japanese devs want to speak and
> hear more English, and I know that a good number of expats speak
> Japanese, so maybe we could do some kind of joint thing.  The Ruby group
> I joined a few times had that sort of setup and it was great for
> cultural exchange (both in terms of ethnic culture and programming
> community culture).
>
> But whatever the case may be, I'm certainly interested and would love to
> get more involved with the Clojure community here.  I would certainly be
> interested in giving a talk too, or putting together some sort of
> workshop or something if that appealed.  And I'd love to hear more about
> core.typed from Ambrose!
>
> Best,
> Dave
>
> (2013/10/03 16:43), Ambrose Bonnaire-Sergeant wrote:
> > Me! :)
> >
> > Ambrose
> >
> >
> > On Thu, Oct 3, 2013 at 3:07 PM, Alan Busby  > > wrote:
> >
> > Hi Dave,
> >
> > Regarding Clojure events in Tokyo, I'm only aware of Tokyo.clj at
> > the moment and it's held in Japanese. It sounds like we have a few
> > expats here in Tokyo using Clojure though, so it might be worth
> > putting something together (in English?).
> >
> > I can likely host something at the Gracenote office here in Shibuya
> > if there is enough interest. If schedules work out Mr. Ambrose may
> > be able to give us a quick intro / Q+A on core.typed as well.
> >
> > Anyone interested?
> >
> >
> > Thanks,
> >Alan Busby
> >
> >
> >
> > On Thu, Oct 3, 2013 at 2:32 PM, Dave Della Costa
> > mailto:ddellaco...@gmail.com>> wrote:
> >
> > Speaking of, is there anything other than Tokyo.clj (which seems
> > pretty
> > infrequent based on this: http://atnd.org/event/tokyoclj) going
> > on for
> > Clojurians in Tokyo?   I work remotely, using Clojure, and would
> > love to
> > get together more frequently with other Clojure developers if
> > possible.
> >  If anyone is interested in doing something like co-working on a
> > more
> > regular basis, let me know!
> >
> > Cheers,
> > DD
> >
> > (2013/10/03 9:44), Alan Busby wrote:
> > > On Thu, Oct 3, 2013 at 9:30 AM, Marek Kubica
> > mailto:ma...@xivilization.net>
> > >  > >> wrote:
> > >
> > > On Tue, 1 Oct 2013 22:01:02 -0700 (PDT)
> > > Nicolas Modrzyk  >   > >>
> > > wrote:
> > >
> > > > The whole text has also been written in English, so I
> > guess there
> > > > could be a chance to put it out there.
> > > > But we have had no contacts with US/UK publishers so far.
> > >
> > > Did you try the usual suspects like O'Reilly or PragProg?
> > They are
> > > surprisingly approachable.
> > >
> > >
> > > The O'Reilly Tokyo office is on the ground floor of where
> > Tokyo.clj is
> > > hosted too!
> > >
> > > --
> > > --
> > > 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 email to
> > > clojure+unsubscr...@googlegroups.com
> > 
> > > For more options, visit this group at
> > > http://groups.google.com/group/clojure?hl=en
> > > ---
> > > You received this message because you are subscribed to the
> Google
> > > Groups "Clojure" group.
> > > To unsubscribe from this group and stop receiving emails from
> > it, send
> > > an email to clojure+unsubscr...@googlegroups.com
> > .
> > > For more options, visit
> https://groups.google.com/groups/opt_out.
> >
> > --
> > --
> > 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 member

Re: [ANN] 美味しいClojure

2013-10-03 Thread Takahiro SAWADA
Hi, Alan,

It was nice to meet you at Tokyo.clj held in last August!
We have a nearly monthly meet-up for Lisp in Tokyo, called Shibuya.lisp (
http://shibuya.lisp-users.org/about.html). I have not participated all the 
times but as far as I understand every 3 times Clojure is the main subject 
of the meet-up. The language spoken there is Japanese.
Unfortunately here in Tokyo we have not formed a "tight" community while 
the number of Clojurians is obviously increasing. I am looking for some 
good ways to set-up a core of the community here.

Cheers,
Takahiro SAWADA





2013年10月3日木曜日 16時07分55秒 UTC+9 TheBusby:
>
> Hi Dave,
>
> Regarding Clojure events in Tokyo, I'm only aware of Tokyo.clj at the 
> moment and it's held in Japanese. It sounds like we have a few expats here 
> in Tokyo using Clojure though, so it might be worth putting something 
> together (in English?).
>
> I can likely host something at the Gracenote office here in Shibuya if 
> there is enough interest. If schedules work out Mr. Ambrose may be able to 
> give us a quick intro / Q+A on core.typed as well.
>
> Anyone interested?
>
>
> Thanks,
>Alan Busby
>
>
>
> On Thu, Oct 3, 2013 at 2:32 PM, Dave Della Costa 
> 
> > wrote:
>
>> Speaking of, is there anything other than Tokyo.clj (which seems pretty
>> infrequent based on this: http://atnd.org/event/tokyoclj) going on for
>> Clojurians in Tokyo?   I work remotely, using Clojure, and would love to
>> get together more frequently with other Clojure developers if possible.
>>  If anyone is interested in doing something like co-working on a more
>> regular basis, let me know!
>>
>> Cheers,
>> DD
>>
>> (2013/10/03 9:44), Alan Busby wrote:
>> > On Thu, Oct 3, 2013 at 9:30 AM, Marek Kubica 
>> > 
>> > > wrote:
>> >
>> > On Tue, 1 Oct 2013 22:01:02 -0700 (PDT)
>> > Nicolas Modrzyk  > hell...@gmail.com >>
>> > wrote:
>> >
>> > > The whole text has also been written in English, so I guess there
>> > > could be a chance to put it out there.
>> > > But we have had no contacts with US/UK publishers so far.
>> >
>> > Did you try the usual suspects like O'Reilly or PragProg? They are
>> > surprisingly approachable.
>> >
>> >
>> > The O'Reilly Tokyo office is on the ground floor of where Tokyo.clj is
>> > hosted too!
>> >
>> > --
>> > --
>> > You received this message because you are subscribed to the Google
>> > Groups "Clojure" group.
>> > To post to this group, send email to clo...@googlegroups.com
>> > Note that posts from new members are moderated - please be patient with
>> > your first post.
>> > To unsubscribe from this group, send email to
>> > clojure+u...@googlegroups.com 
>> > For more options, visit this group at
>> > http://groups.google.com/group/clojure?hl=en
>> > ---
>> > You received this message because you are subscribed to the Google
>> > Groups "Clojure" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> > an email to clojure+u...@googlegroups.com .
>> > For more options, visit https://groups.google.com/groups/opt_out.
>>
>> --
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Clojure" group.
>> To post to this group, send email to clo...@googlegroups.com
>> Note that posts from new members are moderated - please be patient with 
>> your first post.
>> To unsubscribe from this group, send email to
>> clojure+u...@googlegroups.com 
>> For more options, visit this group at
>> http://groups.google.com/group/clojure?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups 
>> "Clojure" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to clojure+u...@googlegroups.com .
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [ANN] 美味しいClojure

2013-10-03 Thread Dave Della Costa
Well, that would be mighty fine too. :-)

(2013/10/04 9:57), Ambrose Bonnaire-Sergeant wrote:
> Only through the magic of the internet! I'll be giving a video
> conference talk + QA.
> 
> Ambrose
> 
> 
> On Fri, Oct 4, 2013 at 8:54 AM, Dave Della Costa  > wrote:
> 
> Ambrose, you're in Tokyo??
> 
> In any case, Alan, that sounds great and I'm definitely interested.  It
> would be wonderful if we could keep it integrated somehow with the
> Tokyo.clj folks--I know that a lot of Japanese devs want to speak and
> hear more English, and I know that a good number of expats speak
> Japanese, so maybe we could do some kind of joint thing.  The Ruby group
> I joined a few times had that sort of setup and it was great for
> cultural exchange (both in terms of ethnic culture and programming
> community culture).
> 
> But whatever the case may be, I'm certainly interested and would love to
> get more involved with the Clojure community here.  I would certainly be
> interested in giving a talk too, or putting together some sort of
> workshop or something if that appealed.  And I'd love to hear more about
> core.typed from Ambrose!
> 
> Best,
> Dave
> 
> (2013/10/03 16:43), Ambrose Bonnaire-Sergeant wrote:
> > Me! :)
> >
> > Ambrose
> >
> >
> > On Thu, Oct 3, 2013 at 3:07 PM, Alan Busby  
> > >> wrote:
> >
> > Hi Dave,
> >
> > Regarding Clojure events in Tokyo, I'm only aware of Tokyo.clj at
> > the moment and it's held in Japanese. It sounds like we have a few
> > expats here in Tokyo using Clojure though, so it might be worth
> > putting something together (in English?).
> >
> > I can likely host something at the Gracenote office here in
> Shibuya
> > if there is enough interest. If schedules work out Mr. Ambrose may
> > be able to give us a quick intro / Q+A on core.typed as well.
> >
> > Anyone interested?
> >
> >
> > Thanks,
> >Alan Busby
> >
> >
> >
> > On Thu, Oct 3, 2013 at 2:32 PM, Dave Della Costa
> > mailto:ddellaco...@gmail.com>
> >> wrote:
> >
> > Speaking of, is there anything other than Tokyo.clj (which
> seems
> > pretty
> > infrequent based on this: http://atnd.org/event/tokyoclj)
> going
> > on for
> > Clojurians in Tokyo?   I work remotely, using Clojure, and
> would
> > love to
> > get together more frequently with other Clojure developers if
> > possible.
> >  If anyone is interested in doing something like
> co-working on a
> > more
> > regular basis, let me know!
> >
> > Cheers,
> > DD
> >
> > (2013/10/03 9:44), Alan Busby wrote:
> > > On Thu, Oct 3, 2013 at 9:30 AM, Marek Kubica
> > mailto:ma...@xivilization.net>
> >
> > >  
> >   > >
> > > On Tue, 1 Oct 2013 22:01:02 -0700 (PDT)
> > > Nicolas Modrzyk  
> > >
> 
> >  > > wrote:
> > >
> > > > The whole text has also been written in English, so I
> > guess there
> > > > could be a chance to put it out there.
> > > > But we have had no contacts with US/UK publishers
> so far.
> > >
> > > Did you try the usual suspects like O'Reilly or
> PragProg?
> > They are
> > > surprisingly approachable.
> > >
> > >
> > > The O'Reilly Tokyo office is on the ground floor of where
> > Tokyo.clj is
> > > hosted too!
> > >
> > > --
> > > --
> > > 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
> > 

Re: core.async: communicating termination

2013-10-03 Thread mstump


>
> This brings up another issue: Currently writing to a closed channel is a 
> no-op, but it probably should throw an exception. Similarly, closing a 
> closed channel is a no-op, but also probably should throw an exception. 
> Both are things that a well behaved sender should never do, since they know 
> when they close, so they know not to keep putting stuff in there. Or, they 
> are warned of the impending close by some coordination process & the same 
> rules apply.
>


Sorry to resurrect an old thread, but why not return true on successful 
put, false otherwise? That would allow for the following:

   (loop []
 (let [results (get-metrics metrics)]
   (when (async/>! mchan results)
 (recur

You could terminate blocks simply by closing the channel. You also avoid 
the messy higher order (quit) channel. 

-- 
-- 
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 email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.