ChanServ changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.20.5 | Fund Crystal's development: http://is.gd/X7PRtI | Paste > 3 lines of text to https://gist.github.com | GH: https://github.com/crystal-lang/crystal | Docs: http://crystal-lang.org/docs/ | API: http://crystal-lang.org/api/ | Logs: http://irclog.whitequark.org/crystal-lang
bjz has joined #crystal-lang
bjz has quit [Client Quit]
bjz has joined #crystal-lang
<Papierkorb> How do I reliably detect in a method or macro if an argument is of a Union type or not?
<FromGitter> <crisward> I've posted some info on compiler speed on mac for 0.20.5 and 0.20.4 - https://github.com/crystal-lang/crystal/issues/4022 hopefully that gives some hints as to what's happening.
<Papierkorb> Got it
<FromGitter> <crisward> Not very scientific, but how long should `p "hello world"` take to return in crystal play? Mine takes around 20 seconds. Not sure if it's related to crystal-lang/crystal#4022 but it's slow in 0.20.4 as well. Tried changing the port, incase I was getting some network issues, but it didn't help.
<RX14> @crisward takes me 0.7s about
<FromGitter> <crisward> mine is only a bit longer using `crystal build test.cr -s` the 20 seconds is in the crystal play interface. No idea why it's that slow.
<FromGitter> <crisward> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=589fafac00c00c3d4f28354e]
<FromGitter> <crisward> Just deleted my ~/.cache/crystal files. Seems to have fixed it. Now taking < 3 seconds
Svenskunganka has quit [Read error: Connection reset by peer]
<RX14> weird
Svenskunganka has joined #crystal-lang
<FromGitter> <crisward> The cache took an age to delete, must have been very big.
<Papierkorb> RX14: The digest issue isn't much about security. Though I'd be fine in theory with the methods providing easy access to OpenSSL primitives for it, without showing it's using OpenSSL. The last thing I want from a "secure" language is having to clutter OpenSSL::... everywhere
<Papierkorb> Though that's a more broad issue, I'd like to hide OpenSSL more anyway, so it can also be more easily replaced by the next cool ssl library like BoringSSL or whatever
FiveBroDeepBook has joined #crystal-lang
FiveBroDeepBook has left #crystal-lang [#crystal-lang]
squeaky_ has quit [Ping timeout: 264 seconds]
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
soveran has quit [Remote host closed the connection]
bjz has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Dreamer3 has joined #crystal-lang
bjz has joined #crystal-lang
snsei has joined #crystal-lang
snsei has quit [Read error: No route to host]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bjz has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<FromGitter> <drosehn> I didn't see anyone answer the question about `uname` on MacOS. Here's `uname -a` on the mac I'm currently typing on: Darwin OnRun-i52c.local 14.5.0 Darwin Kernel Version 14.5.0: Sun Sep 25 22:07:15 PDT 2016; root:xnu-2782.50.9~1/RELEASE_X86_64 x86_64
squeaky_ has joined #crystal-lang
<FromGitter> <drosehn> I doubt PR's would need all that. It might be interesting for crystal to include the version of whatever llvm was used to compile it.
snsei has quit [Remote host closed the connection]
bjz has joined #crystal-lang
<crystal-gh> [crystal] karlseguin opened pull request #4023: document use (and risk) of $N special capture group variables (#3979) (master...feature/regexp_capture_doc) https://git.io/vDwMB
squeaky_ has quit [Ping timeout: 245 seconds]
soveran has joined #crystal-lang
soveran has joined #crystal-lang
soveran has quit [Changing host]
<crystal-gh> [crystal] ezrast opened pull request #4024: Support "View source" links for GitLab projects (master...gitlab-view-source) https://git.io/vDw9J
soveran has quit [Remote host closed the connection]
Raimondii has joined #crystal-lang
Raimondi has quit [Ping timeout: 268 seconds]
Raimondii is now known as Raimondi
soveran has joined #crystal-lang
<crystal-gh> [crystal] karlseguin opened pull request #4025: Adds include? macro method to string, symbol and macroid. (master...feature/macro_includes) https://git.io/vDw99
squeaky_ has joined #crystal-lang
bjz_ has joined #crystal-lang
bjz has quit [Ping timeout: 240 seconds]
<RX14> Papierkorb, i agree with you on abstracting openssl
<RX14> and abstracting TLS/SSL/Digest away from openssl so we have pluggable providers
<RX14> but each and every one of those providers should be written by someone who knows what they're doing
unshadow has joined #crystal-lang
<unshadow> Is there a fork\branch with the concurrency work ? to checkout and test ?
<RX14> unshadow, there's a branch but it's too early to test
<unshadow> RX14: Sure, thanks :)
<RX14> actually wow
<RX14> it's actually being worked on
<BlaXpirit> exactly my reaction
<unshadow> Can't find it, is it a branch or someones fork ?
<RX14> i'm used to "waj is working on it" "last commit a month ago"
<RX14> unshadow, it's called thread-support
<unshadow> RX14: Cool, thanks :) I'll check it out , maybe it's already usable ?
<RX14> well
<RX14> a few of the examples seem to be edited to run
<RX14> so yes
<RX14> it looks somewhat usable
<unshadow> I guess not ... "src/ck/ext/rwlock.c:1:23: fatal error: ck_rwlock.h: No such file or directory"
<RX14> make again
<RX14> oh
<RX14> uhh
<RX14> nvm
<unshadow> XD
<RX14> looks like a new lib
<RX14> concurrencykit
bmcginty has quit [Ping timeout: 252 seconds]
bmcginty has joined #crystal-lang
<unshadow> Is that some lib I can found on the net ? can't find it in my package manager
<RX14> well
<unshadow> RX14: It workek, still not compiling , but now it's just some local var errors, this I guess, is just a matter of time to let waj and friends to finish concurency
A124 has quit [Ping timeout: 264 seconds]
<Papierkorb> Is there a coverage tool?
A124 has joined #crystal-lang
pduncan has quit [Ping timeout: 255 seconds]
<RX14> no
<RX14> which is a shame
<crystal-gh> [crystal] jellymann opened pull request #4026: Add `zero?` to Number (master...patch-1) https://git.io/vDwhF
<Papierkorb> Ah, someone else liked #zero? too
<RX14> we already had this discussion
<RX14> and it was why have #zero? wuejn you can just use == 0
<RX14> there is no point
<Papierkorb> Why use crystal when there's C
<RX14> thats not much of an argument is it
<RX14> #zero? is essentially a method alias
<RX14> and asterite has made his position on them clear
<Papierkorb> My opinion is not changed by another persons opinion I disagree with. I don't wanna start this war RX14, I don't care much about #zero?, I just like how it reads
<RX14> your opinion doesn't have to change, but it does have an effect on whether this PR will be merged or not
<unshadow> I agree that .zero? is not needed as it's longer then just == 0 , but, we can say the same for .nil?, where x == nil
<RX14> the reason behind nil? is that == nil doesn't work in type restrictions
<RX14> you cannot implement nil? yourself, you can implement == nil yourself
<Papierkorb> The intention is different. zero? asks "is this thing zero-ish?" and == 0 tests if that thing is actually zero
<unshadow> RX14: Oh, didn't know that, in that case my argument is invalid
<unshadow> Ok, what about .empty? then
<Papierkorb> it's not as strong as the intention difference between Symbol vs String of course
<RX14> personally i'd prefer to use == nil, but I imagine implementing it as non-overridable would be quite hard
* Papierkorb brb
<RX14> .empty? is quite a bit shorter than .size == 0 i guess
<RX14> because it's not testing equality of self
<unshadow> == ""
<RX14> it's etsting equality of a property of self
<RX14> not sure how much difference that makes
<RX14> I always use size == 0
<FromGitter> <chyzwar> Thanks for pointing where exit and bort is defined @RX14
<RX14> that was BlaXpirit
<RX14> iirc
BlaXpirit is now known as oprypin
<FromGitter> <chyzwar> yeah, thanks @BlaXpirit
<FromGitter> <chyzwar> I have another thing to ask. I define logging module that then include in my classes. it work on in all cases but I have issue when I try to create custom formatter
oprypin is now known as BlaXpirit
<FromGitter> <chyzwar> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=58a074461465c46a56552629]
snsei has joined #crystal-lang
<FromGitter> <chyzwar> it is something aout how modules are avaluated or they way I am using Logger::Formatter alias?
<RX14> this seems to be the bug
<FromGitter> <spalladino> Yep, you can work around it by using `tap`: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=58a077b9872fc8ce622678c6]
<FromGitter> <chyzwar> cool, thank for workaround. I found real bug this time :)
unshadow has quit [Quit: leaving]
<FromGitter> <chyzwar> btw string interpolation would not perform faster than << ?
zaiste_ has joined #crystal-lang
<Yxhuvud> Why would it be faster to create an intermediary string than to not do that?
<FromGitter> <chyzwar> `io << severity[0] << ", [" << datetime << " #" << Process.pid << "] "` vs `io << "#{severity[0]} [ #{datetime} # #{Process.pid} ] "`
<FromGitter> <chyzwar> Well it shoudl be pretty the same in terms of performance I gueass.
jhass has quit [Ping timeout: 276 seconds]
jhass has joined #crystal-lang
<Papierkorb> chyzwar, maybe neglibable, but #<< could be a tad faster as the string interpolation version would build the whole string first and then send it off into the io
skinkitten has joined #crystal-lang
skinkitten_ has joined #crystal-lang
snsei has quit [Remote host closed the connection]
zaiste_ has quit [Ping timeout: 252 seconds]
M-mva1985 has quit [Ping timeout: 256 seconds]
acheron[m] has quit [Ping timeout: 240 seconds]
Vallkury[m] has quit [Ping timeout: 264 seconds]
kodotest[m] has quit [Ping timeout: 276 seconds]
braidn[m] has quit [Ping timeout: 276 seconds]
splitty_ has quit [Read error: Connection reset by peer]
splitty_ has joined #crystal-lang
havenwood has quit [Quit: mIRC 5.91 (16 bit) for Microsoft © Windows For WorkGroups 3.11®]
havenwood has joined #crystal-lang
havenwood has joined #crystal-lang
havenwood has quit [Changing host]
Yxhuvud has quit [Read error: Connection reset by peer]
Yxhuvud has joined #crystal-lang
skinkitten_ has quit [Ping timeout: 240 seconds]
skinkitten has quit [Ping timeout: 240 seconds]
braidn[m] has joined #crystal-lang
<RX14> tfw nobody will review my multipart PR
<RX14> it's like life doesn't want this PR merged
bjz_ has quit [Ping timeout: 260 seconds]
bjz has joined #crystal-lang
kodotest[m] has joined #crystal-lang
acheron[m] has joined #crystal-lang
M-mva1985 has joined #crystal-lang
Vallkury[m] has joined #crystal-lang
<wmoxam> RX14: HTTP Multipart?
<RX14> yep
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bjz has joined #crystal-lang
squeaky_ has quit [Read error: Connection reset by peer]
squeaky_ has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Papierkorb> Oh. Maybe I found a missing !dbg location.
<Papierkorb> > Module validation failed: inlinable function call in a function with debug info must have a !dbg location
<Papierkorb> > call void @"*raise<String>:NoReturn"(tring* bitcast ({ i32, i32, i32, [147 x i8] }* @"'can't execute `wait...'" to tring*))
<RX14> yup
<Papierkorb> If that alone helps. Will release that thing tomorrow either way
<RX14> i'd reduce it
<Papierkorb> > Ping 958877.06:30:16.6719373
<Papierkorb> Meh, looks like Time isn't fine enough for that Oo
<Papierkorb> The RTT looks fine
sz0 has quit [Quit: Connection closed for inactivity]
danielpclark has joined #crystal-lang
mgarciaisaia has joined #crystal-lang