you are viewing a single comment's thread
view the rest of the comments
[–] 4 points 2 years ago* (last edited 2 years ago) (2 children)

Alright, maybe you misunderstood the term digits with numbers. When parsing a digit, you do not attach semantic yet to the building blocks. A \d regex parser does not care that the string "555" is not equivalent to "VVV". All it cares about is that there is the digit "5" or "V". In the same vein, regex parser should not try to parse IV as a single symbol.

  • source
  • parent
  • hideshow 2 child comments
  • [–] 3 points 2 years ago* (1 child)

    It's not just digits. Nobody is expecting it to understand language yet but the parser is-number still returns true for "2e3" or "0x0F". It tells you whether the string can be interpreted as a real numeric value.

  • source
  • parent
  • hideshow 1 child comment