I started to do a little bit of code involving floats operation on recent build. Experience is horrible dbg crashing constantly , simple stuff like Num.floor, Num.rond crashing , Dec numbers practically unusable. Do you know older builds where those things used to work better. Btw I was mentioning that but when I create a lot of tags and to some of them I attach floats , hell breaks loose, it is extremely difficult to do anything with such constructions later on. all the time I have to specify how every single tag should be serviced I can't group them in any way because there is implicit assumption that floats may be there in every path (and since Dec does not work I have to stick to F32-64)
hey sorry to hear you're having a frustrating experience, sounds like we have a cluster of bugs you ran into
to improve things we need to know where the problems are specifically, so we know what to fix - do you think you could find ways to reproduce some of these crashes and bugs?
on recent build Num.floor , Num.round are crashing Str.toDec crashing at least for me
dbg crashes often but in order to report problem I need to submit quite a decent chunk of code. I will consider doing so anyway. For problem I mentioned simple things like lines " r = Num.floor 1.1f32" , " Str.toDec "50" " are crashing. Those seems like rudimentary operations and for them not working is disappointing. Crashing dbg I can swallow, but I don't know how to go around crashing Num.floor or Num.round . Btw I am beginner in FP so experiencing additional hurdles all the time does not help
This is quite informative. I guess no one has really done anything significant with floating point or decimal types yet.
dbg is less surprising to me. It tends to crash in a lot of situations and is a more complex picture.
I'll try to look into filling out our test suite and figuring out what is missing for floats.
actually my goal was to accomplish some basic functionality, so when I meet some kind of problem usually I am focused more on trying bypass it but maybe I should focus more on reporting I will see next week
floats are important since roc premise is to be relatively performant it is natural that it will be used to perform some computations at least I plan to use it this way
Yes, submitting issue whenever you find a bug is very helpful :grinning:
I haven't managed to repro the Num.floor
issue, but I think I figured out the Str.toDec
issue. Actually turned out not to be an issue with Str.toDec
, but with Num.toStr
on the dec to print it out. Will push a fix shortly.
Last updated: Jul 06 2025 at 12:14 UTC