bpo-33502: dataclass._Dataclassparams repr: use repr of each member. (GH-6812)
(cherry picked from commit 3059042410dce69806b94be72d5c8055d616f3a3)
Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
diff --git a/j.py b/j.py
new file mode 100644
index 0000000..9551702
--- /dev/null
+++ b/j.py
@@ -0,0 +1,15 @@
+
+class X:
+ def __init__(self, value):
+ self.value = value
+ def __str__(self):
+ return str(self.value)
+ def __format__(self, fmt):
+ assert fmt[0] == '='
+ self.value = eval(fmt[1:])
+ return ''
+
+x = X(3)
+print(x)
+f'{x:=4}' # Behold!
+print(x)