MCPcopy Create free account
hub / github.com/astral-sh/ruff / target_scope

Method target_scope

crates/ty_python_core/src/unpack.rs:74–77  ·  view source on GitHub ↗

Returns the scope where the unpack target expression belongs to.

(self, db: &'db dyn Db)

Source from the content-addressed store, hash-verified

72
73 /// Returns the scope where the unpack target expression belongs to.
74 pub fn target_scope(self, db: &'db dyn Db) -> ScopeId<'db> {
75 self.target_file_scope(db)
76 .to_scope_id(db, self.program_file(db))
77 }
78
79 pub fn program(self, db: &'db dyn Db) -> Program<'db> {
80 self.target_scope(db).program(db)

Callers 2

programMethod · 0.80
infer_unpack_typesFunction · 0.80

Calls 2

to_scope_idMethod · 0.80
program_fileMethod · 0.45

Tested by

no test coverage detected