<FromGitter>
<octosteve> Hello! Started taking a real look at crystal today and I LOVE IT!!
<FromGitter>
<octosteve> Running into something weird when trying to write a DSL. I'm trying to pass a class into a macro and the error I'm getting thinks it's a path
<FromGitter>
<octosteve> I think I muscled through it somehow
<FromGitter>
<octosteve> I have another question though. Regarding types. How do I match that the *type* of an argument is a particular class?
<FromGitter>
<octosteve> not an instance of that class?
<FromGitter>
<octosteve> Yea I think I'm in a weird rabbit hole. So I'm trying to figure out a type that works for a set of classes that *include* a certain module
<FromGitter>
<octosteve> Error: no overload matches 'Hash(String, Protobuf::Message:Module)#[]=' with types String, Events::AThingWasDone.class
<FromGitter>
<octosteve> That's what my error looks like. I'm trying to setup a hash that has a string key, and a value of a class that includes the Protobuf::Message module
<FromGitter>
<octosteve> so the hash is there to convert the values
<FromGitter>
<octosteve> Maybe? You don't know what you're going to get over the wire
<FromGitter>
<Blacksmoke16> fair
<FromGitter>
<octosteve> This is fun!
<FromGitter>
<octosteve> Been nose down on Elixir for a bit so I'm looking for pattern matching a lot. Didn't know if that overloading pattern was *right*
<FromGitter>
<octosteve> One thing I am trying to noodle over is recovering from failure. No supervision trees! If my rabbit connection croaks, I'll just have to rescue in my spawn I guess and restart
_whitelogger has joined #crystal-lang
ua_ has joined #crystal-lang
ua has quit [Ping timeout: 240 seconds]
postmodern has joined #crystal-lang
zorp_ has quit [Ping timeout: 246 seconds]
<deimos_>
I think i have a comipler bug, but no idea how to go about debugging it. if i run ```crystal run code.cr``` everything works. if i run ```cyrstal build code.cr```, the resulting binary works fine. if i add --release to the build code.cr, i get a indexerror in boehm.cr
<deimos_>
i'm trying to recreate to get more detail
<FromGitter>
<naqvis> doesn't the stacktrace shows the details about the line of code which triggering that error?
<FromGitter>
<naqvis> might worth adding `--debug` during your build
zorp_ has joined #crystal-lang
hsh has joined #crystal-lang
bazaar has quit [Quit: leaving]
bazaar has joined #crystal-lang
alexherbo2 has joined #crystal-lang
zorp_ has quit [Ping timeout: 240 seconds]
alexherbo2 has quit [Ping timeout: 246 seconds]
alexherbo2 has joined #crystal-lang
alexherbo21 has joined #crystal-lang
alexherbo2 has quit [Ping timeout: 240 seconds]
alexherbo21 is now known as alexherbo2
postmodern has quit [Quit: Leaving]
_whitelogger has joined #crystal-lang
deavmi has quit [Read error: Connection reset by peer]
deavmi_ has joined #crystal-lang
Vexatos has quit [Quit: ZNC Quit]
Vexatos has joined #crystal-lang
psydroid has quit [Quit: killed]
ryanprior has quit [Quit: killed]
return0e[m] has quit [Quit: killed]
hamoko[m] has quit [Quit: killed]
deavmi_ has quit [Read error: Connection reset by peer]
<FromGitter>
<Blacksmoke16> is there something you're working on that needs that?
<FromGitter>
<mtsmmp_gitlab> it would help
<FromGitter>
<mtsmmp_gitlab> would be faster
<FromGitter>
<Blacksmoke16> got an example of what your use case is?
<FromGitter>
<mtsmmp_gitlab> its like
<FromGitter>
<mtsmmp_gitlab> i have the classes' names stored already somewhere, instead of picking which one ill instantiate i would just loop through the data and instantiate them straight up. without having to create a class to control which one im calling
<FromGitter>
<mtsmmp_gitlab> like this i would be just passing information through different functions and i dont like that
<FromGitter>
<Blacksmoke16> can you share more of what you're ultimately trying to do?
<FromGitter>
<Blacksmoke16> like you're storing them in a file and wanting to create an instance of each class based on the data from the file?
<FromGitter>
<mtsmmp_gitlab> ```Class.new(first_param, some_param, other_param, param: "something_cool")``` ⏎ ⏎ how do i get the first_param, isolate it and pass everything that is after to another function? i know its a noob question but i was thinking about doing something with it [https://gitter.im/crystal-lang/crystal?at=5f52810a49148b41c99489b9]
<FromGitter>
<Blacksmoke16> could do something like