/examples/thread_safety.fy
Unknown | 14 lines | 11 code | 3 blank | 0 comment | 0 complexity | 7a10396672a0616aad6e10a1071402b3 MD5 | raw file
Possible License(s): BSD-3-Clause
1require: "redis" 2 3r = Redis Client new 4 5threads = [] 610 times: |i| { 7 t = Thread new: { 8 r set: ("foo", "test: #{i}") 9 r get: "foo" . println 10 } 11 threads << t 12} 13 14threads each: 'join