<FromGitter>
<mattrberry> Just increments off of the last value I guess..
ur5us has quit [Quit: Leaving]
ur5us has joined #crystal-lang
ur5us has quit [Ping timeout: 255 seconds]
Sankalp has quit [Ping timeout: 268 seconds]
Sankalp- has joined #crystal-lang
Sankalp- is now known as Sankalp
<FromGitter>
<azurelmao> Sankalp: Ok, so the reason why bar.as(Bar) was returning (Bar | Nil) was because of the unless statement. This snippet works: https://play.crystal-lang.org/#/r/dp5a
kiwiroy has quit [Ping timeout: 268 seconds]
kiwiroy has joined #crystal-lang
<FromGitter>
<Blacksmoke16> i feel like there's a better way to do what you're doing
<FromGitter>
<Blacksmoke16> @azurelmao is the goal to just have a singleton type that's lazily initialized?
hightower2 has quit [Remote host closed the connection]
<FromGitter>
<azurelmao> Wow, this is much cleaner!
<FromGitter>
<azurelmao> Thanks!
<FromGitter>
<Blacksmoke16> np
_ht has quit [Quit: _ht]
<FromGitter>
<azurelmao> Is there a cleaner way to do this? Preferably so that I can just plop Player as the first argument and not *this*https://carc.in/#/r/dpbw
<FromGitter>
<Blacksmoke16> can you not have it just accept `Player`?
<FromGitter>
<Blacksmoke16> and not a proc
<FromGitter>
<azurelmao> Nah I can't. I want to be able to create multiple vars, which would require the the instance var to be generic smth like Class and that isn't possible