RX14 changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.24.1 | Fund Crystal's development: http://is.gd/X7PRtI | GH: https://github.com/crystal-lang/crystal | Docs: http://crystal-lang.org/docs/ | API: http://crystal-lang.org/api/ | Gitter: https://gitter.im/crystal-lang/crystal
maattdd_ has joined #crystal-lang
maattdd_ has quit [Ping timeout: 245 seconds]
<FromGitter> <bew> @genericpenguin you don't need the `()` when they are empty, and you also don't need the `|i|` and `|j|` as you don't use it
<FromGitter> <genericpenguin> Good to know. Thanks
guy has joined #crystal-lang
guy has quit [Ping timeout: 260 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 248 seconds]
hightower3 has joined #crystal-lang
hightower2 has quit [Ping timeout: 252 seconds]
wojnar has joined #crystal-lang
learod has joined #crystal-lang
learod has quit [Remote host closed the connection]
learod has joined #crystal-lang
rohitpaulk has joined #crystal-lang
learod has quit [Ping timeout: 240 seconds]
wojnar has quit [Quit: Leaving]
alex`` has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
Qchmqs__ has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 252 seconds]
Qchmqs__ is now known as Qchmqs
alex`` has quit [Ping timeout: 245 seconds]
alex`` has joined #crystal-lang
Qchmqs has left #crystal-lang ["Konversation terminated!"]
rohitpaulk has joined #crystal-lang
alex`` has quit [Ping timeout: 240 seconds]
alex`` has joined #crystal-lang
Papierkorb has joined #crystal-lang
learod has joined #crystal-lang
learod has quit [Remote host closed the connection]
learod has joined #crystal-lang
learod has quit [Ping timeout: 248 seconds]
Papierkorb has left #crystal-lang ["Konversation terminated!"]
learod has joined #crystal-lang
learod has quit [Remote host closed the connection]
learod has joined #crystal-lang
learod has quit [Remote host closed the connection]
<crystal-gh> [crystal] j8r closed pull request #5718: Keep empty sections when parsing INI (master...keep_empty_ini_sections) https://git.io/vA3eQ
learod has joined #crystal-lang
learod has quit [Remote host closed the connection]
learod has joined #crystal-lang
learod has quit [Ping timeout: 256 seconds]
bonemind has joined #crystal-lang
wojnar has joined #crystal-lang
wojnar has quit [Quit: Leaving]
wojnar has joined #crystal-lang
learod has joined #crystal-lang
wojnar has quit [Client Quit]
wojnar has joined #crystal-lang
learod has quit [Remote host closed the connection]
learod has joined #crystal-lang
learod has quit [Remote host closed the connection]
learod has joined #crystal-lang
duane has joined #crystal-lang
learod has quit []
maattdd_ has joined #crystal-lang
duane has quit [Ping timeout: 256 seconds]
sz0 has joined #crystal-lang
duane has joined #crystal-lang
bonemind has quit [Quit: WeeChat 2.0.1]
olbat__ has joined #crystal-lang
thews_ has joined #crystal-lang
cyberarm_ has joined #crystal-lang
cyberarm has quit [*.net *.split]
olbat has quit [*.net *.split]
Cyrus has quit [*.net *.split]
thews has quit [*.net *.split]
lvmbdv has quit [*.net *.split]
emancu has joined #crystal-lang
Cyrus has joined #crystal-lang
Cyrus is now known as Guest1156
lvmbdv has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 276 seconds]
duane has quit [Ping timeout: 240 seconds]
duane has joined #crystal-lang
<FromGitter> <philfine> Do unit tests timeout ?
<FromGitter> <philfine> I mean, I want to make a test that it might block in some Fiber
sz0 has quit [Quit: Connection closed for inactivity]
<FromGitter> <philfine> @hightower2 ... I got it a little further
<FromGitter> <philfine> Because, previous implementation would suffer from a sort of race as only listen would register the interest in the event
<FromGitter> <philfine> Posting the changes
maattdd_ has quit [Ping timeout: 240 seconds]
<crystal-gh> [crystal] j8r reopened pull request #5718: Keep empty sections when parsing INI (master...keep_empty_ini_sections) https://git.io/vA3eQ
qard has joined #crystal-lang
qard has quit [Client Quit]
qard has joined #crystal-lang
kosmonaut has joined #crystal-lang
kosmonaut has quit [Quit: Ping timeout (120 seconds)]
DeBot has quit [Ping timeout: 276 seconds]
DeBot has joined #crystal-lang
Liothen has quit [Ping timeout: 252 seconds]
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
qard has joined #crystal-lang
Liothen has joined #crystal-lang
Liothen has joined #crystal-lang
<FromGitter> <philfine> BTW, I just realized that in some more event obscure situation you need to define the channels with more capacity
duane has quit [Ping timeout: 260 seconds]
duane has joined #crystal-lang
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rohitpaulk has joined #crystal-lang
ephemera__ has quit [Quit: No Ping reply in 180 seconds.]
ephemera_ has joined #crystal-lang
qard has joined #crystal-lang
emancu has quit []
duane has quit [Ping timeout: 276 seconds]
rohitpaulk has quit [Ping timeout: 240 seconds]
pta2002 has joined #crystal-lang
duane has joined #crystal-lang
shalmezad has joined #crystal-lang
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<FromGitter> <philfine> New attempt to refurbish the EvenHandler ... need help with this: https://play.crystal-lang.org/#/r/3noq
Ven`` has joined #crystal-lang
qard has joined #crystal-lang
<FromGitter> <bew> this looks a bit weird, why is are the `@@listeners` on class level, and in the EventType class?
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
qard has joined #crystal-lang
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 260 seconds]
shalmezad has quit [Quit: Leaving]
shalmezad has joined #crystal-lang
<FromGitter> <bew> also why not simply use a Channel?
<FromGitter> <bew> @philfine and if you want to have multiple listeners, channels works too: https://carc.in/#/r/3nos
duane has quit [Ping timeout: 256 seconds]
duane has joined #crystal-lang
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
qard has joined #crystal-lang
<FromGitter> <philfine> @bew, what happens if one of the listeners is not on the receive
<FromGitter> <philfine> Will the message be lost ?
<FromGitter> <philfine> For that listener ?
<FromGitter> <philfine> Oh, the intent is for all listeners to receive the same messages
<FromGitter> <philfine> Not distinct ones
<FromGitter> <bew> oh ok
<FromGitter> <bew> you can use 1 channel for each listeners then
<FromGitter> <philfine> @bew any help with the error ?
<FromGitter> <philfine> HOr how can I fix that ?
<FromGitter> <bew> and then you'd use an EventManager like you were doing...
<FromGitter> <bew> don't use Class ?
<FromGitter> <bew> I tried to understand what you were doing in there, but I couldn't understand from the naming, and what you have inside the classes..
<FromGitter> <bew> for example, why use a Class
<FromGitter> <bew> and can you give an example with 2 handlers, and 2 kind of events?
<FromGitter> <philfine> Sure one moment
<FromGitter> <philfine> I will give same handler and 2 types
<FromGitter> <bew> and also, what is an EventHandler for you?
<FromGitter> <philfine> Your right Event Handler lost meaning with that code
<FromGitter> <philfine> Let me refresh it ...
<FromGitter> <bew> and why is the dispatch in EventType?
<FromGitter> <philfine> Please refer to this code: https://play.crystal-lang.org/#/r/3noe
<FromGitter> <philfine> This is the origins
<FromGitter> <philfine> Sort of
pracabor is now known as robacarp
<FromGitter> <philfine> I think I lost the focus when I changed that code.
<RX14> crystal's new time implementation with 2 values is so shit
<RX14> my predict.cr specs don't pass because of the inaccuracies
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Ven`` has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
qard has joined #crystal-lang
<Yxhvd> was it better before?
<RX14> by far
<FromGitter> <philfine> @RX14 inacuracies in returned time ?
<RX14> it was predicting satellites down to 0.5mm accuracy, now it's 500mm
<Yxhvd> is it fixable or should it be reverted?
<RX14> @philfine no in time calculations
<RX14> Yxhvd, it's just float inprecision
<RX14> where before there were no floats involved
<Yxhvd> -_-
<FromGitter> <philfine> :D
<FromGitter> <philfine> Big mistake ...
<RX14> yes
<Yxhvd> ruby uses a lot of rationals in the time parts IIRC.
<RX14> I complained about it before
<RX14> before we used the number of 0.1us intervals since the year 0000
<Yxhvd> which make it slow as fuck, but accurate
<RX14> now we use two integers
<RX14> seconds since 0000
<RX14> and ns since the last second
<RX14> having 2 integers makes everything harder
<RX14> so we usually give up and do calculations in floats
<RX14> since the added precision to time values suddenly makes our time not fit in 64bit integers
<RX14> it's really annoyying
<FromGitter> <bew> maybe we just need good functions to manipulate those 2 numbers? (so that you don't have to do it yourself, and have to use floats)
<RX14> no
<RX14> we should use i128 ns since 0000
<RX14> lol
<hightower3> Glad to hear I'm not the only one despairing over Time in 0.24.1
<hightower3> (for different reasons, but still :))
<hightower3> On the plus side, I did get to port the code to 0.24... So now https://github.com/docelic/crystime works with 0.24
duane has quit [Ping timeout: 240 seconds]
<RX14> loosing ticks is good
<RX14> because it makes moving back seamless
qard has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
duane has joined #crystal-lang
rohitpaulk has joined #crystal-lang
alex`` has quit [Ping timeout: 240 seconds]
shalmezad has quit [Quit: Leaving]
Ven`` has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 256 seconds]
duane has quit [Ping timeout: 276 seconds]
duane has joined #crystal-lang
<FromGitter> <philfine> What is the cheapest and easiest way to print Float64 with 3 decimals
<FromGitter> <philfine> Sorry for the dumb question
<FromGitter> <philfine> .round(3)
Ven`` has quit [Read error: Connection reset by peer]
sz0 has joined #crystal-lang
Ven`` has joined #crystal-lang
rohitpaulk has joined #crystal-lang
<hightower3> Hey, is there a way to use macros to keep appending to a macro variable, and then another macro do dump the accumulated code/content into some location?
<FromGitter> <bew> Yes
<FromGitter> <bew> But not to a macro variable, you can use constant
<FromGitter> <bew> So declare `MY_CONST = [] of *` and in macros you can use `MY*CONST` to add elements, or traverse the contained elements
<FromGitter> <bew> @hightower3 https://carc.in/#/r/3npv
<hightower3> fabulous, thanks bew
duane has quit [Ping timeout: 256 seconds]
Ven`` has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
andersh has quit [Ping timeout: 265 seconds]
avdi has quit [Ping timeout: 256 seconds]
andersh has joined #crystal-lang
andersh has quit [Max SendQ exceeded]
andersh has joined #crystal-lang
aarongodin has quit [Ping timeout: 260 seconds]
mroth has quit [Ping timeout: 252 seconds]
danzilio has quit [Ping timeout: 255 seconds]
aarongodin has joined #crystal-lang
faustinoaq has joined #crystal-lang
ilovezfs_ has quit [Ping timeout: 256 seconds]
danzilio has joined #crystal-lang
mroth has joined #crystal-lang
danzilio has quit [Max SendQ exceeded]
avdi has joined #crystal-lang
mroth has quit [Max SendQ exceeded]
avdi has quit [Max SendQ exceeded]
mroth has joined #crystal-lang
avdi has joined #crystal-lang
mroth has quit [Max SendQ exceeded]
avdi has quit [Max SendQ exceeded]
danzilio has joined #crystal-lang
ilovezfs_ has joined #crystal-lang
mroth has joined #crystal-lang
manveru has quit [Ping timeout: 256 seconds]
avdi has joined #crystal-lang
danzilio has quit [Max SendQ exceeded]
danzilio has joined #crystal-lang
avdi has quit [Max SendQ exceeded]
avdi has joined #crystal-lang
danzilio has quit [Max SendQ exceeded]
avdi has quit [Max SendQ exceeded]
danzilio has joined #crystal-lang
avdi has joined #crystal-lang
jwaldrip has quit [Ping timeout: 256 seconds]
danzilio has quit [Max SendQ exceeded]
danzilio has joined #crystal-lang
manveru has joined #crystal-lang
manveru has quit [Max SendQ exceeded]
jwaldrip has joined #crystal-lang
manveru has joined #crystal-lang
duane has joined #crystal-lang