jhass changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.13.0 | Fund Crystals 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
mgarciaisaia has left #crystal-lang [#crystal-lang]
Philpax has joined #crystal-lang
A124 has joined #crystal-lang
sp4rrow has quit [Quit: The Internet needs a break and I need a cookie]
tomchapin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
emancu has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
umurgdk has joined #crystal-lang
pawnbox has quit [Ping timeout: 264 seconds]
umurgdk has quit [Ping timeout: 244 seconds]
Gasher has joined #crystal-lang
sp4rrow has joined #crystal-lang
sp4rrow has quit [Client Quit]
Philpax has quit [Ping timeout: 260 seconds]
<ragmaanir> why does this raise an error? crystal eval 'require "json"; Time.new.to_json'
pawnbox has joined #crystal-lang
Gasher has quit [Quit: Leaving]
pawnbox has quit [Ping timeout: 252 seconds]
emancu has joined #crystal-lang
ragmaanir has quit [Quit: Leaving]
pawnbox has joined #crystal-lang
sp4rrow has joined #crystal-lang
pawnbox has quit [Ping timeout: 244 seconds]
pawnbox has joined #crystal-lang
pawnbox has quit [Ping timeout: 248 seconds]
kulelu88 has joined #crystal-lang
sp4rrow has quit [Quit: Textual]
Philpax has joined #crystal-lang
umurgdk has joined #crystal-lang
umurgdk has quit [Ping timeout: 244 seconds]
stef__ has quit [Read error: Connection reset by peer]
zodiak has joined #crystal-lang
A124 has quit [Read error: Connection reset by peer]
A124 has joined #crystal-lang
willl has quit [Quit: Connection closed for inactivity]
stef__ has joined #crystal-lang
zodiak has quit [Ping timeout: 244 seconds]
kulelu88 has quit [Quit: Leaving]
Philpax has quit [Ping timeout: 260 seconds]
marcosdsanchez has quit [Remote host closed the connection]
Dreamer3 has quit [Ping timeout: 244 seconds]
shadeslayer has quit [Quit: No Ping reply in 180 seconds.]
miketheman has quit [Ping timeout: 276 seconds]
onionhammer has quit [Ping timeout: 276 seconds]
Dreamer3 has joined #crystal-lang
slash_nick has quit [Ping timeout: 276 seconds]
slash_nick has joined #crystal-lang
shadeslayer has joined #crystal-lang
miketheman has joined #crystal-lang
onionhammer has joined #crystal-lang
umurgdk has joined #crystal-lang
umurgdk has quit [Ping timeout: 276 seconds]
Cidan has quit [Ping timeout: 244 seconds]
Cidan has joined #crystal-lang
Philpax has joined #crystal-lang
bjz has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bjz has joined #crystal-lang
pawnbox has joined #crystal-lang
trapped has joined #crystal-lang
umurgdk has joined #crystal-lang
umurgdk has quit [Remote host closed the connection]
umurgdk has joined #crystal-lang
pawnbox has quit [Remote host closed the connection]
bjz has quit [Ping timeout: 240 seconds]
bjz has joined #crystal-lang
zodiak has joined #crystal-lang
stef__ has quit [Ping timeout: 248 seconds]
PragTob has joined #crystal-lang
Philpax has quit [Ping timeout: 276 seconds]
trapped has quit [Read error: Connection reset by peer]
matp has quit [Ping timeout: 252 seconds]
matp has joined #crystal-lang
matp has quit [Ping timeout: 250 seconds]
matp has joined #crystal-lang
Philpax has joined #crystal-lang
pawnbox has joined #crystal-lang
onec has joined #crystal-lang
onec has quit [Client Quit]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
pawnbox has quit [Ping timeout: 260 seconds]
Gasher has joined #crystal-lang
Gasher has quit [Read error: Connection reset by peer]
Gasher has joined #crystal-lang
Gasher has quit [Read error: Connection reset by peer]
Gasher has joined #crystal-lang
pawnbox has joined #crystal-lang
trapped has joined #crystal-lang
ponga has joined #crystal-lang
<BlaXpirit> I don't understand how I can make a private module that can be used only by the library itself
<BlaXpirit> how to make a helper function and use it without exposing it
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
knoopx has joined #crystal-lang
<BlaXpirit> I also want some library-wide private utility macros
knoopx has quit [Remote host closed the connection]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
<emancu> BlaXpirit: i think i have a _hack_ to do that
<emancu> first of all, to do a private function (or method) just do `private def hola`
<BlaXpirit> yeah then I can't use it
<emancu> where ?
<emancu> BlaXpirit: I'm using it
<BlaXpirit> emancu, this is within the same file
<emancu> so i don't get what you want to do
<BlaXpirit> emancu, make helper functions in one file and use them in other files of the library without exposing them to the user of the library
<emancu> i see
<emancu> give me a minute
pawnbox has quit [Ping timeout: 248 seconds]
<asterite> BlaXpirit: you can use protected for that
<BlaXpirit> I was under the impression that protected is more private than private
<asterite> we changed the meaning from ruby
<asterite> well, in ruby private is more private than protected too
<asterite> (but I changed that page a few days ago, previously protected was like in ruby)
<emancu> 2. instances in the same namespace (class, struct, module, etc.) as the current type
<BlaXpirit> I'm gonna try that in a while
<BlaXpirit> aaand it worked! thanks!
<crystal-gh> [crystal] Ryuuzakis closed pull request #2297: Improved complex.cr documentation (master...ComplexDocumentation) https://git.io/vaGtr
<crystal-gh> [crystal] Ryuuzakis opened pull request #2315: Improved complex.cr documentation (master...ComplexDocumentationV2) https://git.io/vaKDm
trapped has quit [Ping timeout: 246 seconds]
Philpax has quit [Ping timeout: 244 seconds]
trapped has joined #crystal-lang
marcosdsanchez has joined #crystal-lang
bjz has quit [Quit: Textual IRC Client: www.textualapp.com]
<crystal-gh> [crystal] Nesqwik closed pull request #2234: Add shuffle with seed and tests for StaticArray (master...static_array) https://git.io/v2unn
bjz has joined #crystal-lang
mgarciaisaia has joined #crystal-lang
mgarciaisaia has left #crystal-lang [#crystal-lang]
bjz has quit [Ping timeout: 244 seconds]
bjz has joined #crystal-lang
<crystal-gh> [crystal] Nesqwik opened pull request #2316: Add shuffle with seed and tests for StaticArray (master...shuffle_static_array) https://git.io/vaKhn
ql6wlld has joined #crystal-lang
PragTob has quit [Ping timeout: 276 seconds]
matp has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
matp has joined #crystal-lang
tamole has joined #crystal-lang
mgarciaisaia has joined #crystal-lang
<BlaXpirit> p(JSON.parse("5") as Int32) # can't cast JSON::Any to Int32
<BlaXpirit> why???
mgarciaisaia has left #crystal-lang [#crystal-lang]
<BlaXpirit> this must've changed. now .as_i is a thing
<umurgdk> BlaXpirit: isn't that expected result? since it is not possible to convert any json value to int32
<umurgdk> but i think Int32? should be possible
<BlaXpirit> umurgdk, no
<BlaXpirit> >> (true ? 5 : "a") as Int32
<DeBot> BlaXpirit: # => 5 - https://carc.in/#/r/ucn
<BlaXpirit> >> (false ? 5 : "a") as Int32
<DeBot> BlaXpirit: can't cast String to Int32 - https://carc.in/#/r/uco
<BlaXpirit> ok this is a compile time error so my exmaple shows nothing
<umurgdk> yeah compiler knows possible path in that example
ql6wlld has quit [Quit: WeeChat 1.4]
matp has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
umurgdk has quit [Remote host closed the connection]
umurgdk has joined #crystal-lang
matp has joined #crystal-lang
<crystal-gh> [crystal] asterite closed pull request #976: [WIP] Implement ASTPrinter (master...feature/ast_print) https://git.io/va62C
<crystal-gh> [crystal] asterite closed pull request #1091: Add type restrictions to `Array#concat` (master...fix/array_concat_type) https://git.io/va62M
marcosdsanchez has quit [Read error: Connection reset by peer]
marcosdsanchez has joined #crystal-lang
<crystal-gh> [crystal] asterite closed pull request #1134: Add support for concurrency safe file operations. (master...f/openat) https://git.io/va62b
<crystal-gh> [crystal] asterite closed pull request #1399: Add Singleton Module. (master...f/singleton) https://git.io/va6Vf
<crystal-gh> [crystal] asterite closed pull request #1521: Changed 2 lines in time/time.cr to calculate local time correctily wh… (master...master) https://git.io/va6V8
<crystal-gh> [crystal] asterite closed pull request #1601: Add reallocation and concatenation methods for slice (master...reallocate-slice) https://git.io/va6wf
<crystal-gh> [crystal] asterite closed pull request #1609: New class Mmap. (master...f/mmap) https://git.io/va6ww
<crystal-gh> [crystal] asterite closed pull request #1611: add Enumerable#pmap (master...pmap) https://git.io/va6rk
umurgdk has quit [Read error: Connection reset by peer]
umurgdk has joined #crystal-lang
<crystal-gh> [crystal] asterite closed pull request #1612: Mutex and thread attribute enhancements (master...f/mutex) https://git.io/va6oJ
<crystal-gh> [crystal] asterite closed pull request #1627: Basic pthread_attr support. (master...f/pthread_attribute) https://git.io/va6o3
pawnbox has joined #crystal-lang
umurgdk has quit [Remote host closed the connection]
mgarciaisaia1 has joined #crystal-lang
umurgdk has joined #crystal-lang
pawnbox has quit [Ping timeout: 260 seconds]
mgarciaisaia1 has left #crystal-lang [#crystal-lang]
pawnbox has joined #crystal-lang
tamole has quit [Quit: bye]
umurgdk has quit [Remote host closed the connection]
rok has joined #crystal-lang
<donpdonp> are there plans/ideas for defining the type of a method return value?
<BlaXpirit> donpdonp, but it's always been there
<donpdonp> BlaXpirit: orly
<donpdonp> only for method parameters
<BlaXpirit> donpdonp, that's a big oversight in docs then
<jeromegn> it's infered or you can do something like `def add(a, b) : Int32`
<BlaXpirit> def f(x : Int32) : Int
<donpdonp> ah, fantastic. yes that needs to be documented
<jeromegn> I think, in general, the best practice is not to specify types and just use the global inference.
<donpdonp> def value : Float64; "hi"; end
<BlaXpirit> jeromegn, nah that sucks
<BlaXpirit> best practice is specifying return type, for documentation
<donpdonp> type must be Float64, not Sting.
<jeromegn> oh is it?
<BlaXpirit> it's the easiest and most important part of documentation
<donpdonp> note that error was caught at compile time.
<donpdonp> whoops wrong channel sorry, ignore that last msg
<donpdonp> jeromegn: i find the value comes from specifying what I expected
<RX14> BlaXpirit, I would specify return type, but not parameter type
<RX14> because paramter types allow the user to duck type
<RX14> but the return type is usually fixed
ssvb has joined #crystal-lang
ponga has quit [Quit: Connection closed for inactivity]
<crystal-gh> [crystal] marceloboeira opened pull request #2317: Add HTTP::Client::Response status code helpers (master...response-helpers) https://git.io/va65w
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
pawnbox has quit [Remote host closed the connection]
pawnbox_ has joined #crystal-lang
bjz_ has joined #crystal-lang
bjz has quit [Ping timeout: 248 seconds]
greengriminal has joined #crystal-lang
pawnbox_ has quit [Remote host closed the connection]
pawnbox_ has joined #crystal-lang
pawnbox_ has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
mgarciaisaia has joined #crystal-lang
mgarciaisaia has left #crystal-lang [#crystal-lang]
luislavena has joined #crystal-lang
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
pawnbox has quit [Ping timeout: 244 seconds]
Excureo has quit [Remote host closed the connection]
tomchapin has joined #crystal-lang
Excureo has joined #crystal-lang
pawnbox has joined #crystal-lang
<crystal-gh> [crystal] asterite closed pull request #2080: Add Changelog episode badge to README (master...patch-1) https://git.io/vaiR0
ragmaanir has joined #crystal-lang
umurgdk has joined #crystal-lang
emancu_ has joined #crystal-lang
trapped_ has joined #crystal-lang
braidn has quit [Ping timeout: 276 seconds]
emancu has quit [Ping timeout: 276 seconds]
ldlework has quit [Ping timeout: 276 seconds]
rok has quit [Ping timeout: 276 seconds]
ldlework has joined #crystal-lang
trapped has quit [Ping timeout: 248 seconds]
g3funk has joined #crystal-lang
umurgdk has quit [Ping timeout: 264 seconds]
_ has joined #crystal-lang
_ is now known as Guest81970
trapped_ has quit [Ping timeout: 244 seconds]
umurgdk has joined #crystal-lang
irvingprime has joined #crystal-lang
<travis-ci> bcardiff/crystal#5bcf6d5 (master - Fixed #2314: Local variable type gets mixed with block argument's type): The build passed. https://travis-ci.org/bcardiff/crystal/builds/117015115
<crystal-gh> [crystal] bcardiff merged upstream-master into master: https://git.io/vaiMq
irvingprime has quit []
umurgdk has quit [Remote host closed the connection]
umurgdk has joined #crystal-lang
<travis-ci> crystal-lang/crystal#437f4cf (master - Time to play! add `crystal play`): The build passed. https://travis-ci.org/crystal-lang/crystal/builds/117019067
umurgdk has quit [Read error: Connection reset by peer]
umurgdk has joined #crystal-lang
Renich has joined #crystal-lang
<travis-ci> bcardiff/crystal#437f4cf (master - Time to play! add `crystal play`): The build passed. https://travis-ci.org/bcardiff/crystal/builds/117023909
bcardiff has joined #crystal-lang
umurgdk has quit [Read error: Connection reset by peer]
umurgdk has joined #crystal-lang
luislavena has quit [Quit: Leaving]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
Philpax has joined #crystal-lang
Renich has quit [Quit: leaving]
Philpax has quit [Read error: Connection reset by peer]
pawnbox has quit [Ping timeout: 244 seconds]
umurgdk has quit [Read error: Connection reset by peer]
umurgdk has joined #crystal-lang
hwpplayer1 has joined #crystal-lang
ragmaanir has quit [Quit: Leaving]
pawnbox has joined #crystal-lang
pawnbox has quit [Remote host closed the connection]
Gasher has quit [Ping timeout: 260 seconds]
Gasher has joined #crystal-lang
greengriminal has quit [Quit: Leaving]
umurgdk has quit [Read error: Connection reset by peer]
umurgdk has joined #crystal-lang