diff --git a/python/common/org/python/types/Bool.java b/python/common/org/python/types/Bool.java index 1b3f801fed..18935c7d95 100644 --- a/python/common/org/python/types/Bool.java +++ b/python/common/org/python/types/Bool.java @@ -94,6 +94,16 @@ public org.python.types.Str __getitem__(org.python.Object format_string) { throw new org.python.exceptions.TypeError("'bool' object is not subscriptable"); } + @org.python.Method( + __doc__ = "", + args = {"index", "value"} + ) + public void __setitem__(org.python.Object index, org.python.Object value) { + throw new org.python.exceptions.TypeError( + "'bool' object does not support item assignment" + ); + } + @org.python.Method( __doc__ = "Return self