<jhass>
unshadow: repository contributors get a notification if you open an issue ;)
<asterite>
hehe, yes. I was actually replying :-)
<unshadow>
True, I'm just impetiant XD sorry
<asterite>
unshadow: I replied ;-)
<unshadow>
hmmm I see, so I need to use the channel to wait untill all my answers are back
<unshadow>
Thanks :):):)
<asterite>
Exactly
mdz_ has joined #crystal-lang
<asterite>
jhass: I think the compiler can figure this out, but the docs don't instantiate classes and methods so that info would be missing
<jhass>
mmh
<jhass>
I think it would be a super awesome feature, definitive list of things I need to handle
<jhass>
though if it's worth the overhead of instantiating everything...
<asterite>
The problem is that the compiler can't figure out how to instantiate things
<unshadow>
asterite: Can I use instead something along array_of_fibers << spawn helper_methoud(1,2,3) ; while array_of_fibers.each {|f| f.dead?} ; run my code; end
<unshadow>
super psudo code
<asterite>
unshadow: nope. I think spawn right now returns the fiber but we'll change it to return nil
<unshadow>
hm... ok, so how can I check if a fiber is alive, dead, closed, sleeping etc ?
<unshadow>
(when i spwan ofcurse)
<asterite>
You can't, you won't have access to the fibers
<asterite>
The only tools you'll have are channels
<asterite>
Why do you need to know that?
<asterite>
By the way, any question you have about spawn and channels, you can search "goroutine" instead of spawn and search answers about Go, it will be like %99 the same
<asterite>
except that we don't have WaitGroup yet, but it's basically the counter channel I showed earlier
leafybasil has joined #crystal-lang
<unshadow>
lets say I'm accepting connections, I want to allow only 50 concurrent connections , in ruby I could do somthing like array_of_threads << thread.new(socket.accept) do blablab; then put all this in a loop that does a check if more then 50 of the threads are alive, if yes then it sleep for 1 sec, or w\e
<asterite>
I think you can do that with a counter and channels
NeverDie has joined #crystal-lang
<asterite>
we might also need atomic counters. As I said, you can probably search how to solve these things in Go to get an idea of how you'll do that in Crystal
<unshadow>
>> a = Fiber.current; a.alive?
<DeBot>
unshadow: Error in line 4: undefined method 'alive?' for Fiber - http://carc.in/#/r/379
<unshadow>
I'll search for it now, thanks asterite
<asterite>
unshadow: Fiber and Thread will be there for us to implement spawn and the scheduler, but eventually won't have access to them. Again, you'll only have spawn and channels at your disposal :-)
<asterite>
So bad, you can do `npm install -g crystal`, what's the point of a homebrew formula for that...
<BlaXpirit>
they'd remove wiki article anyway
<BlaXpirit>
nim barely survived on wikipedia, and, disregarding stars on github, i think nim is much more popular and has many more references to it
<jhass>
BlaXpirit: you confuse it with the german wikipedia ;P
<unshadow>
well, send him an email, use some spearphishing techniques, get hes homebrew account, close the project, win :)
<unshadow>
joking of curse XD
<asterite>
BlaXpirit: I don't understand why Wikipedia doesn't like Nim… that's one of the reasons I wouldn't bother adding Crystal to it
<jhass>
shit, TIL setarch
<unshadow>
Just asking, I'm starting to work on converting rubyntlm(https://github.com/WinRb/rubyntlm) to Crystal , no one is doing something similar right ?
jua_ has joined #crystal-lang
<asterite>
unshadow: I doubt it… it's also related to Windows, which makes it less likely
<crystal-gh>
[crystal] waj pushed 1 new commit to master: http://git.io/vLLsI
<crystal-gh>
crystal/master 0595487 Juan Wajnerman: Homebrew formula is now named "crystal-lang"
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
<unshadow>
asterite: this is very important for NTLM auth, which in turn is importent for web frameworks, web clients etc... but I get your drift ;) I'll convert and publish :)
<unshadow>
how long back are you saving the data ?
<jhass>
2256 (53.8%) are successful (exit code 0)
<jhass>
so far for eternity
<jhass>
asterite: http://carc.in/#/r/38b could use better "don't use a keyword" indication
<unshadow>
datanoise: How do you feel about the state of openssl.cr ? I could really use digest for my NTLM convert, do you think this is stable enough to be merged into crystal ?
<unshadow>
jhass: yeha, fun can be missleading in this context
<datanoise>
unshadow: i'm planning to add DH soon and some other features. what stops you from using it as an exteranl lib?
<travis-ci>
manastech/crystal#2481 (master - 0595487 : Juan Wajnerman): The build was broken.
<unshadow>
datanoise: nothing tbh, I just want to refrain from Projectfile with github datanoise/openssl.cr , so people could use it without any additional libs, but it's not really that big of an issue
<unshadow>
datanoise: also, did you plan to add DEC ? that could be awsome
<unshadow>
(brb i'll follow logs :))
unshadow has quit [Quit: leaving]
<vikaton>
kinda funny how during Ober's talk on Crystal there was a compiler bug xP
<vikaton>
>> x -> { puts "test" }; x.call
<DeBot>
vikaton: Error in line 4: undefined method 'x' (did you mean 'p'?) - http://carc.in/#/r/38i
NeverDie has joined #crystal-lang
<datanoise>
unshadow: what is DEC?
<vikaton>
I forgot how anonymous functions work :(