From 75b29c92ed5dcf43fe02ff11972ef228a9620b4a Mon Sep 17 00:00:00 2001 From: Sei Lisa Date: Mon, 12 Dec 2022 16:32:14 +0100 Subject: [PATCH] Fix warning about possible future breakage Incoming Unicode regular expressions allow brackets inside brackets, therefore POSIX semantics no longer apply. Python warns about possible future breakage, so add backslash escape to square bracket opening inside the character class. --- unit_tests/expr.suite/llfrand-1.out | 2 +- unit_tests/expr.suite/llfrand-2.out | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/unit_tests/expr.suite/llfrand-1.out b/unit_tests/expr.suite/llfrand-1.out index 77bef8f..9ace17d 100644 --- a/unit_tests/expr.suite/llfrand-1.out +++ b/unit_tests/expr.suite/llfrand-1.out @@ -1,2 +1,2 @@ REGEX -[[,] [0-9]{7}\.[0-9]* \ No newline at end of file +[\[,] [0-9]{7}\.[0-9]* \ No newline at end of file diff --git a/unit_tests/expr.suite/llfrand-2.out b/unit_tests/expr.suite/llfrand-2.out index 66c6f34..3f22864 100644 --- a/unit_tests/expr.suite/llfrand-2.out +++ b/unit_tests/expr.suite/llfrand-2.out @@ -1,2 +1,2 @@ REGEX -[[,] [0-9]{8}\.[0-9]* \ No newline at end of file +[\[,] [0-9]{8}\.[0-9]* \ No newline at end of file