X-Git-Url: https://git.madduck.net/etc/vim.git/blobdiff_plain/5316bbff0e9db989db98b14761ce2c299a05895b..ea9fefb359b86208ad20c944c3c420e6c3fb2c5e:/src/black/__init__.py?ds=inline diff --git a/src/black/__init__.py b/src/black/__init__.py index 5c9ab75..0a893aa 100644 --- a/src/black/__init__.py +++ b/src/black/__init__.py @@ -5351,15 +5351,10 @@ def normalize_numeric_literal(leaf: Leaf) -> None: def format_hex(text: str) -> str: """ - Formats a hexadecimal string like "0x12b3" - - Uses lowercase because of similarity between "B" and "8", which - can cause security issues. - see: https://github.com/psf/black/issues/1692 + Formats a hexadecimal string like "0x12B3" """ - before, after = text[:2], text[2:] - return f"{before}{after.lower()}" + return f"{before}{after.upper()}" def format_scientific_notation(text: str) -> str: