Visitor for querying whether a type has an UninhabitedType component.
| 6716 | |
| 6717 | |
| 6718 | class HasUninhabitedComponentsQuery(types.BoolTypeQuery): |
| 6719 | """Visitor for querying whether a type has an UninhabitedType component.""" |
| 6720 | |
| 6721 | def __init__(self) -> None: |
| 6722 | super().__init__(types.ANY_STRATEGY) |
| 6723 | |
| 6724 | def visit_uninhabited_type(self, t: UninhabitedType) -> bool: |
| 6725 | return True |
| 6726 | |
| 6727 | |
| 6728 | def has_ambiguous_uninhabited_component(t: Type) -> bool: |
no outgoing calls
no test coverage detected
searching dependent graphs…