From f6a97d7a2feb8bb14909bc162310ea3e0893cbd3 Mon Sep 17 00:00:00 2001 From: Mangel Maxime Date: Mon, 6 Jul 2026 16:40:41 +0200 Subject: [PATCH] perf(python): use native operators for int64/uint64 arithmetic --- src/Fable.Transforms/Python/Replacements.fs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Fable.Transforms/Python/Replacements.fs b/src/Fable.Transforms/Python/Replacements.fs index 47dc01eef..bedc64231 100644 --- a/src/Fable.Transforms/Python/Replacements.fs +++ b/src/Fable.Transforms/Python/Replacements.fs @@ -497,14 +497,12 @@ let applyOp (com: ICompiler) (ctx: Context) r t opName (args: Expr list) = let argTypes = args |> List.map (fun a -> a.Type) match argTypes with - | Number(Int64 | UInt64 | BigInt | Decimal as kind, _) :: _ -> + | Number(BigInt | Decimal as kind, _) :: _ -> let modName, opName = match kind, opName with - // | UInt64, Operators.rightShift -> "long", "op_RightShiftUnsigned" // See #1482 | Decimal, Operators.divideByInt -> "decimal", Operators.division | Decimal, _ -> "decimal", opName - | BigInt, _ -> "big_int", opName - | _ -> "long", opName + | _ -> "big_int", opName Helper.LibCall(com, modName, opName, t, args, argTypes, ?loc = r)