mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-29 13:24:57 +00:00
[ty] Remove TODO about using a non-panicking lookup method
Ref https://github.com/astral-sh/ruff/pull/20439#discussion_r2355082049 Ref https://github.com/astral-sh/ruff/pull/18455#discussion_r2126833137
This commit is contained in:
parent
64a4e2889e
commit
3fcbe8bde6
1 changed files with 0 additions and 4 deletions
|
@ -267,10 +267,6 @@ impl<'db> SemanticModel<'db> {
|
||||||
fn scope(&self, node: ast::AnyNodeRef<'_>) -> Option<FileScopeId> {
|
fn scope(&self, node: ast::AnyNodeRef<'_>) -> Option<FileScopeId> {
|
||||||
let index = semantic_index(self.db, self.file);
|
let index = semantic_index(self.db, self.file);
|
||||||
|
|
||||||
// TODO: We currently use `try_expression_scope_id` here as a hotfix for [1].
|
|
||||||
// Revert this to use `expression_scope_id` once a proper fix is in place.
|
|
||||||
//
|
|
||||||
// [1] https://github.com/astral-sh/ty/issues/572
|
|
||||||
match node {
|
match node {
|
||||||
ast::AnyNodeRef::Identifier(identifier) => index.try_expression_scope_id(identifier),
|
ast::AnyNodeRef::Identifier(identifier) => index.try_expression_scope_id(identifier),
|
||||||
node => match node.as_expr_ref() {
|
node => match node.as_expr_ref() {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue