LastCalc icon indicating copy to clipboard operation
LastCalc copied to clipboard

Handle commas in numbers

Open sanity opened this issue 13 years ago • 0 comments

LastCalc currently outputs numbers with commas, like 35,523,433 - however it cannot parse numbers with commas.

The issue is lists, is [123,456] a list with two numbers, 123 and 456, or the number 123456?

It's hard to think of a robust solution. eg. we could look out specifically for up to 3 digits, followed by one or more sets of 3 digits all separated by a comma, with no space. This may be sufficient, but could lead to misunderstandings in some circumstances.

In any case, this should occur in the Tokenizer, and also in the javascript so that numbers can be highlighted as the user types.

sanity avatar May 04 '12 03:05 sanity