ChanServ changed the topic of #crystal-lang to: The Crystal programming language | http://crystal-lang.org | Crystal 0.32.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
<FromGitter> <wontruefree> Anyone who might be interested @veelenga is giving a talk on Ameba in soon https://meet.google.com/jjp-esph-xbm
ur5us has quit [Ping timeout: 256 seconds]
<FromGitter> <watzon> Had an interview today for a Ruby position and had the chance to shill Crystal a little
<FromGitter> <Blacksmoke16> Oh?
ur5us has joined #crystal-lang
<FromGitter> <watzon> Yeah one of the devs seemed very interested in it
<FromGitter> <watzon> I mean who doesn't want Ruby to be faster/
<FromGitter> <Blacksmoke16> indeed :p
alexherbo2 has quit [Quit: The Lounge - https://thelounge.chat]
alex`` has quit [Quit: WeeChat 2.7]
<FromGitter> <Blacksmoke16> well After nearly a year, a rewrite, and a lot of thinking/planning, Athena `0.8.0` is now released: https://github.com/athena-framework/athena/releases/tag/v0.8.0
<FromGitter> <Blacksmoke16> πŸ‘
<FromGitter> <Blacksmoke16> working on the changelog, will update it tomorrow
<FromGitter> <tenebrousedge> πŸš€ πŸŽ‰
<FromGitter> <tenebrousedge> bravo
<FromGitter> <Blacksmoke16> Thanks :)
<FromGitter> <Blacksmoke16> Now just gotta get more people to use it ;)
<FromGitter> <Blacksmoke16> Blog/forum posts to come soon
ur5us has quit [Ping timeout: 240 seconds]
<FromGitter> <BenMusch> Hi! I’m a newcomer to the project interested in contributing to the compiler. I've got things running locally. What's a good way to get started with basic contributions? ⏎ ⏎ Context: I’m a recent college graduate with some experience building compilers (took compilers class + some research on pyret-lang). But I know very little about Crystal internals other than writing some small toy apps ⏎ ⏎
<FromGitter> ... I’ve checked the community:newcomer GitHub label but it doesn’t seem to be super up-to-date [https://gitter.im/crystal-lang/crystal?at=5e3cf2f6594a0517c2709cd4]
<FromGitter> <tenebrousedge> are you on Windows?
<FromGitter> <BenMusch> Nope, mac OS
<FromGitter> <tenebrousedge> hmm
<FromGitter> <shalabhc> Hi folks, I'm new and installing crystal on MacOS. `brew install crystal` has been running for over 30 mins now as my enthusiasm wanes. Seems like it is installing llvm-9.0.1. Is there a faster way to get going on MacOS?
<FromGitter> <tenebrousedge> docker, theoretically
<FromGitter> <tenebrousedge> it's weird that llvm would take that long
<FromGitter> <shalabhc> "Warning: Building llvm from source:" I thought brew would have these precompiled or something.
<FromGitter> <tenebrousedge> did you do `brew install llvm` first?
<FromGitter> <tenebrousedge> I'm one of these penguin people so I don't know that much about brew :/
<FromGitter> <shalabhc> No, it was installing llvm as part of crystal deps. Anyway I might have found the issue
<FromGitter> <shalabhc> > The bottle needs the Xcode CLT to be installed.
<FromGitter> <shalabhc> So I'm installing Xcode command line tools now. Hopefully that fixes it.
<FromGitter> <shalabhc> Crystal looks very interesting, BTW. Even though I'd done more Python :D. I specially like the type inference rules - very practical and out of your way. We'll see how it works out in practice.
<FromGitter> <shalabhc> How much of it is self hosted?
<FromGitter> <tenebrousedge> Crystal is written in Crystal. It uses a few C libraries here and there, e.g. PCRE, OpenSSL
<FromGitter> <tenebrousedge> C interop seems relatively painless
<FromGitter> <shalabhc> I couldn't find a 'who uses crystal' page - is there one?
<FromGitter> <shalabhc> BTW, I understand Crystal has fibers, but does it have shared memory (Go) or isolated heaps (Erlang)?
<FromGitter> <shalabhc> Thanks for the users link - interesting stuff!
<FromGitter> <tenebrousedge> Crystal also has threads, btw. Crystal uses Channels (https://crystal-lang.org/reference/guides/concurrency.html) for fiber communication
<FromGitter> <tenebrousedge> Multithreading hit sometime in the previous quarter, it's behind a compiler flag for now
_ht has joined #crystal-lang
alex` has joined #crystal-lang
alex` is now known as Guest80208
Guest80208 is now known as alex``
_whitelogger has joined #crystal-lang
jetpack_joe has joined #crystal-lang
HumanGeek has quit [Ping timeout: 256 seconds]
HumanGeek has joined #crystal-lang
renich has joined #crystal-lang
<FromGitter> <halfdan> Howdy! I'm trying to add C bindings to C library. Is there a way to inspect how Crystal sees the C library?
<FromGitter> <tenebrousedge> what do you mean?
<FromGitter> <halfdan> I basically have ⏎ ⏎ ``` @[Link("hs")] ⏎ lib LibHyperscan ⏎ ⏎ end``` ⏎ ⏎ but I'm not sure how Crystal will expose the functions/constants defined from libhs [https://gitter.im/crystal-lang/crystal?at=5e3d9a8a62e9db4bf7849f54]
<FromGitter> <halfdan> aite, lemme try that
<FromGitter> <halfdan> how do I map constants from a lib to crystal? i.e. in libhs there's `#define HS_SUCCESS 0`
teardown has quit [Ping timeout: 265 seconds]
<FromGitter> <Blacksmoke16> `HS_SUCCESS = 0`?
<FromGitter> <halfdan> right, so what if the value changes in the library?
<FromGitter> <Blacksmoke16> youd have to update your binding in crystal, but given its a constant, wouldnt that be not something you change often?
<FromGitter> <Daniel-Worrall> you can also programmatically extract it from the lib
<FromGitter> <Daniel-Worrall> there's a proof of concept by asterite lying around somewhere
alex`` has quit [Quit: WeeChat 2.7]
alex` has joined #crystal-lang
alex` is now known as Guest41381
Guest41381 is now known as alex``
<FromGitter> <halfdan> ok, next question: libhs defines a struct hs_database - how do I map/reference this in crystal?
<FromGitter> <watzon> @shalabhc Crystal uses basically the same concurrency model as Go from what I understand
<FromGitter> <watzon> It uses channels for communication between fibers the same way Go does
<FromGitter> <halfdan> @Blacksmoke16 That shows me how to define a struct in crystal and how it maps to C - but it doesn't tell me how to use one already defined in C
<FromGitter> <watzon> Just create a struct called `HsDatabase` with the same fields on it. You should then be able to use it just as you would the C struct.
<FromGitter> <Blacksmoke16> i think a key point you're missing is, as far as i know, you have to make your crystal c binding lib reflect your c library
<FromGitter> <Blacksmoke16> i.e. if a struct is in libhs, you also have to define that in your crystal lib in order to use it
<FromGitter> <watzon> Si senhor
<FromGitter> <Blacksmoke16> you cant just reference the c lib's struct without defining it in your crystal first
<FromGitter> <tenebrousedge> wasn't there a project to generate bindings?
_ht has joined #crystal-lang
<FromGitter> <tenebrousedge> one or the other. bindgen seems to be less maintained
renich_ has joined #crystal-lang
<FromGitter> <636f7374> RUSTGO: CALLING RUST FROM GO WITH NEAR-ZERO OVERHEAD (https://blog.filippo.io/rustgo/)
renich has quit [Ping timeout: 268 seconds]
<FromGitter> <636f7374> CALLING RUST FROM Crystal Will be fun.
<FromGitter> <636f7374> I've seen calling Crystal from Swift before.
renich has joined #crystal-lang
renich_ has quit [Ping timeout: 272 seconds]
<FromGitter> <watzon> I prefer libgen
<FromGitter> <watzon> https://github.com/olbat/libgen
<FromGitter> <watzon> It's based off of crystal_lib I think, but it's a bit easier to use
<FromGitter> <636f7374> bew ⏎ What do you mean by "debug memory leaks"? What are you expecting the tool to do? ⏎ From IRC (bridge bot) ⏎ FromIRC ⏎ <RX14> at least show me the composition of the heap by object type ... [https://gitter.im/crystal-lang/crystal?at=5e3dbadff3718e705deb96b1]
<FromGitter> <halfdan> @watzon Ok, libgen is great. That worked like a charm and saved me a ton of time
alexherbo2 has joined #crystal-lang
<FromGitter> <watzon> Good to hear. I use it all the time
<FromGitter> <grkek> Failed git ls-tree -r --full-tree --name-only v0.1.0 -- shard.yml (). Maybe a commit, branch or file doesn't exist?
<FromGitter> <grkek> what is this error and how do I deal with it ?
<FromGitter> <grkek> I have met that error already for the fifth time
<FromGitter> <Blacksmoke16> whats the context of when it happens?
<FromGitter> <grkek> ``
<FromGitter> <grkek> ```dependencies: ⏎ nodejs: ⏎ github: fukaoi/crystal-nodejs ⏎ ``` [https://gitter.im/crystal-lang/crystal?at=5e3dbcef37545d247d26e29e]
<FromGitter> <grkek> shards install
<FromGitter> <grkek> on that
<FromGitter> <grkek> :')
<FromGitter> <Blacksmoke16> his release tag is `0.1.0` not `v0.1.0`
<FromGitter> <Blacksmoke16> iirc i think thats fixed in shards `0.9.0` but dont quote me
<FromGitter> <watzon> I'd just put `branch: master` for now. Should fix it.
<FromGitter> <Blacksmoke16> `commit: HASH`
<FromGitter> <Blacksmoke16> would be safer
<FromGitter> <watzon> That would probably be better, yes
<FromGitter> <grkek> Thank you guys
<FromGitter> <Blacksmoke16> oh yea btw,
<FromGitter> <Blacksmoke16> > Since the warranty expired a short time ago, we can support a one time out of warranty replacement.
<FromGitter> <Blacksmoke16> they going to replace my GPU :P
<FromGitter> <tenebrousedge> sweet!
<FromGitter> <tenebrousedge> who made it?
<FromGitter> <Blacksmoke16> EVGA
<FromGitter> <tenebrousedge> cool, I'll remember they have good customer service
<FromGitter> <Blacksmoke16> ye, they make the best cards too
<FromGitter> <Blacksmoke16> this is the first i had an issue with
early has quit [Quit: Leaving]
early has joined #crystal-lang
alexherbo21 has joined #crystal-lang
alexherbo2 has quit [Ping timeout: 260 seconds]
alexherbo21 is now known as alexherbo2
alex`` has quit [Ping timeout: 256 seconds]
alex`` has joined #crystal-lang
_ht has quit [Remote host closed the connection]
_ht has joined #crystal-lang
renich has quit [Read error: Connection reset by peer]
renich has joined #crystal-lang
Human_G33k has joined #crystal-lang
HumanGeek has quit [Ping timeout: 260 seconds]
_ht has quit [Remote host closed the connection]
<FromGitter> <Blacksmoke16> https://github.com/athena-framework/athena/releases/tag/v0.8.0 wew, i think i got everything...
<FromGitter> <kinxer> It doesn't look like I can ping @manveru. Does anyone know them? Or am I misremembering their username?
<FromGitter> <Blacksmoke16> Might be
<FromGitter> <Blacksmoke16> Oops
<FromGitter> <kinxer> It looks like the ping worked anyway. Dunno if they're still around here, but I wrote down to tell them when I released my GeoJSON shard (https://github.com/kinxer/crgeojson).
<FromGitter> <kinxer> Related, @Blacksmoke16: I've never set up CI or auto-generated docs or anything on GitHub. Does it seem reasonable to base my setup on yours for Athena?
<FromGitter> <Blacksmoke16> yea should be pretty solid
<FromGitter> <Blacksmoke16> runs CI daily and on PR
<FromGitter> <kinxer> Cool. I'll do that, then.
<FromGitter> <Blacksmoke16> tests format, ameba, and specs latest/nightly
<FromGitter> <Blacksmoke16> api docs are deployed in any push to master
<FromGitter> <Blacksmoke16> workflow is assuming you dont push directly to master, but go via a PR
<FromGitter> <kinxer> Yeah, that's how I prefer to work anyway.
<FromGitter> <Blacksmoke16> perfect
<FromGitter> <Nicolab> @636f7374 ⏎ ⏎ > CALLING RUST FROM Crystal Will be fun. ⏎ ⏎ It's limited to the primitive (including struct) but it works well [https://gitter.im/crystal-lang/crystal?at=5e3deebdecfa4461c048a832]
<FromGitter> <Blacksmoke16> would be nice to run ci on push and PR, but if you setup both then it runs it twice when a PR is open
<FromGitter> <Blacksmoke16> and if you only do push then contributors stuff wont run, and if you only do PR wont run until you make the PR, which is decent, esp with draft PRs these days