ChanServ changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.23.1 | Fund Crystal's development: http://is.gd/X7PRtI | GH: https://github.com/crystal-lang/crystal | Docs: http://crystal-lang.org/docs/ | API: http://crystal-lang.org/api/ | Gitter: https://gitter.im/crystal-lang/crystal
aroaminggeek has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<FromGitter> <akzhan> looks ike we need need hashed from @funyy-falcon and will what em all… lustly joke
mooe_ has quit [Quit: Connection closed for inactivity]
DTZUZU has quit [Quit: WeeChat 1.9]
<RX14> well
<RX14> looks like the crystal arch package is on 0.24.0
<RX14> which isn't even a real release
<RX14> such a mess
stephenwithav has quit [Read error: Connection reset by peer]
stephenwithav has joined #crystal-lang
stephenwithav has quit [Changing host]
stephenwithav has joined #crystal-lang
DTZUZU has joined #crystal-lang
faustinoaq has joined #crystal-lang
<FromGitter> <jwoertink> Is there a way to call one macro from another?
vivus has joined #crystal-lang
aroaminggeek has joined #crystal-lang
<Papierkorb> just use the macro in a macro?
<FromGitter> <jwoertink> I get `can't nest macro expressions`
<Papierkorb> "No code no help"
<FromGitter> <jwoertink> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a18c40571ad3f873628a46f]
<FromGitter> <jwoertink> `undefined local variable or method 'a`
<FromGitter> <jwoertink> which would make sense here, and I understand why
<FromGitter> <jwoertink> but this is the most simple way I can show "call one macro from another"
<Papierkorb> If you understand why, why don't you post working code?
<FromGitter> <jwoertink> lol. because If I had working code, I wouldn't be asking the question
<Papierkorb> `::Thing.a` in b.
<FromGitter> <jwoertink> ah!
<FromGitter> <jwoertink> awesome! Thanks.
<Papierkorb> macros are *expanded*. They work on the AST. They're expanded locally where you "call" them (hence we say macros are expanded, not called or invoked).
<Papierkorb> Thus, in a macro body, you have to take into account that your code is actually living in the scope of the users code, and not in your class
<FromGitter> <jwoertink> oh, ok. Yeah, that makes sense.
shankar has joined #crystal-lang
vivus has quit [Quit: Leaving]
shankar has quit [Remote host closed the connection]
shankar has joined #crystal-lang
shankar has quit [Quit: Leaving]
aroaminggeek has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
watzon_ has quit [Remote host closed the connection]
watzon_ has joined #crystal-lang
<FromGitter> <codenoid> morning crystaller
sz0 has quit [Quit: Connection closed for inactivity]
<bmcginty> I was just going through some of the crystal code, trying to modernize txe's crystal-win branch to get Crystal to run with the current commit. However, I see there are all these crystal::system changes. I'd like to assist with the windows porting, but don't want to do work that's going to just be scrapped as others have partiall done it already. Anyone have suggestions?
DTZUZO has joined #crystal-lang
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 260 seconds]
snsei has joined #crystal-lang
PixeLInc has quit [Ping timeout: 246 seconds]
claudiuinberlin has joined #crystal-lang
rohitpaulk has joined #crystal-lang
olbat has quit [Ping timeout: 268 seconds]
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
PixeLInc has joined #crystal-lang
olbat has joined #crystal-lang
olbat has joined #crystal-lang
olbat has quit [Changing host]
sz0 has joined #crystal-lang
<FromGitter> <extremety1989> hope someone will help me =)
alex`` has joined #crystal-lang
alex`` is now known as alexherbo2
alexherbo2 is now known as alex``
alex`` is now known as alexherbo2
snsei has quit [Remote host closed the connection]
snsei has joined #crystal-lang
snsei has quit [Ping timeout: 255 seconds]
alexherbo2 is now known as alex``
faustinoaq has quit [Ping timeout: 255 seconds]
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 250 seconds]
faustinoaq has joined #crystal-lang
rohitpaulk has joined #crystal-lang
aroaminggeek has joined #crystal-lang
aroaminggeek has quit [Ping timeout: 260 seconds]
maxpert has joined #crystal-lang
<maxpert> hmmm
maxpert has quit [Remote host closed the connection]
maxpert has joined #crystal-lang
<FromGitter> <lwakefield> Hey, I am sure I am going about this the wrong way, but what is the easiest way to create a `JSON::Any` from a hash literal: ex. `JSON::Any.new({"foo": "bar"})`
<FromGitter> <extremety1989> @lwakefield have you tried it on postgres ?
maxpert has quit [Ping timeout: 250 seconds]
<FromGitter> <lwakefield> No, but unless I am missing something @extremety1989, I don't see how that is related?
<FromGitter> <extremety1989> @lwakefield well
<FromGitter> <extremety1989> im trying to insert json data to postgres
<FromGitter> <extremety1989> using token field as jsnb
<FromGitter> <extremety1989> jsonb
<FromGitter> <extremety1989> ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a19837c8b3a9e2c0c182830]
<FromGitter> <extremety1989> in my database tokens table, the field token is jsonb
<FromGitter> <lwakefield> I think we may be talking at cross purposes @extremety1989, I am asking a separate question :)
<FromGitter> <extremety1989> @lwakefield aa ))
<FromGitter> <bew> @lwakefield don't think there's another way, but why would you want a JSON::Any object?
maxpert has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 268 seconds]
maxpert_ has joined #crystal-lang
rohitpaulk has joined #crystal-lang
maxpert has quit [Ping timeout: 240 seconds]
<FromGitter> <unreadable> some fun with shaders and sine function
alex`` has quit [Quit: WeeChat 1.9.1]
maxpert_ has quit [Remote host closed the connection]
<FromGitter> <lwakefield> @bew bummer. Ideally it would be a convenience thing, for testing some framework code.
<FromGitter> <lwakefield> I suppose serializing & deserializing isn't that big of a deal if it is just testing code.
<Papierkorb> lwakefield, there's a convenient thing to do it: Simply `JSON.parse` a json document. For testing I this may be fine.
<Papierkorb> Note that you can use `%<...>` instead of double-quotes, so you don't have to unescape them in the document when writing it manually.
maxpert has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 240 seconds]
<FromGitter> <lwakefield> Oh nice, that makes much more sense than having the overhead of serializing.
<FromGitter> <lwakefield> Thanks @Papierkorb!
sz0 has quit [Quit: Connection closed for inactivity]
rohitpaulk has joined #crystal-lang
maxpert has quit [Remote host closed the connection]
faustinoaq has quit [Quit: IRC client terminated!]
maxpert has joined #crystal-lang
maxpert has quit [Ping timeout: 248 seconds]
maxpert has joined #crystal-lang
maxpert has quit [Remote host closed the connection]
hightower2 has joined #crystal-lang
hightower2 has quit [Client Quit]
hightower3 has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 240 seconds]
rohitpaulk has joined #crystal-lang
<hightower3> Is it expected that 0.24.0 prerelease reports "Crystal 0.23.0+313 [ea4187c57] (2017-10-27)" in crystal -v ?
<FromGitter> <straight-shoota> hightower3, yes
<FromGitter> <straight-shoota> but I think this could be improved
maxpert has joined #crystal-lang
maxpert has quit [Remote host closed the connection]
maxpert has joined #crystal-lang
maxpert has quit [Remote host closed the connection]
aroaminggeek has joined #crystal-lang
rohitpaulk has quit [Ping timeout: 248 seconds]
aroaminggeek has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
faustinoaq has joined #crystal-lang
faustinoaq has quit [Ping timeout: 246 seconds]
<FromGitter> <MrSorcus> https://github.com/crystal-community/leveldb - why here PR doesn't accepted? This shard failed when building, but in PR available fix. (unexpected token: as) change line 9 to `@err_ptr = pointerof(@err_address).as(Pointer(UInt64))`
<oprypin> I don't understand what you're saying
<oprypin> MrSorcus, perhaps your version of Crystal is outdated?
<FromGitter> <MrSorcus> > **<oprypin>** @MrSorcus, perhaps your version of Crystal is outdated? ⏎ ⏎ ```code paste, see link``` [https://gitter.im/crystal-lang/crystal?at=5a19d24b540c78242d4a58aa]
<oprypin> MrSorcus, it's likely that your download of the shard doesnt have the latest code
<oprypin> because the released version is old
<oprypin> do you use shard.yml ? maybe specify branch: master for the dependency
<bmcginty> I'm going through the windows code that txe and others have written, and just planning on working on everything until specs pass. Is that a good plan, or is someone else working on any part of it currently?
snsei has joined #crystal-lang
<oprypin> bmcginty, well there's the opinion that this should be planned and done gradually and that the fork is messy,
<oprypin> but nobody's actually doing the work
<oprypin> i'd love to merge any such fork but i dont have a say
<bmcginty> oprypin: Okay. I couldn't eve figure out which way the crystal::system thing is headed, or I'd pull all my changes to the latest commit.
<FromGitter> <MrSorcus> > **<oprypin>** do you use shard.yml ? maybe specify branch: master for the dependency ⏎ ⏎ Oh, you right. Thank you.
<oprypin> well it's staying in, unfortunately, and not really moving anywhere, like everything else
<bmcginty> I'll try to get all this working as quick as I can and maybe that'll be enough to push things forward a bit. Though contributers to the original windows PR have done the difficult bits with stacks and the like.
<oprypin> bmcginty, well you can keep doing the work, just don't expect it to be merged ¯\_(ツ)_/¯
<FromGitter> <MrSorcus> https://crystal-lang.org/api/0.23.1/OpenSSL/Digest.html#new%28name%2Cctx%3ALibCrypto%3A%3AEVP_MD_CTX%29-class-method ⏎ Broken link.
<oprypin> MrSorcus, it's really just broken API. lib things are not supposed to show up in docs
<FromGitter> <jwoertink> Hey @oprypin, can you explain how this works? https://github.com/oprypin/crsfml-examples/blob/master/2048/2048.cr#L325 Mainly just the fact that you're doing addition with a tuple. Is there an override somewhere that adds a `def +(nums : Tuple(Int32, Int32))`?
<FromGitter> <jwoertink> Oohh! Ok. Vectors!
<FromGitter> <jwoertink> Thanks :D
<oprypin> it's kind of a hack, really should be `SF.vector2(0, -75)` but too neat to pass up
<FromGitter> <jwoertink> haha yeah. That makes sense. This whole thing is pretty wild.
faustinoaq has joined #crystal-lang
faustinoaq has quit [Ping timeout: 248 seconds]
aroaminggeek has joined #crystal-lang
faustinoaq has joined #crystal-lang
claudiuinberlin has quit [Quit: Textual IRC Client: www.textualapp.com]
aroaminggeek has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
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
snsei has joined #crystal-lang
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
snsei has quit [Remote host closed the connection]
aroaminggeek has joined #crystal-lang
maxpert has joined #crystal-lang
vivus has joined #crystal-lang