* [PATCH] tests/tcg/aarch64: Use raw strings for regexes in test-mte.py
@ 2024-10-15 14:08 Gustavo Romero
2024-10-15 14:47 ` Philippe Mathieu-Daudé
2024-10-21 8:28 ` Alex Bennée
0 siblings, 2 replies; 3+ messages in thread
From: Gustavo Romero @ 2024-10-15 14:08 UTC (permalink / raw)
To: qemu-devel, qemu-arm; +Cc: gustavo.romero
Use Python's raw string notation instead of string literals for regex so
it's not necessary to double backslashes when regex special forms are
used. Raw notation is preferred for regex and easier to read.
Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
---
tests/tcg/aarch64/gdbstub/test-mte.py | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/tcg/aarch64/gdbstub/test-mte.py b/tests/tcg/aarch64/gdbstub/test-mte.py
index a4cae6caa0..9ad98e7a54 100644
--- a/tests/tcg/aarch64/gdbstub/test-mte.py
+++ b/tests/tcg/aarch64/gdbstub/test-mte.py
@@ -23,8 +23,8 @@
from test_gdbstub import arg_parser, main, report
-PATTERN_0 = "Memory tags for address 0x[0-9a-f]+ match \\(0x[0-9a-f]+\\)."
-PATTERN_1 = ".*(0x[0-9a-f]+)"
+PATTERN_0 = r"Memory tags for address 0x[0-9a-f]+ match \(0x[0-9a-f]+\)."
+PATTERN_1 = r".*(0x[0-9a-f]+)"
def run_test():
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] tests/tcg/aarch64: Use raw strings for regexes in test-mte.py
2024-10-15 14:08 [PATCH] tests/tcg/aarch64: Use raw strings for regexes in test-mte.py Gustavo Romero
@ 2024-10-15 14:47 ` Philippe Mathieu-Daudé
2024-10-21 8:28 ` Alex Bennée
1 sibling, 0 replies; 3+ messages in thread
From: Philippe Mathieu-Daudé @ 2024-10-15 14:47 UTC (permalink / raw)
To: Gustavo Romero, qemu-devel, qemu-arm
On 15/10/24 11:08, Gustavo Romero wrote:
> Use Python's raw string notation instead of string literals for regex so
> it's not necessary to double backslashes when regex special forms are
> used. Raw notation is preferred for regex and easier to read.
>
> Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
> ---
> tests/tcg/aarch64/gdbstub/test-mte.py | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] tests/tcg/aarch64: Use raw strings for regexes in test-mte.py
2024-10-15 14:08 [PATCH] tests/tcg/aarch64: Use raw strings for regexes in test-mte.py Gustavo Romero
2024-10-15 14:47 ` Philippe Mathieu-Daudé
@ 2024-10-21 8:28 ` Alex Bennée
1 sibling, 0 replies; 3+ messages in thread
From: Alex Bennée @ 2024-10-21 8:28 UTC (permalink / raw)
To: Gustavo Romero; +Cc: qemu-devel, qemu-arm
Gustavo Romero <gustavo.romero@linaro.org> writes:
> Use Python's raw string notation instead of string literals for regex so
> it's not necessary to double backslashes when regex special forms are
> used. Raw notation is preferred for regex and easier to read.
>
> Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
Queued to gdbstub/next, thanks.
--
Alex Bennée
Virtualisation Tech Lead @ Linaro
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-10-21 8:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-15 14:08 [PATCH] tests/tcg/aarch64: Use raw strings for regexes in test-mte.py Gustavo Romero
2024-10-15 14:47 ` Philippe Mathieu-Daudé
2024-10-21 8:28 ` Alex Bennée
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).