ChanServ changed the topic of #crystal-lang to: The Crystal programming language | | Fund Crystal's development: | GH: | Docs: | Gitter:
deavmi has quit [Read error: Connection reset by peer]
deavmi has joined #crystal-lang
ur5us has quit [Ping timeout: 240 seconds]
ur5us has joined #crystal-lang
<FromGitter> <HertzDevil> ```code paste, see link``` []
<FromGitter> <HertzDevil> soon
postmodern has quit [Quit: Leaving]
ur5us has quit [Ping timeout: 252 seconds]
ur5us has joined #crystal-lang
ur5us has quit [Quit: Leaving]
ur5us has joined #crystal-lang
ur5us has quit [Ping timeout: 246 seconds]
HumanG33k has joined #crystal-lang
aquijoule__ has quit [Remote host closed the connection]
aquijoule__ has joined #crystal-lang
kevinsjoberg has quit [Ping timeout: 252 seconds]
kevinsjoberg has joined #crystal-lang
<FromGitter> <RespiteSage> Does stdlib have its own logic for type promotion when adding different numeric types, or does it rely on LLVM for that?
<FromGitter> <RespiteSage> In particular I'm thinking about the case of `a + b`, where `b` is a wider type than `a`.
<FromGitter> <RespiteSage> So like `Int8#+(UInt64)`, as an extreme example.
<FromGitter> <Daniel-Worrall> Int#+(otherInt) returns self class, so no
<FromGitter> <RespiteSage> No, that's not what I mean.
<FromGitter> <Daniel-Worrall> It'll raise overflow, not promote
<FromGitter> <RespiteSage> This is what I mean:
<FromGitter> <RespiteSage> Maybe "type promotion" was the wrong wording.
<FromGitter> <RespiteSage> Unless I'm sorely mistaken, the hardware doesn't do arithmetic on numbers of mismatched length, so either Crystal or LLVM has to turn those numbers into the same type under the covers.
<FromGitter> <RespiteSage> Presumably it's the larger type, and then they try to convert it to the left-hand type, which could raise overflow.
<FromGitter> <RespiteSage> I'm asking this because I'm trying to handle arithmetic with mismatched numeric types in saline (
HumanG33k has quit [Quit: WeeChat 2.3]
HumanG33k has joined #crystal-lang
<FromGitter> <Daniel-Worrall> yikes, my playground docker container was using 1.2GB of memory
Guest15 has joined #crystal-lang
<Guest15> hello all. i am wondering if variadic functions are supported for crystal functions and procs. ive tried playing around with VaList and viewing the specs around it, but i cant seem to make sense of it. does anyone happen to have an example of passing multiple arguments via variadic functions with crystal?
<FromGitter> <HertzDevil> c funs: no (crystal-lang/crystal#214)
<FromGitter> <HertzDevil> maybe you could use valist exactly like c i don't know
ur5us has joined #crystal-lang
ur5us has quit [Ping timeout: 240 seconds]
wolfshappen has quit [Quit: later]
wolfshappen has joined #crystal-lang