Skip to content

Commit 05b3188

Browse files
committed
Use .group(0) instead of [0] for regex matches
The latter was added in Python version 3.6. Close #323
1 parent b96e429 commit 05b3188

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.gdbinit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ def fetch_breakpoints(watchpoints=False, pending=False):
346346
parsed_breakpoints[number] = [address_info], is_pending, ''
347347
elif len(fields) >= 5 and fields[1] == 'catchpoint':
348348
# only take before comma, but ignore commas in quotes
349-
what = catch_what_regex.search(' '.join(fields[4:]))[0].strip()
349+
what = catch_what_regex.search(' '.join(fields[4:])).group(0).strip()
350350
parsed_breakpoints[number] = [], False, what
351351
elif len(fields) >= 3 and number in parsed_breakpoints:
352352
# add this address to the list of multiple locations

0 commit comments

Comments
 (0)