News for hackers. Stuff that matters.
Re:Show HN: Numscript, a declarative language to model finan... by holloway on Friday September 20, 2024 @02:29AM (#41599362)
Large sends seem to crash the playground with a JSON parse error. eg change the first example 'Simple send' to send `10000000000000000000` (`send [USD/2 10000000000000000000]`) and there's a crash
Re:Show HN: Numscript, a declarative language to model finan... by superzamp on Friday September 20, 2024 @03:30AM (#41599674)
Thanks for the heads up! While the Numscript backend itself uses big.Int, we're still using normal javascript numbers in the playground for now so that's where it's coming from. But we should definitely switch to BigInt in the playground code though and that would solve the issue.
Re:Show HN: Numscript, a declarative language to model finan... by hum3hum3 on Friday September 20, 2024 @03:49AM (#41599753)
You should never use floats for money. In python Decimal works well. TigerBeatle uses 128 bit accounts and amounts which I thought was interesting although more than needed gor many cases.