jhass changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.5.8 | Paste > 3 lines of text to https://gist.github.com | GH: https://github.com/manastech/crystal - Docs: http://crystal-lang.org/docs/ - API: http://crystal-lang.org/api/ - Logs: http://irclog.whitequark.org/crystal-lang
the_asterite has joined #crystal-lang
the_asterite has quit [Client Quit]
the_asterite has joined #crystal-lang
the_asterite has quit [Client Quit]
asterite has joined #crystal-lang
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] jhass opened pull request #380: Character sets (master...string_count) http://git.io/bIfI
crystal-gh has left #crystal-lang [#crystal-lang]
asterite has quit [Ping timeout: 246 seconds]
tmoore_ has quit [Ping timeout: 245 seconds]
endou______ has quit [Ping timeout: 265 seconds]
tmoore_ has joined #crystal-lang
endou______ has joined #crystal-lang
zamith has quit [Quit: Be back later ...]
<epitron> lol, shards
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] waj fast-forwarded master from a8dc4fb to aa194e4: http://git.io/bIyu
crystal-gh has left #crystal-lang [#crystal-lang]
travis-ci has joined #crystal-lang
<travis-ci> manastech/crystal#1901 (master - aa194e4 : Juan Wajnerman): The build passed.
travis-ci has left #crystal-lang [#crystal-lang]
bcardiff has joined #crystal-lang
emmanueloga has quit []
emmanueloga has joined #crystal-lang
shama has quit [Quit: (╯°□°)╯︵ɐɯɐɥs]
r0ast has joined #crystal-lang
bcardiff has quit [Quit: Leaving.]
r0ast has quit [Remote host closed the connection]
r0ast has joined #crystal-lang
r0ast has quit [Client Quit]
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] ysbaddaden opened pull request #382: Refactored Process.run (master...std-process-refactor) http://git.io/btLa
crystal-gh has left #crystal-lang [#crystal-lang]
leafybasil has quit [Remote host closed the connection]
leafybasil has joined #crystal-lang
leafybasil has quit [Read error: Connection reset by peer]
leafybas_ has joined #crystal-lang
zamith has joined #crystal-lang
bcardiff has joined #crystal-lang
asterite has joined #crystal-lang
bcardiff has quit [Quit: Leaving.]
17SABPS93 has joined #crystal-lang
17SABPS93 has left #crystal-lang [#crystal-lang]
<17SABPS93> [crystal] asterite closed pull request #380: Character sets (master...string_count) http://git.io/bIfI
21WAA8H9Q has joined #crystal-lang
<21WAA8H9Q> [crystal] asterite pushed 5 new commits to master: http://git.io/bq0O
<21WAA8H9Q> crystal/master 448cb21 Jonne Haß: Add Char#in_set?...
<21WAA8H9Q> crystal/master dd379fb Jonne Haß: Add String#count
<21WAA8H9Q> crystal/master 7e97726 Jonne Haß: Add new overloads to String#delete
21WAA8H9Q has left #crystal-lang [#crystal-lang]
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] asterite pushed 3 new commits to master: http://git.io/bqEU
<crystal-gh> crystal/master 74595fc Ary Borenszweig: Improved error message on call error on mismatched named argument
<crystal-gh> crystal/master eb9c023 Ary Borenszweig: Added Dir#glob(*) that accepts a block
<crystal-gh> crystal/master 976bfb9 Ary Borenszweig: Fixed #383: Array#reverse! crashes on arrays with even length
crystal-gh has left #crystal-lang [#crystal-lang]
leafybas_ has quit []
leafybasil has joined #crystal-lang
travis-ci has joined #crystal-lang
<travis-ci> manastech/crystal#1906 (master - cfee640 : Ary Borenszweig): The build passed.
travis-ci has left #crystal-lang [#crystal-lang]
travis-ci has joined #crystal-lang
<travis-ci> manastech/crystal#1907 (master - 976bfb9 : Ary Borenszweig): The build was broken.
travis-ci has left #crystal-lang [#crystal-lang]
<jhass> asterite: hah, https://travis-ci.org/manastech/crystal/builds/49314425 segfault! Already thought I'm the only one to produce them :P
<asterite> :)
<asterite> It crashes on my machine too with LLVM 3.5.1
<asterite> but with LLVM HEAD (3.7-svn) it works well
<asterite> There are some LLVM bugs related to exception handling… I think in HEAD they are fixed. I thought in LLVM 3.5.1 they were fixed, but apparently not
<asterite> And only in Mac, I think
<asterite> jhass: can you try to `make clean crystal spec` on your side, see if it segfaults too?
<asterite> Bah, I guess I can also check drone.io
<asterite> It works fine on linux: https://drone.io/github.com/manastech/crystal/1009
<asterite> :(
<jhass> mmh, doesn't github support multiple commit statuses these days?
<asterite> That bug has been hunting us for a long time now… and there’s a bug in libunwind as well, only in mac
<jhass> would be nice to have both builds I guess
<asterite> Travis to build mac and linux, you say?
<jhass> that's possible too, but they only give out a limited amount of those so called multi-environment builds and I think it's empty atm
<jhass> let me get the github blogpost for what I mean though
<asterite> Ok :)
<jhass> it would be nice to see the drone and the travis build in a PR is what I'm saying
<asterite> Oh! Yes… only travis builds it right now
<jhass> here's the multi os docs for travis http://docs.travis-ci.com/user/multi-os/
<asterite> Ah! Yes, we should add the result from drone too
<asterite> I’ll tell @waj :)
<jhass> we probably should also think about a community supported build env for travis
<asterite> Definitely!
<asterite> Too many things to do :)
<jhass> yeah...
<jhass> fyi, make clean crystal spec runs fine on my machine too on master
<asterite> Yes… And remember that IO.select thing that would segfault on my machine but not yours? That’s the same llvm bug :(
<asterite> Maybe we should just generate assembly code ourself :-P
<jhass> hehe
<jhass> I fear llvm needs its code for the optimizer run though, right? ;)
<asterite> To be honest, I’m not quite sure why crystal is so fast. LLVM is really amazing :)
<jhass> yeah
<asterite> Yes, llvm does all the optimizations for us
<asterite> It’s really smart
<jhass> and things like that ARM support is figuring out a few constants away basically
<asterite> Of course, we try to give it things it can nicely optimize
<asterite> Yes, exactly. The other thing would be to use gcc, but I guess it would have its cons too
<jhass> Ruby is thinking about doing an LLVM JIT for 3.0, so...
<asterite> And ldc (d + llvm) is much faster than regular D… I think llvm is the way to go :)
<jhass> definitely
<jhass> I think you just need to dispose your mac :P
<asterite> Well, that’s going to be hard… the mac I have is the one they give me for work :-P
<asterite> And I really like mac by now… I used ubuntu and other linuxes for a while, but there were always problems and manual command line things I had to do all the time, it was kind of annoying
<asterite> and mac is pretty fast, actually
<jhass> btw. I "found" an xcode dmg and extracted some stuff and throw lxr at it... so if you need to find something in the future :P
<jhass> >> class Foo; def self.[](x]; yield x; end; end; Foo["hi"] {|x| puts x }
<CeBot> jhass: Syntax error in eval:3: unexpected token: ] (expected ',' or ')')
<jhass> >> class Foo; def self.[](x); yield x; end; end; Foo["hi"] {|x| puts x }
<CeBot> jhass: Syntax error in eval:3: unexpected token: {
<jhass> :/
<asterite> :-P
<jhass> >> class Foo; def self.[](x); yield x; end; end; Foo["hi"] do |x| puts x; end
<CeBot> jhass: Syntax error in eval:3: expecting identifier 'end', not 'do'
<asterite> That doesn’t work in Ruby either, I think
<jhass> yeah
<jhass> but would be funny :P
<asterite> I think it could work, I don’t know why it doesn’t (in ruby)
<jhass> because.. did you ever look at parse.y? :P
<asterite> Not for too long, I want to keep my eyes healthy
<asterite> Probably my mental health too :-P
<asterite> I don’t like parser generators much
<jhass> ;)
<asterite> It all starts nice, but when you need to do some little tweaks then you are in for a long war against those tools
zamith_ has joined #crystal-lang
zamith has quit [Ping timeout: 245 seconds]
asterite_ has joined #crystal-lang
asterite has quit [Ping timeout: 252 seconds]
asterite_ is now known as asterite
CeBot has quit [Quit: Crystal]
DeBot has joined #crystal-lang
asterite has quit [Quit: asterite]
bcardiff has joined #crystal-lang
asterite has joined #crystal-lang
shama has joined #crystal-lang
<zamith_> asterite: hey
<zamith_> I get a segfault when running the tests
<zamith_> and it's not on the compiler
<zamith_> the compiler is ok
zamith_ is now known as zamith
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] zamith opened pull request #385: Allows divisions with the num1/(num2) syntax (master...master) http://git.io/bYrW
crystal-gh has left #crystal-lang [#crystal-lang]
<asterite> zamith: you are on mac, right?
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] asterite pushed 1 new commit to master: http://git.io/bY6C
<crystal-gh> crystal/master ff1e13f Ary Borenszweig: [CLI] Added -D option to add compile-time flags to use for ifdef
crystal-gh has left #crystal-lang [#crystal-lang]
<zamith> yes
<zamith> I'm trying to find the file where it happens
<asterite> What llvm you have?
<asterite> If you have 3.5 or 3.5.1, can you try this: brew update; brew rm llvm; brew install llvm —HEAD; brew link llvm —force
<asterite> And then try to compile the specs with `make clean crystal spec` again
<asterite> At least in my case it works… We strongly believe it’s a bug in llvm
<zamith> it may well be
<asterite> More because it doesn’t happen on mac, and it happens randomly
<zamith> have you had this happen to you as well?
<asterite> Yes. I’m now checking with @waj if it happens to him too
<zamith> I'm re installing llvm head
<asterite> Yes, it takes a lot of time. Then… we don’t know if the bug is because llvm is compiled generically… if you install HEAD it will compile it on your machine
<zamith> oh ok
<zamith> but it only effects the running of tests, right?
<zamith> it has no impact on the regular user
travis-ci has joined #crystal-lang
<travis-ci> manastech/crystal#1909 (master - ff1e13f : Ary Borenszweig): The build is still failing.
travis-ci has left #crystal-lang [#crystal-lang]
<zamith> it runs now, but I guess my fix broke some stuff
<zamith> disregard my pr for now
<asterite> I was going to answer, the specs don’t compile after that
<asterite> But I was really surprised that you sent it so fast!
<asterite> I was going to fix it and immediately saw your PR :)
<zamith> the problem now is this: Syntax error in /Users/zamith/Projects/personal/crystal/crystal/spec/std/string_spec.cr:49: unexpected token: /
<zamith> assert { "FooBar"[/([A-Z])/, 1].should eq "F" }
<asterite> I think the solution is to set @wants_regex to false after a call dot comes
<zamith> I was trying to set slash_is_regex
<asterite> Yes, /( might mean a regex, but after a dot it can never be a regex
<zamith> slash_is_not_regex
<zamith> i mean
<zamith> but it didn't work
<zamith> i'll try that
<zamith> the test is correct, though, I think
<zamith> at least, there's that
<zamith> :P
<asterite> Definitely :)
<asterite> But we can now add a test for parsing foo[/(bar)/], which should fail now :)
<asterite> By the way, you can try commenting this spec: https://github.com/manastech/crystal/blob/master/spec/std/dir_spec.cr#L78
<asterite> and run the specs again, with llvm 3.5, and see that it all compiles and runs nicely… but that code is almost the same as the above one, so that’s the llvm bug… it happens randomly depending on the code you compile :(
<asterite> which makes it pretty obsucre
<asterite> Unless we are not seeing something… but on linux it never, ever segfaults like that
<zamith> asterite: while I run the tests, would you be available for a skype call or something like that, today or tomorrow?
<zamith> I'd like to review my talk with you, if you have the time
<zamith> I'm giving it tomorrow
<zamith> all the tests are ok, now
<asterite> zamith: Sure! I’d love to review it with you :)
<zamith> what's the best time for you?
<asterite> I have a meeting right now, for one or two hours, but after that, if it’s not too late there, we can do it
<zamith> let me check the time difference
<zamith> :P
<zamith> it's only 3 hours difference, can you do 6PM?
<zamith> that's 9PM here
<zamith> or any time after 6PM
<asterite> Yes, 6PM is good :)
<zamith> asterite: where is the &. being parsed? I thought it was here: https://github.com/manastech/crystal/blob/master/src/compiler/crystal/syntax/parser.cr#L1110
<zamith> nice :)
<asterite> Oh, no, sorry
<asterite> It’s there where you pointed
<zamith> yeah, I just need to figure out where to put the wants regex
<zamith> that should fix it
<asterite> Just before line 1120
<asterite> I think
<asterite> That is, before asking the next token after the do
<asterite> dot
<zamith> yeah, i tried that
<zamith> but it does work
<zamith> :S
<zamith> the wants_regex is still true when it gets to the lexer
<asterite> Strange, it works for me
<zamith> really?
<zamith> it passes the test?
<asterite> Are you doing bin/crystal spec/compiler/parser/parser_spec.cr ?
<asterite> (using bin/crystal)
<zamith> yeah
<zamith> i had a typo
<zamith> :s
<zamith> @want_regex, instead of wants
<zamith> it works
<asterite> Good
<asterite> Maybe we can have a warning in that case (ivar set but never read)
<asterite> But not sure
<zamith> it's ok, I just need to pay more attention
<zamith> let me run all the tests, before commting
<zamith> *commiting
leafybasil has quit [Remote host closed the connection]
<zamith> >> 4./(2)
<DeBot> zamith: Syntax error in eval:3: expecting any of these tokens: IDENT, +, -, *, /, %, |, &, ^, **, <<, <, <=, ==, !=, =~, >>, >, >=, <=>, ||, &&, ===, [], []= (not 'DELIMITER_START')
<zamith> asterite: is this supposed to work?
<asterite> It should work, but maybe doesn't
<zamith> it works in ruby
<zamith> >> 4 /(2)
<DeBot> zamith: 2
<zamith> this does
<asterite> The dot syntax should work too. It probably broke after we added support for regex with whitespace
<zamith> maybe
<zamith> just letting you know
<zamith> do you want me to open an issue?
<zamith> I can't fix it right now
<asterite> Thanks. I’ll fix it later today :)
zamith has quit [Ping timeout: 264 seconds]
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] waj pushed 1 new commit to master: http://git.io/bO32
<crystal-gh> crystal/master 5665bcb Juan Wajnerman: Use patched LLVM 3.5.0 in Travis (until LLVM 3.6 is released with issue 20800 fixed)
crystal-gh has left #crystal-lang [#crystal-lang]
travis-ci has joined #crystal-lang
<travis-ci> manastech/crystal#1911 (master - 5665bcb : Juan Wajnerman): The build was fixed.
travis-ci has left #crystal-lang [#crystal-lang]
<asterite> Aaand… with the patched llvm, no segfault :)
<asterite> I’ll soon be adding a Contributing.md, I guess...
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] weskinner opened pull request #387: Fix SDL Samples (master...master) http://git.io/bOCV
crystal-gh has left #crystal-lang [#crystal-lang]
<jhass> asterite: yeah, looks like it fixed my PR too :P
<asterite> So that was it!
<asterite> I had no idea
<asterite> I guess those PR will have to wait for a while, until I meet with waj and we discuss it. I think he knows how it would like it to be
<jhass> asterite: that llvm assertion that was happening on my PR on travis might still be worth looking at I guess
<jhass> maybe it can point to a workaround to the bug or whatever
<asterite> Yes, maybe
zamith has joined #crystal-lang
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] asterite closed pull request #387: Fix SDL Samples (master...master) http://git.io/bOCV
crystal-gh has left #crystal-lang [#crystal-lang]
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] asterite pushed 1 new commit to master: http://git.io/bOi0
crystal-gh has left #crystal-lang [#crystal-lang]
<crystal-gh> crystal/master df182ad Ary Borenszweig: Fixed SDL samples for linux and mac too
travis-ci has joined #crystal-lang
<travis-ci> manastech/crystal#1915 (master - df182ad : Ary Borenszweig): The build passed.
travis-ci has left #crystal-lang [#crystal-lang]
travis-ci has joined #crystal-lang
travis-ci has left #crystal-lang [#crystal-lang]
<travis-ci> manastech/crystal#1914 (master - ced9b10 : Ary Borenszweig): The build passed.
<asterite> jhass: woah, did you just replace debot to be crystal by default? :-P
<jhass> that was the plan anyway ;)
<asterite> Does it already do what the ruby one could do?
<jhass> pretty much
<jhass> I didn't do the RSS feed reader since nobody was using that anymore
<jhass> it doesn't do nickserv authentication, only SASL for now
<jhass> oh and I disabled the URL title announcer on DeBot since some time and didn't reimplement it
crystal-gh has joined #crystal-lang
<crystal-gh> [crystal] ysbaddaden opened pull request #388: Fix: SDL link declaration for Linux (master...sdl-linux-link-fix) http://git.io/b3cm
crystal-gh has left #crystal-lang [#crystal-lang]
bcardiff1 has joined #crystal-lang
bcardiff has quit [Ping timeout: 255 seconds]
bcardiff1 has quit [Quit: Leaving.]
bcardiff has joined #crystal-lang
zamith has quit [Quit: Be back later ...]
leafybasil has joined #crystal-lang
asterite has quit [Quit: asterite]
zamith has joined #crystal-lang
ryanf has quit [Ping timeout: 245 seconds]
ryanf has joined #crystal-lang
bcardiff has quit [Quit: Leaving.]
endou______ has quit [Ping timeout: 245 seconds]
tmoore_ has quit [Ping timeout: 265 seconds]
endou______ has joined #crystal-lang
endou______ has quit [Changing host]
endou______ has joined #crystal-lang
tmoore_ has joined #crystal-lang
bcardiff has joined #crystal-lang