From 0917b02a31cc5ebb87b646a2ce04e200b0c18328 Mon Sep 17 00:00:00 2001 From: Jan Petykiewicz Date: Sun, 19 Mar 2023 10:17:30 -0700 Subject: [PATCH] str(namedpattern) should just return its name --- masque/pattern.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/masque/pattern.py b/masque/pattern.py index ecd9787..9e136e1 100644 --- a/masque/pattern.py +++ b/masque/pattern.py @@ -734,6 +734,9 @@ class NamedPattern(Pattern): s += ']>' return s + def __str__(self) -> str: + return self.name + def __copy__(self) -> Pattern: return Pattern.__copy__(self)