@@ -81,7 +81,7 @@ def record_literal(self, value: LiteralValue) -> None:
8181 self .record_literal (item )
8282 frozenset_literals [value ] = len (frozenset_literals )
8383 elif isinstance (value , dict ):
84- items = self .make_dict_literal_key (value )
84+ items = self .make_dict_literal_key (value ) # type: ignore [arg-type]
8585 dict_literals = self .dict_literals
8686 if items not in dict_literals :
8787 for k , v in items :
@@ -126,13 +126,13 @@ def literal_index(self, value: LiteralValue) -> int:
126126 return n + self .frozenset_literals [value ]
127127 n += len (self .frozenset_literals )
128128 if isinstance (value , dict ):
129- key = self .make_dict_literal_key (value )
129+ key = self .make_dict_literal_key (value ) # type: ignore [arg-type]
130130 return n + self .dict_literals [key ]
131131 assert False , "invalid literal: %r" % value
132132
133133 def make_dict_literal_key (
134134 self , value : dict [LiteralValue , LiteralValue ]
135- ) -> tuple [tuple [LiteralValue , LiteralValue ]]:
135+ ) -> tuple [tuple [LiteralValue , LiteralValue ], ... ]:
136136 """Make a unique key for a literal dict."""
137137 return tuple (value .items ())
138138
@@ -198,8 +198,8 @@ def encoded_dict_values(self) -> list[str]:
198198 items = value_by_index [i ]
199199 result .append (str (len (items )))
200200 for k , v in items :
201- index_k = self .literal_index (k )
202- index_v = self .literal_index (v )
201+ index_k = self .literal_index (k ) # type: ignore [arg-type]
202+ index_v = self .literal_index (v ) # type: ignore [arg-type]
203203 result .append (str (index_k ))
204204 result .append (str (index_v ))
205205 return result
0 commit comments