jhass changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.7.5 | Fund Crystals development: http://to.ly/TtGw | 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
blue_deref has quit [Quit: bbn]
<crystal-gh> [crystal] asterite closed pull request #1073: Allows match to take a block (master...improve-match) http://git.io/vO3DN
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vOGXL
<crystal-gh> crystal/master b9b7d57 Zamith: Do not delegate to LibSSL when there is nothing to read...
<crystal-gh> crystal/master b10df4d Ary Borenszweig: Merge pull request #1078 from zamith/openssl-read...
zamith has joined #crystal-lang
centrx has quit [Quit: 'Get out, you and all the people who follow you!' Then he went out from Pharaoh in hot anger.]
zamith has quit [Ping timeout: 255 seconds]
<travis-ci> manastech/crystal#09244e8 (master - Merge pull request #1073 from zamith/improve-match): The build passed. https://travis-ci.org/manastech/crystal/builds/73732140
<travis-ci> manastech/crystal#b10df4d (master - Merge pull request #1078 from zamith/openssl-read): The build passed. https://travis-ci.org/manastech/crystal/builds/73732173
havenwood has quit [Quit: Textual IRC Client: www.textualapp.com]
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 260 seconds]
blue_deref has joined #crystal-lang
NeverDie has joined #crystal-lang
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 244 seconds]
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 265 seconds]
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 260 seconds]
zamith has joined #crystal-lang
<crystal-gh> [crystal] luislavena opened pull request #1080: CGI.parse: avoid malformed query string to raise exception (master...malformed-cgi-parsing) http://git.io/vOZCT
zamith has quit [Ping timeout: 246 seconds]
willl has quit [Quit: Connection closed for inactivity]
mitch_ has left #crystal-lang ["Leaving"]
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 264 seconds]
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 244 seconds]
BlaXpirit has joined #crystal-lang
sailorswift has joined #crystal-lang
<crystal-gh> [crystal] sferik opened pull request #1081: Add code of conduct (master...code-of-conduct) http://git.io/vOZ2k
blue_deref has quit [Quit: bbn]
zamith has joined #crystal-lang
zamith has quit [Ping timeout: 260 seconds]
wonderbreadz has quit [Ping timeout: 240 seconds]
wonderbreadz has joined #crystal-lang
<travis-ci> jalyna/crystal#b10df4d (master - Merge pull request #1078 from zamith/openssl-read): The build passed. https://travis-ci.org/jalyna/crystal/builds/73751149
Raimondi has quit [Ping timeout: 252 seconds]
dbackeus has joined #crystal-lang
zamith has joined #crystal-lang
dbackeus has quit [Ping timeout: 250 seconds]
BlaXpirit has quit [Quit: Konversation]
zamith has quit [Quit: Be back later ...]
elia has joined #crystal-lang
elia has quit [Quit: Computer has gone to sleep.]
<crystal-gh> [crystal] jalyna opened pull request #1084: Add flat method for arrays (master...array-flat) http://git.io/vOZHq
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
elia has joined #crystal-lang
elia has quit [Client Quit]
<jhass> epitron: try less +F or tail -f ?
elia has joined #crystal-lang
elia has quit [Client Quit]
elia has joined #crystal-lang
<crystal-gh> [crystal] yui-knk opened pull request #1085: Move tests for `#flat_map` to enumerable.cr (master...fix/test_flat_map) http://git.io/vOZpV
sailorswift has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
elia has quit [Quit: Computer has gone to sleep.]
zamith has joined #crystal-lang
sdogruyol has joined #crystal-lang
<crystal-gh> [crystal] yui-knk opened pull request #1086: [ci skip] Fix typo (master...fix/typo_2) http://git.io/vOnej
<sdogruyol> asterite: what if the fundraiser on bountsource can't reach the goal of 50k? Do you still get the gathered amount
zamith has quit [Client Quit]
zamith_ has joined #crystal-lang
<crystal-gh> [crystal] yui-knk opened pull request #1087: [ci skip] Fix typo (master...fix/typo_3) http://git.io/vOnku
sdogruyol has quit [Remote host closed the connection]
zamith_ has quit [Quit: Be back later ...]
zamith_ has joined #crystal-lang
zamith_ has quit [Quit: Be back later ...]
dbackeus has joined #crystal-lang
zamith_ has joined #crystal-lang
zamith_ has quit [Quit: Be back later ...]
sdogruyol has joined #crystal-lang
<dbackeus> is it possible to render methods blocks in ecr? <%= my_method do %><p>hello</p><% end %> gives me "unexpected token: (" error
elia has joined #crystal-lang
hangyas has joined #crystal-lang
sdogruyol has quit [Ping timeout: 240 seconds]
elia has quit [Quit: Computer has gone to sleep.]
<jhass> mmh, I'd expect it to, probably a bug/missing feature
sdogruyol has joined #crystal-lang
dbackeus has quit [Remote host closed the connection]
dbackeus has joined #crystal-lang
dbackeus has quit [Remote host closed the connection]
elia has joined #crystal-lang
boghison has joined #crystal-lang
<boghison> Hi! Does anyone know how I can pass a C struct to a C function (where the param is the struct pointer)? I tried just using .new, but it says that the struct has no method to_unsafe
sdogruyol has quit [Remote host closed the connection]
Raimondi has joined #crystal-lang
elia has quit [Quit: Computer has gone to sleep.]
elia has joined #crystal-lang
<jhass> boghison: you might need to use pointerof(foo)
sdogruyol has joined #crystal-lang
sdogruyol has quit [Remote host closed the connection]
elia has quit [Quit: Computer has gone to sleep.]
leafybasil has quit [Remote host closed the connection]
<boghison> jhass: Can't take address
dbackeus has joined #crystal-lang
<jhass> of?
<boghison> the struct
<boghison> or the struct.new
<jhass> foo = TheStruct.new; c_func(pointerof(foo))
<boghison> Oh, it works if I assign it beforehand
<boghison> as in foo = ...
<boghison> Thanks!
dbackeus has quit [Remote host closed the connection]
dbackeus has joined #crystal-lang
<hangyas> hi, what is Slice used for?
dbackeus has quit [Remote host closed the connection]
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vOnSM
<crystal-gh> crystal/master 4c9ede2 yui-knk: Add `Array#zip?`...
<crystal-gh> crystal/master acae3fe Ary Borenszweig: Merge pull request #1088 from yui-knk/feature/array_zipp...
<crystal-gh> [crystal] asterite closed pull request #1087: [ci skip] Fix typo (master...fix/typo_3) http://git.io/vOnku
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vOnSN
<crystal-gh> crystal/master f0ff4a1 yui-knk: [ci skip] Fix typo
<crystal-gh> crystal/master e76216f Ary Borenszweig: Merge pull request #1086 from yui-knk/fix/typo_2...
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vOn9Y
<crystal-gh> crystal/master 4d46e6c yui-knk: Move tests for `#flat_map` to enumerable.cr...
<crystal-gh> crystal/master 186a1ff Ary Borenszweig: Merge pull request #1085 from yui-knk/fix/test_flat_map...
havenwood has joined #crystal-lang
<travis-ci> manastech/crystal#2ed7782 (master - Merge pull request #1080 from luislavena/malformed-cgi-parsing): The build passed. https://travis-ci.org/manastech/crystal/builds/73770807
dbackeus has joined #crystal-lang
<boghison> Does anyone know how to convert a Void* to String from C?
sdogruyol has joined #crystal-lang
<travis-ci> manastech/crystal#acae3fe (master - Merge pull request #1088 from yui-knk/feature/array_zipp): The build passed. https://travis-ci.org/manastech/crystal/builds/73771000
<travis-ci> manastech/crystal#186a1ff (master - Merge pull request #1085 from yui-knk/fix/test_flat_map): The build passed. https://travis-ci.org/manastech/crystal/builds/73771137
<boghison> Actually, never mind
strcmp1 has joined #crystal-lang
grios has quit [Ping timeout: 264 seconds]
unshadow has joined #crystal-lang
leafybasil has joined #crystal-lang
sdogruyol has quit [Remote host closed the connection]
elia has joined #crystal-lang
sdogruyol has joined #crystal-lang
grios_ has joined #crystal-lang
elia has quit [Quit: Computer has gone to sleep.]
sdogruyol has quit [Remote host closed the connection]
elia has joined #crystal-lang
<crystal-gh> [crystal] asterite pushed 1 new commit to master: http://git.io/vOceS
<crystal-gh> crystal/master e605cbc Ary Borenszweig: Fixed gc/null after adding libc type aliases. Fixes #1083
<crystal-gh> [crystal] MakeNowJust opened pull request #1090: Added hooks `method_added` and `method_removed` (master...feature/method_added) http://git.io/vOcvD
<jhass> hangyas: Slice is basically a pointer with bounds checking, a chunk of memory
unshadow has quit [Quit: leaving]
elia has quit [Quit: Computer has gone to sleep.]
<hangyas> so a fixed size array?
elia has joined #crystal-lang
<jhass> hangyas: not quite, that's what StaticArray is for
<jhass> it's not fixed to be aligned to the underlying data type really, opposed to StaticArray
elia has quit [Client Quit]
<hangyas> oh, I see thanks
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vOcks
<crystal-gh> crystal/master 8839eb0 Ary Borenszweig: Codegen: don't dump LLVM module on handled exception (it's not useful for bug reports)
<crystal-gh> crystal/master d17b1b0 Ary Borenszweig: Say to include source code to reproduce bugs on handled exceptions
grios_ has quit [Ping timeout: 244 seconds]
<hangyas> btw I'm thinking about implementing Stack and Queue classes as they are not in the std, if nobody working on them or something
<jhass> hangyas: not sure if they'd fit into the currency model stdlib is aiming for, did you look at Channel?
<jhass> *concurrency
<hangyas> hm, I didn't think about concurrency purposes
<jhass> Stack might be okay, but Queue people would be expect to be thread safe and used for such purposes (thus be confusing in relation to Channel)
<jhass> personally I think such stuff would be good to have libraries but liked to see as few tools as possible in stdlib that do good on the average usecase
<jhass> opposed as too many specialized tools and then you spent half day wondering which to use now, like in Java
leafybasil has quit [Remote host closed the connection]
<jhass> I mean few tools as possible with overlapping usecases of course
<travis-ci> manastech/crystal#d17b1b0 (master - Say to include source code to reproduce bugs on handled exceptions): The build passed. https://travis-ci.org/manastech/crystal/builds/73777373
<hangyas> well, my main problem with using array as a queue was that unshifting is linear
<hangyas> however I didn't try chanels
<hangyas> I mean I haven't thought to use it not only for multithreading
<crystal-gh> [crystal] yui-knk opened pull request #1091: Add type restrictions to `Array#concat` (master...fix/array_concat_type) http://git.io/vOcYB
sdogruyol has joined #crystal-lang
<epitron> jhass: it's not less' fault - that thing I did works in Ruby with popen, and Process.run also fails when you use cat instead of less
<epitron> And it works if you pass a string as input instead of an IO
DeBot has quit [Ping timeout: 240 seconds]
_whitelogger has quit [Ping timeout: 240 seconds]
_whitelogger has joined #crystal-lang
leafybasil has joined #crystal-lang
hangyas has joined #crystal-lang
hangyas has quit [Quit: hangyas]
wuehlmaus has quit [Quit: Lost terminal]
boghison has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
NeverDie has joined #crystal-lang
blue_deref has joined #crystal-lang
BlaXpirit has joined #crystal-lang
leafybasil has quit [Remote host closed the connection]
sdogruyol has joined #crystal-lang
sdogruyol has quit [Ping timeout: 272 seconds]
NeverDie has quit [Quit: I'm off to sleep. ZZZzzz…]
waj has joined #crystal-lang
waj has quit [Quit: waj]
sdogruyol has joined #crystal-lang
sdogruyol has quit [Ping timeout: 256 seconds]
kulelu88 has joined #crystal-lang
NeverDie has joined #crystal-lang
jiriki has quit [*.net *.split]
hplar has quit [*.net *.split]
adam12 has quit [*.net *.split]
adam| has joined #crystal-lang
hplar has joined #crystal-lang
<travis-ci> manastech/crystal#9808af5 (master - Fixed #1092: `foo.@x` didn't compile if `foo` was a c struct): The build passed. https://travis-ci.org/manastech/crystal/builds/73796654
<BlaXpirit> >> case 5.class; when Int32; p "lol"; end
<DeBot_> BlaXpirit: # => nil - http://carc.in/#/r/9i9
<BlaXpirit> why?
<BlaXpirit> >> if 5.class === Int32; p "lol"; end
<DeBot_> BlaXpirit: "lol" - more at http://carc.in/#/r/9ic
jiriki has joined #crystal-lang
leafybasil has joined #crystal-lang
sailorswift has joined #crystal-lang
asterite has left #crystal-lang ["Leaving..."]
<crystal-gh> [crystal] Sdogruyol opened pull request #1093: [ci skip] Fix doc (master...master) http://git.io/vOCl7
<BlaXpirit> oh i get it
<BlaXpirit> because case for types is kinda hardcoded to use is_a?
<BlaXpirit> >> 5.class.is_a? Int32
<DeBot_> BlaXpirit: # => false - http://carc.in/#/r/9j0
<jhass> yeah, though I guess it should also test for equality
<jhass> though it wouldn't work in Ruby either
<BlaXpirit> how to get the class of array's values?
<BlaXpirit> Array(Int32) => Int32
<thor77> >> [1, 2, 3].delete 4
<DeBot_> thor77: # => false - http://carc.in/#/r/9j8
<thor77> >> [1, 2, 3].delete 3
<DeBot_> thor77: # => true - http://carc.in/#/r/9j9
<BlaXpirit> i wish Int32.class returned Type(Int32) or something
<BlaXpirit> because returning Object is just wrong
<BlaXpirit> >> a = Array(Int32); p typeof(a.new[0])
<DeBot_> BlaXpirit: Int32 - more at http://carc.in/#/r/9jk
<BlaXpirit> >> ["a"].class.class == Array(Int32).class.class
<DeBot_> BlaXpirit: # => false - http://carc.in/#/r/9jl
<BlaXpirit> i have no idea anymore
<BlaXpirit> how to check if a type is Array?
<BlaXpirit> >> Array(Int32).name.starts_with? "Array(" # other than this
<DeBot_> BlaXpirit: # => true - http://carc.in/#/r/9jm
<thor77> wtf
<BlaXpirit> ikr
<thor77> >> typeof(Array(Int32))
<DeBot_> thor77: # => Array(Int32):Class - http://carc.in/#/r/9jn
<thor77> >> typeof([1])
<DeBot_> thor77: # => Array(Int32) - http://carc.in/#/r/9jo
<thor77> >> typeof([1]) === Array
<DeBot_> thor77: # => false - http://carc.in/#/r/9jp
<thor77> >> typeof([1]) === Array()
<DeBot_> thor77: Syntax error in eval:4: expecting token 'CONST', not ')' - http://carc.in/#/r/9jq
<BlaXpirit> stahp
<thor77> >> typeof([1]) Array(T)
<DeBot_> thor77: Syntax error in eval:4: unexpected token: Array - http://carc.in/#/r/9jr
<BlaXpirit> it's no use, i've tried it all
<thor77> okey, to nidea
<BlaXpirit> is_subclass is needed
<thor77> yeah
<thor77> create a pr :P
<BlaXpirit> i cannot implement this
<BlaXpirit> >> t = [5].class; t.new.is_a? Array
<DeBot_> BlaXpirit: # => true - http://carc.in/#/r/9js
<thor77> >> [5].is_a? Array
<DeBot_> thor77: # => true - http://carc.in/#/r/9jt
<thor77> ^
<thor77> there you go
<BlaXpirit> thor77, no but i don't have a value to work with, i only have a type
<thor77> value?
<thor77> which value do you need?
<BlaXpirit> thor77, t = Array(Int32)
<BlaXpirit> how to find out if t is Array(T) or something else
<thor77> >> [5].is_a? Array(Int32)
<DeBot_> thor77: # => true - http://carc.in/#/r/9ju
<thor77> ^
dbackeus has quit [Remote host closed the connection]
<BlaXpirit> thor77, i don't care about this [5]
<BlaXpirit> I care about the variable `t` as defined in my earlier message
<thor77> >> t = Array(Int32); if [5].is_a? t
<DeBot_> thor77: Syntax error in eval:4: expecting token 'CONST', not 't' - http://carc.in/#/r/9jv
<thor77> >> t = Array(Int32).class; if [5].is_a? t
<DeBot_> thor77: Syntax error in eval:4: expecting token 'CONST', not 't' - http://carc.in/#/r/9jw
<thor77> okey, no idea
<thor77> maybe you can use macros
kumpelblase2 has joined #crystal-lang
blue_deref has quit [Quit: bbn]
<BlaXpirit> great idea
<jhass> >> ["foo"].is_a? Array
<DeBot_> jhass: # => true - http://carc.in/#/r/9k1
<jhass> don't need to supply the T there
<thor77> jhass: he wants to store the type in a variable
<jhass> and yeah, while the metamodel is all fake anyway, it's still incomplete
<jhass> thor77: ah, only read up to .name.starts_with?
<BlaXpirit> TypeNode has some interesting stuff, but I don't know how to obtain one
blue_deref has joined #crystal-lang
<BlaXpirit> "Macros can access constants. If the constant denotes a type, you get back a TypeNode."
<BlaXpirit> i dont know anymore http://carc.in/#/r/9k9
BlaXpirit has quit [Quit: Konversation]
elia has joined #crystal-lang
elia has quit [Quit: Computer has gone to sleep.]
elia has joined #crystal-lang
willl has joined #crystal-lang
asterite_ has joined #crystal-lang
asterite_ has quit [Client Quit]
asterite_ has joined #crystal-lang
asterite_ has quit [Client Quit]
<crystal-gh> [crystal] asterite pushed 2 new commits to master: http://git.io/vOCb2
<crystal-gh> crystal/master a5c16f3 Serdar Dogruyol: [ci skip] Fix doc
<crystal-gh> crystal/master ce2add3 Ary Borenszweig: Merge pull request #1093 from Sdogruyol/master...
kumpelblase2 has quit [Quit: Leaving...]
elia has quit [Quit: Computer has gone to sleep.]
sfcgeorge has joined #crystal-lang
sfcgeorg_ has joined #crystal-lang
sfcgeorge has quit [Ping timeout: 250 seconds]