From 8ed1479619a3487af72a7c44bf61c9711370d4da Mon Sep 17 00:00:00 2001 From: Timothy Poon <62692924+ptim0626@users.noreply.github.com> Date: Sat, 8 Aug 2026 02:42:23 +0100 Subject: [PATCH] gh-155339: Document the change of behaviour about parsing negative numbers from 3.14 in argparse (#155340) Co-authored-by: Savannah Ostrowski --- Doc/library/argparse.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Doc/library/argparse.rst b/Doc/library/argparse.rst index 0eba8ca932be1fe..b2318ddace8514b 100644 --- a/Doc/library/argparse.rst +++ b/Doc/library/argparse.rst @@ -1624,6 +1624,11 @@ argument:: See also :ref:`the argparse howto on ambiguous arguments ` for more details. +.. versionchanged:: 3.14 + Negative-number matching was expanded to include numbers in scientific + notation (``-2.5e-6``), numbers containing underscores (``-1_234.5``), + and complex numbers (``-1.2e-3j``). + .. _prefix-matching: Argument abbreviations (prefix matching)