File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -1199,11 +1199,14 @@ def test_serialization(self):
11991199 System .StringSplitOptions .RemoveEmptyEntries ,
12001200 ]
12011201
1202- if False :
1203- # TODO: Enum types are not picklable if defined in nested namespaces
1204- # https://github.com/IronLanguages/ironpython3/issues/1989
1205- clr .AddReference ("System.Text.Json" )
1206- data .append (System .Text .Json .JsonValueKind .Object ) # byte-based enum
1202+ if is_cli :
1203+ # enum types
1204+ clr .AddReference ("Microsoft.Scripting" )
1205+ import Microsoft .Scripting
1206+ data .append (Microsoft .Scripting .Severity .Warning ) # different namespace than System
1207+ if is_netcoreapp :
1208+ clr .AddReference ("System.Text.Json" )
1209+ data .append (System .Text .Json .JsonValueKind .Object ) # byte-based enum
12071210
12081211 data .append (list (data )) # list of all the data..
12091212 data .append (tuple (data )) # tuple of all the data...
You can’t perform that action at this time.
0 commit comments