bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<crystal-gh>
[crystal] Sija opened pull request #3860: Implement Char#* operator (master...char-times-operator) https://git.io/vMCyE
A124 has quit [Ping timeout: 255 seconds]
soveran has joined #crystal-lang
soveran has quit [Ping timeout: 240 seconds]
bjz has joined #crystal-lang
pawnbox has joined #crystal-lang
unshadow has quit [Ping timeout: 256 seconds]
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #crystal-lang
pawnbox has quit [Ping timeout: 248 seconds]
pawnbox has joined #crystal-lang
unshadow has joined #crystal-lang
unshadow has quit [Ping timeout: 255 seconds]
unshadow has joined #crystal-lang
soveran has joined #crystal-lang
<manveru>
is there some way to make the docs work offline as well? right now it tries to fetch each page using ajax...
<manveru>
got a long flight and i'd like to learn it a bit during that time :)
<manveru>
in the worst case i can open each doc page from the directory, it's just a bit annoying
Yxhuvud has quit [Read error: Connection reset by peer]
Yxhuvud has joined #crystal-lang
Raimondi has quit [Read error: Connection reset by peer]
Raimondi has joined #crystal-lang
<unshadow>
jhass: When will you update the arch package ? (do you want me to push a new package file?)
A124 has joined #crystal-lang
bjz_ has joined #crystal-lang
bjz has quit [Ping timeout: 258 seconds]
<Yxhuvud>
manveru: if nothing else, the API docs is generated from the main crystal repo. Dunno where the gitbook is generated, but it should be possible to find from github.com/crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
soveran has joined #crystal-lang
soveran has joined #crystal-lang
soveran has quit [Changing host]
soveran has quit [Ping timeout: 245 seconds]
DeBot has quit [Read error: Connection reset by peer]
DeBot has joined #crystal-lang
cyjimmy264 has joined #crystal-lang
<BlaXpirit>
mjago, you must give the pointer to the memory region, not a pointer to the pointer
<BlaXpirit>
use `max.to_unsafe` to get a pointer to the memory region
<BlaXpirit>
the 0 is just reading some random memory location
akwiatkowski has quit [Ping timeout: 264 seconds]
<FromGitter>
<mjago> @BlaXpirit Thanks for that. I’m still getting comfortable with Slice and forget its a pointer! max without to_unsafe worked also so I guess it is getting called anyway? (argument is a Void*)
<RX14>
yes
<RX14>
to_unsafe is automatically called when sending items to lib bindings
<RX14>
i'm not all to happy about that myself but it's a thing
<FromGitter>
<mjago> Ok thanks!
cyjimmy264 has quit [Ping timeout: 240 seconds]
cyjimmy264 has joined #crystal-lang
unshadow has quit [Quit: leaving]
akwiatkowski has joined #crystal-lang
akwiatkowski has quit [Read error: Connection reset by peer]
soveran has joined #crystal-lang
soveran has quit [Ping timeout: 240 seconds]
_whitelogger has joined #crystal-lang
<FromGitter>
<exts> how do i dynamically call a def of class using a string var?
<Papierkorb>
You don't
<Papierkorb>
Or rather, you can't
akwiatkowski has joined #crystal-lang
<Papierkorb>
use a case statement or a Hash(String, Proc) instead depending on your needs
unshadow has joined #crystal-lang
<FromGitter>
<exts> can't do that with what I'm trying to accomplish, is there a way to do it with macros ?
<Papierkorb>
No.
<Yxhuvud>
so what ARE you trying to accoplish?
<Yxhuvud>
perhaps there is a better way
akwiatkowski has quit [Read error: Connection reset by peer]
<renovo>
clang: error: linker command failed with exit code 1 (use -v to see invocation)
<renovo>
sorry, did not mean the above
<renovo>
Even so! Just came across crystal-lang and installed 0.20.4 on a mac 10.12.1 and getting the error above - openssl is installed on my system. Thanks.
<unshadow>
renovo: Don't know how it is in Mac , but in Linux I know you need the -dev packages to be avilable for you to compile programs against the libs, so see if you have openssl-dev or libssl-dev , or something like that
<steenuil>
nope, OS X ships with the binary but not with the headers for openssl, so if you want to compile something that links openssl you have to pass some special flags
<steenuil>
since the headers you install from homebrew are not linked by default due to possible problems
<steenuil>
so you need to specify the location of the openssl headers yourself
<renovo>
And when I run $> crystal play ? Is there a flag I must pass?
<steenuil>
I have no idea
<FromGitter>
<exts> anywhere i can read more on macros?
<RX14>
@exts have you read the docs?
hako has quit [Ping timeout: 240 seconds]
DeBot has quit [Read error: Connection reset by peer]
DeBot has joined #crystal-lang
soveran has quit [Remote host closed the connection]
<FromGitter>
<exts> I have
cyjimmy264 has quit [Ping timeout: 240 seconds]
hako has joined #crystal-lang
cyjimmy264 has joined #crystal-lang
soveran has joined #crystal-lang
soveran has joined #crystal-lang
soveran has quit [Changing host]
bjz has joined #crystal-lang
<manveru>
i think in found a bug in StringScanner
<manveru>
require "string_scanner"; s = StringScanner.new("hi"); s.scan(/./); s.inspect
<manveru>
that fails with `Index out of bounds (IndexError)`
soveran has quit [Remote host closed the connection]
<Yxhuvud>
io << " \"" << @str[start, 5] << "\" >"
<Yxhuvud>
yeah, seems to fail on too short strings.
<manveru>
yeah, also when you're close to the end in long strings
<manveru>
should i make a PR for that?
<manveru>
been only trying crystal for 1-2h but it seems quite nice so far
<Yxhuvud>
I can't see why a fix for that wouldn't be accepted.
<manveru>
just have to manage cloning the repo on this slow-ass connection :)
<Yxhuvud>
heh.
renovo has quit [Remote host closed the connection]
<Yxhuvud>
So far, Crystal has only been growing on me. Sure, there are some parts that are immature, but the overall direction of it is awesome.
LastWhisper____ has joined #crystal-lang
renovo has joined #crystal-lang
bjz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dom96 has quit [Changing host]
dom96 has joined #crystal-lang
soveran has joined #crystal-lang
soveran has joined #crystal-lang
soveran has quit [Changing host]
soveran has quit [Ping timeout: 240 seconds]
matp has quit [Remote host closed the connection]
matp has joined #crystal-lang
Kug3lis has joined #crystal-lang
cyjimmy264 has quit [Ping timeout: 245 seconds]
<crystal-gh>
[crystal] manveru opened pull request #3861: StringScanner should work with small strings (master...fix-stringscanner-inspect) https://git.io/vMWRU
<manveru>
but the docs only list Char#==(Char) and Char#==(Int)
<manveru>
maybe it's something in a superclass of Char
<manveru>
ah, yeah, Value#== always returns false
cyjimmy264 has quit [Ping timeout: 255 seconds]
<manveru>
i'll have to read more on the type system... i wasn't expecting that crystal just allows `def ==(other)` to allow any type, shouldn't that be inferred instead?
<Yxhuvud>
well, it will check if you try to invoke any method that doesn't exist. Otherwise, it will happily ducktype for you