Changes for clojure.core/future

luke on Wed, 05 Sep 2012
;; A future's calculation is started here and it runs in another thread
user=> (def f (future (Thread/sleep 10000) (println "done") 100))
#'user/f
;;if you wait 10 seconds before dereferencing it you'll see "done"

;; When you dereference it you will block until the result is available.
user=> @f
done
100

;; Dereferencing again will return the already calculated value.
=> @f
100
yayitswei on Wed, 05 Sep 2012
;; A future's calculation is started here and it runs in another thread
user=> (def f (future (Thread/sleep 10000) (println "done")) 100)
#'user/f
;;if you wait 10 seconds before dereferencing it you'll see "done"

;; When you dereference it you will block until the result is available.
user=> @f
done
100

;; Dereferencing again will return the already calculated value.
=> @f
100
azkesz on Fri, 31 Aug 2012
;; A future's calculation is started here and it runs in another thread
user=> (def f (future (do (Thread/sleep 10000) (println "done")) 100))
#'user/f
;;if you wait 10 seconds before dereferencing it you'll see "done"

;; When you dereference it you will block until the result is available.
user=> @f
done
100

;; Dereferencing again will return the already calculated value.
=> @f
100
azkesz on Fri, 31 Aug 2012
;; A future is calculated is started here and it runs in another thread
user=> (def f (future (do (Thread/sleep 10000) (println "done")) 100))
#'user/f
;;if you wait 10 seconds before dereferencing it you'll see "done"

;; When you dereference it you will block until the result is available.
user=> @f
done
100

;; Dereferencing again will return the already calculated value.
=> @f
100
azkesz on Thu, 30 Aug 2012
;; A future is calculated in another thread
user=> (def f (future (do (Thread/sleep 10000) (println "done")) 100))
#'user/f

;; When you dereference it you will block until the result is available.
user=> @f
done
100

;; Dereferencing again will return the already calculated value.
=> @f
100
zkim on Sun, 26 Sep 2010
;; A future is calculated in another thread
user=> (def f (future (Thread/sleep 10000) 100))
#'user/f

;; When you dereference it you will block until the result is available.
user=> @f
100

;; Dereferencing again will return the already calculated value.
gstamp on Thu, 05 Aug 2010
A future is calculated in another thread

user=> (def f (future (Thread/sleep 10000) 100))
#'user/f

When you dereference it you will block until the result is available.

user=> @f
100

Dereferencing again will return the already calculated value.