JSON integers: limit on size

前端 未结 3 1900
渐次进展
渐次进展 2020-11-27 16:02

Is it specified anywhere how big JSON integers can be? I\'m guessing that they\'re limited to normal (32 bit) ints, but I can\'t find anywhere that that\'s written down. I n

3条回答
  •  北海茫月
    2020-11-27 16:38

    A JSON number is not limited by the spec.

    JSON number grammar

    Since JSON is an abstract format that is not exclusively targeted at JavaScript, the actual target environment determines the boundaries of what can be interpreted.

    It's also worth noting that there are no "JSON Integers", they are a sub-set of the "Number" datatype.

提交回复
热议问题