diff options
| author | Christian Clauss <cclauss@me.com> | 2023-03-10 06:28:44 +0100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-05-02 11:55:02 +1000 |
| commit | 8f8bd981641e0988b9ed3276c8f2435645269b3f (patch) | |
| tree | 05bd92798fcf6ea91f02811b4a38f2f4f8737932 /tools/insert-usb-ids.py | |
| parent | cda292935dca9df25019168d91b211ad68e2b054 (diff) | |
all: Fix strings with backslash by using raw string literals.
Diffstat (limited to 'tools/insert-usb-ids.py')
| -rw-r--r-- | tools/insert-usb-ids.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/insert-usb-ids.py b/tools/insert-usb-ids.py index 9b53f3f68..177a68c4a 100644 --- a/tools/insert-usb-ids.py +++ b/tools/insert-usb-ids.py @@ -16,7 +16,7 @@ def parse_usb_ids(filename): rv = dict() for line in open(filename).readlines(): line = line.rstrip("\r\n") - match = re.match("^#define\s+(\w+)\s+\(0x([0-9A-Fa-f]+)\)$", line) + match = re.match(r"^#define\s+(\w+)\s+\(0x([0-9A-Fa-f]+)\)$", line) if match and match.group(1).startswith(config_prefix): key = match.group(1).replace(config_prefix, "USB_") val = match.group(2) |
