prevent assignment to set literals
diff --git a/Lib/test/test_syntax.py b/Lib/test/test_syntax.py
index 899db61..4992a32 100644
--- a/Lib/test/test_syntax.py
+++ b/Lib/test/test_syntax.py
@@ -468,6 +468,12 @@
File "<doctest test.test_syntax[50]>", line 1
SyntaxError: can't delete ()
+>>> {1, 2, 3} = 42
+Traceback (most recent call last):
+ ...
+ File "<doctest test.test_syntax[50]>", line 1
+SyntaxError: can't assign to literal
+
"""
import re
diff --git a/Misc/NEWS b/Misc/NEWS
index cb60239..70ce171 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -12,6 +12,8 @@
Core and Builtins
-----------------
+- Prevent assignment to set literals.
+
Library
-------
diff --git a/Python/ast.c b/Python/ast.c
index 41c0d28..f8c83d9 100644
--- a/Python/ast.c
+++ b/Python/ast.c
@@ -440,6 +440,7 @@
expr_name = "dict comprehension";
break;
case Dict_kind:
+ case Set_kind:
case Num_kind:
case Str_kind:
expr_name = "literal";