{"version":3,"file":"_jsonStringifyNumber.mjs","names":[],"sources":["../../src/internal/_jsonStringifyNumber.ts"],"sourcesContent":["/**\n * Prepare a number for JSON, mapping a non-finite number to null as\n * `JSON.stringify` does.\n *\n * @evidence contracts/common.md#principled-implementation JSON has no spelling for NaN or the infinities, and `JSON.stringify` writes them as null, so a non-finite number is mapped to null and a finite one is returned unchanged for the emitted code to concatenate.\n * @evidence contracts/common.md#clear-and-simple-design One expression.\n * @evidence contracts/common.md#prohibited-implementation-shortcuts The mapping follows the platform's own JSON rule and no value is special-cased.\n * @evidence contracts/common.md#meaningful-documentation A comment states the null mapping.\n */\nexport const _jsonStringifyNumber = (value: number): number | null =>\n  isFinite(value) ? value : null;\n"],"mappings":";;;;;;;;;;AASA,MAAa,wBAAwB,UACnC,SAAS,KAAK,IAAI,QAAQ"}