1 of 5

Numeric Separators

Looking to advance to Stage 2

2 of 5

Agenda

  • Recap from last meeting
  • Discuss open issue
  • Stage 2

3 of 5

Recap from last meeting

  • TL;DR; Underscores between digits in numeric literals, e.g. ��Thousands separator 1_000_000_000�Byte separator 0xA0_B0_C0, 0b1010_0001_1000_0101�
  • Spec draft at http://tc39.github.io/proposal-numeric-separator
  • Only one remaining open feedback, looking for a recommendation
  • At Stage 1, looking to advance to Stage 2

4 of 5

Will this change user’s behavior?

  • As we introduce separators to the language for programmers, do we expect user input to change too?
  • Concern is that users are going to expect _ to be allowed in form fields, etc
  • parseFloat() and parseInt() left unchanged deliberately
  • Two paths
    • Introduce and couple a new method, Number.parse() to fill the gaps of parseFloat/parseInt
    • De-couple, get numeric separators to stage 2, and look at these problems independently
  • Strawman proposal
    • De-couple, enable polyfills to fill the gap and converge (and standardize when/if they do).

5 of 5

Stage 2? Reviewers?