ruff
b8a65182 - [red-knot] Symbol API improvements, part 2 (#14276)

Commit
1 year ago
[red-knot] Symbol API improvements, part 2 (#14276) ## Summary Apart from one small functional change, this is mostly a refactoring of the `Symbol` API: - Rename `as_type` to the more explicit `ignore_possibly_unbound`, no functional change - Remove `unwrap_or_unknown` in favor of the more explicit `.ignore_possibly_unbound().unwrap_or(Type::Unknown)`, no functional change - Consistently call it "possibly unbound" (not "may be unbound") - Rename `replace_unbound_with` to `or_fall_back_to` and properly handle boundness of the fall back. This is the only functional change (did not have any impact on existing tests). relates to: #14022 ## Test Plan New unit tests for `Symbol::or_fall_back_to` --------- Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Author
Parents
Loading