Switch all Small Basic numerics to a decimal64-based 'Number' type #137
Labels
pri/3
Priority 3 - Something that can be done in SBO 1.1 or later
type/runtime
Issues related to runtime engine
This issue stems from a Yammer discussion.
Small Basic should switch to using the IEEE
decimal64
format to represent its numbers. This would:decimal
to represent decimal fractions (as opposed tofloat
anddouble
's binary fractions)decimal
type, which has been a source of complaints in the pastdecimal
) to between 10−383 and 10+384 with 16-digit precision. Most learners would probably value added range over being able to represent the weight of an electron in grams (which, FWIW, is 9.11×10−28).decimal32
instead, which retains all the same semantics with more limited range and precision. If thedecimal64
implementation were limited to the range ofdecimal32
, the switch would only incur a reduction in precision, easing understanding.The text was updated successfully, but these errors were encountered: