{
  "version": 3,
  "sources": ["../../../../../src/functions/math/max/max.ts"],
  "sourcesContent": [
    "import {\n  type FunctionDefinition,\n  type FunctionEvaluationResult,\n} from \"../../../core/types.cjs\";\nimport { performMaximum } from \"./max-utils.cjs\";\nimport { createArgumentIterator } from \"../../function-utils.cjs\";\n\n/**\n * MAX function - Returns the largest number in the arguments\n *\n * Usage: MAX(value1, [value2], ...)\n *\n * Examples:\n *   MAX(1, 2, 3) - returns 3\n *   MAX(A1:A10) - finds maximum in the range A1:A10\n *   MAX(A1:A5, B1:B5) - finds maximum across both ranges\n *\n * Note:\n * - Only numeric values are considered\n * - Text, logical values, and empty cells are ignored in ranges\n * - Direct text/logical arguments cause errors\n * - Returns error if no numeric values are found\n */\nexport const MAX: FunctionDefinition = {\n  name: \"MAX\",\n  evaluate: function (node, context): FunctionEvaluationResult {\n    // Create iterator over all argument values\n    const argumentValues = createArgumentIterator(this, node, context, \"col-major\");\n    if (argumentValues.type !== \"values\") {\n      return argumentValues;\n    }\n    // Use shared maximum utility (now with unified error propagation)\n    return performMaximum(argumentValues.values, context);\n  },\n};\n"
  ],
  "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAI+B,IAA/B;AACuC,IAAvC;AAkBO,IAAM,MAA0B;AAAA,EACrC,MAAM;AAAA,EACN,UAAU,QAAS,CAAC,MAAM,SAAmC;AAAA,IAE3D,MAAM,iBAAiB,6CAAuB,MAAM,MAAM,SAAS,WAAW;AAAA,IAC9E,IAAI,eAAe,SAAS,UAAU;AAAA,MACpC,OAAO;AAAA,IACT;AAAA,IAEA,OAAO,gCAAe,eAAe,QAAQ,OAAO;AAAA;AAExD;",
  "debugId": "5466A89F45A347C664756E2164756E21",
  "names": []
}