MCPcopy Create free account
hub / github.com/python/mypy / is_explicit_any

Function is_explicit_any

mypy/suggestions.py:218–225  ·  view source on GitHub ↗
(typ: AnyType)

Source from the content-addressed store, hash-verified

216
217
218def is_explicit_any(typ: AnyType) -> bool:
219 # Originally I wanted to count as explicit anything derived from an explicit any, but that
220 # seemed too strict in some testing.
221 # return (typ.type_of_any == TypeOfAny.explicit
222 # or (typ.source_any is not None and typ.source_any.type_of_any == TypeOfAny.explicit))
223 # Important question: what should we do with source_any stuff? Does that count?
224 # And actually should explicit anys count at all?? Maybe not!
225 return typ.type_of_any == TypeOfAny.explicit
226
227
228def is_implicit_any(typ: Type) -> bool:

Callers 1

is_implicit_anyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…