MCPcopy Create free account

hub / github.com/astral-sh/ruff / functions

Functions27,349 in github.com/astral-sh/ruff

↓ 43 callersMethodproject
(&self)
crates/ty_project/src/db.rs:593
↓ 43 callersMethodwith_annotated_type
Set the annotated type for this parameter. This also marks the annotation as explicit (not inferred), so it will be displayed.
crates/ty_python_semantic/src/types/signatures.rs:4078
↓ 42 callersMethodadd_positive
(self, ty: Type<'db>)
crates/ty_python_semantic/src/types/set_theoretic/builder.rs:1230
↓ 42 callersMethodf
(self)
crates/ruff_linter/resources/test/fixtures/pyupgrade/UP008.py:121
↓ 42 callersMethodfield
Returns the field declared directly on this dynamic named tuple, if any.
crates/ty_python_semantic/src/types/class/named_tuple.rs:470
↓ 42 callersMethodget_mut
(&mut self, index: I)
crates/ruff_index/src/slice.rs:116
↓ 42 callersMethodis_never
(&self)
crates/ty_python_semantic/src/types/constraints.rs:1333
↓ 42 callersMethodliteral
(self)
crates/ruff_python_ast/src/generated.rs:2983
↓ 42 callersMethodmodule
(&self)
crates/ty_python_semantic/src/types/infer/builder.rs:636
↓ 42 callersMethodname
(self)
crates/ruff_linter/src/rules/flake8_tidy_imports/settings.rs:177
↓ 42 callersMethodpath
(&self)
crates/ruff/src/commands/format.rs:862
↓ 42 callersMethodplace_table
(&self, scope_id: FileScopeId)
crates/ty_python_core/src/lib.rs:363
↓ 42 callersMethodproject_path
(&self, relative: impl AsRef<SystemPath>)
crates/ty/tests/file_watching.rs:38
↓ 41 callersMethodapply_changes
( &mut self, changes: &[ChangeEvent], project_options_overrides: Option<&ProjectOption
crates/ty/tests/file_watching.rs:182
↓ 41 callersFunctionbind_docstring_snapshot_filters
()
crates/ty_ide/src/docstring.rs:342
↓ 41 callersFunctionempty
()
crates/ty_python_semantic/src/types/signatures.rs:4597
↓ 41 callersMethodexpect_single_definition
( &self, definition_key: impl Into<DefinitionNodeKey> + std::fmt::Debug + Copy, )
crates/ty_python_core/src/lib.rs:622
↓ 41 callersMethodextend
(&mut self, iter: T)
crates/ruff_linter/src/registry/rule_set.rs:327
↓ 41 callersMethodis_empty
Returns true if and only if this collection is empty.
crates/ty_ide/src/symbols.rs:135
↓ 41 callersMethodis_empty
(&self)
crates/ty_ide/src/docstring/markdown/structured.rs:142
↓ 41 callersMethoditer_mro
Returns an iterator over the MRO.
crates/ty_python_semantic/src/types/class.rs:524
↓ 41 callersMethodsplit_at
Returns a pair of token slices from both before and after the given [`TextSize`] offset. If the given offset is between two tokens, the "before" slic
crates/ruff_python_ast/src/token/tokens.rs:204
↓ 41 callersMethodwith_src_files
Specify files to be created in the `src` mock directory
crates/ty_module_resolver/src/testing.rs:117
↓ 40 callersFunctioncreate_dir_all
( paths: &mut RwLockWriteGuard<BTreeMap<Utf8PathBuf, Entry>>, normalized: &Utf8Path, )
crates/ruff_db/src/system/memory_fs.rs:479
↓ 40 callersMethodeat
Consume the current token if it is of the given kind. Returns `true` if it matches, `false` otherwise.
crates/ruff_python_parser/src/parser/mod.rs:571
↓ 40 callersMethoditer
Returns an iterator over all enabled lints and their severity.
crates/ty_python_semantic/src/lint.rs:587
↓ 40 callersMethodmax
(self, other: Self)
crates/ty_python_semantic/src/place.rs:44
↓ 40 callersMethodto_class_literal
Look up a [`KnownClass`] in its canonical module and return a [`Type`] representing that class literal. If the class cannot be found, a debug-level l
crates/ty_python_semantic/src/types/class/known.rs:1198
↓ 40 callersMethodwith_initialization_options
Set the initial client options for the test server
crates/ty_server/tests/e2e/main.rs:1228
↓ 39 callersMethodadd
Add a file with the given path and contents to this environment.
crates/ruff_db/src/diagnostic/render.rs:2653
↓ 39 callersMethodbuild
(self)
crates/ty_python_semantic/src/types/set_theoretic/builder.rs:1120
↓ 39 callersMethoditer
(&mut self)
crates/ruff_linter/src/checkers/ast/mod.rs:3557
↓ 39 callersMethodnext
(&mut self)
crates/ty_python_semantic/src/types/infer/builder.rs:10866
↓ 39 callersMethodor
Returns the union of this constraint set and another. The other constraint set is provided as a thunk, to implement short-circuiting: the thunk is not
crates/ty_python_semantic/src/types/constraints.rs:526
↓ 39 callersMethodpath
(&self)
crates/ty_wasm/src/lib.rs:853
↓ 38 callersMethodannotated_type
Annotated type of the parameter. If no annotation was provided, this is `Unknown`.
crates/ty_python_semantic/src/types/signatures.rs:4329
↓ 38 callersMethodbuild
Return the built diagnostic.
crates/ruff_db/src/diagnostic/render.rs:2780
↓ 38 callersMethodbuild
(&self)
crates/ty_ide/src/symbols.rs:2972
↓ 38 callersMethodcontains
(&self, kind: TokenKind)
crates/ruff_python_parser/src/token_set.rs:28
↓ 38 callersFunctionevent_for_file
(name: &str)
crates/ty/tests/file_watching.rs:262
↓ 38 callersMethodexists
Returns `true` if the file exists.
crates/ruff_db/src/files.rs:539
↓ 38 callersFunctionformat_with
Creates an object implementing `Format` that calls the passed closure to perform the formatting. # Examples ``` use ruff_formatter::prelude::*; use
crates/ruff_formatter/src/builders.rs:2317
↓ 38 callersFunctionlex_inline_noqa
Lexes in-line `noqa` comment, e.g. `# noqa: F401`
crates/ruff_linter/src/noqa.rs:333
↓ 38 callersMethodlines
(&self)
crates/ruff_linter/src/noqa.rs:316
↓ 38 callersMethodnext
(&mut self)
crates/ruff_python_ast/src/nodes.rs:244
↓ 38 callersMethodopen
(self)
crates/ruff_linter/resources/test/fixtures/flake8_async/ASYNC230.py:66
↓ 38 callersMethodsource
( &mut self, path: impl Into<SystemPathBuf>, contents: impl AsRef<str>,
crates/ty_ide/src/symbols.rs:3006
↓ 38 callersMethodstop_watch
(&mut self, matcher: M)
crates/ty/tests/file_watching.rs:59
↓ 38 callersMethodsub
(mut self, sub: SubDiagnostic)
crates/ty_project/src/metadata/options.rs:2173
↓ 38 callersMethodsuite
Returns the module body contained in this parsed output as a [`Suite`].
crates/ruff_python_parser/src/lib.rs:528
↓ 38 callersMethodvisit_source_order
(&'a self, visitor: &mut V)
crates/ruff_python_ast/src/node.rs:9
↓ 37 callersMethodand
Returns the intersection of this constraint set and another. The other constraint set is provided as a thunk, to implement short-circuiting: the thunk
crates/ty_python_semantic/src/types/constraints.rs:505
↓ 37 callersMethodat
Returns `true` if the current token is of the given kind.
crates/ruff_python_parser/src/parser/mod.rs:631
↓ 37 callersMethodcurrent_statement
Return the current [`Stmt`].
crates/ruff_python_semantic/src/model.rs:1474
↓ 37 callersMethodget
Get the cached results for a single file at relative `path`. This uses `key` to determine if the results are still accurate. (i.e. if the file hasn't
crates/ruff/src/cache.rs:260
↓ 37 callersMethodinto_iter
(self)
crates/ruff_linter/src/rules/pycodestyle/rules/logical_lines/mod.rs:92
↓ 37 callersMethodis_subtype_of
Return true if this type is a subtype of type `target`. See [`TypeRelation::Subtyping`] for more details.
crates/ty_python_semantic/src/types/relation.rs:311
↓ 37 callersMethoditer
(self)
crates/ty_python_semantic/src/types/class/typed_dict.rs:99
↓ 37 callersMethodrange
(&self)
crates/ruff_linter/src/rules/refurb/rules/repeated_append.rs:157
↓ 37 callersMethodsaturating_add
(self, rhs: TextSize)
crates/ruff_text_size/src/size.rs:113
↓ 37 callersMethodset
Overwrite the error context tree with a new root context and child nodes.
crates/ty_python_semantic/src/types/relation_error.rs:509
↓ 37 callersMethoduse_def_map
(&self, scope_id: FileScopeId)
crates/ty_python_core/src/lib.rs:380
↓ 36 callersMethodcheck
(&self, contents: &str)
crates/ruff_wasm/src/lib.rs:342
↓ 36 callersMethodclass
Return the [`KnownClass`] that inhabitants of this type are instances of at runtime
crates/ty_python_semantic/src/types/method.rs:264
↓ 36 callersMethoderr
A convenience function for returning a builder for a diagnostic with "error" severity and canned values for its identifier and message.
crates/ruff_db/src/diagnostic/render.rs:2708
↓ 36 callersMethodfile_uri
(&self, path: impl AsRef<SystemPath>)
crates/ty_server/tests/e2e/main.rs:784
↓ 36 callersMethodis_ok
(&self)
crates/ruff_python_parser/tests/generate_inline_tests.rs:205
↓ 36 callersMethodorigin
(&self)
crates/ty_python_semantic/src/types.rs:8036
↓ 36 callersMethodsymbol
(&self, id: ScopedSymbolId)
crates/ty_python_core/src/place.rs:221
↓ 36 callersFunctiontype
(*args)
crates/ruff_linter/resources/test/fixtures/refurb/FURB168.py:84
↓ 35 callersMethodadd
(self, delta: u32)
crates/ty_python_semantic/src/types/typevar.rs:709
↓ 35 callersMethodas_ref
(&self)
crates/ty_site_packages/src/lib.rs:445
↓ 35 callersMethodcreate_directory_all
(&self, path: &SystemPath)
crates/ty_test/src/db.rs:138
↓ 35 callersMethodhelp
Adds a "help" sub-diagnostic with the given message. See the closely related [`Diagnostic::info`] method for more details.
crates/ruff_db/src/diagnostic/mod.rs:175
↓ 35 callersMethodis_class
(self)
crates/ty_python_core/src/scope.rs:252
↓ 35 callersMethodis_paramspec
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/typevar.rs:220
↓ 35 callersFunctionlex_file_exemption
Lexes file-level exemption comment, e.g. `# ruff: noqa: F401`
crates/ruff_linter/src/noqa.rs:366
↓ 35 callersMethodmap
(self, f: &F)
crates/ty_python_semantic/src/types/call/bind.rs:312
↓ 35 callersMethodor_default
(&self)
crates/ty_project/src/metadata/options.rs:2243
↓ 35 callersMethodparent
(&self)
crates/ty_python_core/src/scope.rs:137
↓ 35 callersMethodpush
Extends `self` with `path`. If `path` is absolute, it replaces the current path. On Windows: if `path` has a root but no prefix (e.g., `\windows`),
crates/ruff_db/src/system/path.rs:566
↓ 35 callersMethodrange
(&self)
crates/ruff_linter/src/rules/flake8_simplify/rules/collapsible_if.rs:188
↓ 35 callersMethodto
(self, unit: str)
crates/ruff_benchmark/resources/pydantic/types.py:740
↓ 34 callersMethodcurrent_token_kind
(&self)
crates/ruff_python_parser/src/parser/mod.rs:368
↓ 34 callersMethodignore_possibly_undefined
Returns the inner type, unless it is definitely undefined.
crates/ty_python_semantic/src/types/member.rs:41
↓ 34 callersFunctionimport
PT013
crates/ruff_linter/src/rules/flake8_pytest_style/rules/imports.rs:41
↓ 34 callersMethoditems
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/typed_dict.rs:479
↓ 34 callersMethodknown
Returns the known class, if any.
crates/ty_python_semantic/src/types/class.rs:513
↓ 34 callersMethodspecialization
Project this inference result into a closed specialization.
crates/ty_python_semantic/src/types/generics.rs:2000
↓ 34 callersMethodwrite_files
(&self, files: impl IntoIterator<Item = (SystemPathBuf, &'a str)>)
crates/ty_project/src/db/ignore.rs:247
↓ 33 callersMethodas_str
(self)
crates/ruff_python_ast/src/str.rs:28
↓ 33 callersMethodcontains_range
(self, other: TextRange)
crates/ruff_text_size/src/range.rs:204
↓ 33 callersMethodfile
(self, db: &dyn Db)
crates/ty_python_semantic/src/types/class/static_literal.rs:394
↓ 33 callersMethodinto_boxed_slice
(self)
crates/ty_python_core/src/definition.rs:281
↓ 33 callersMethodinto_boxed_slice
(self)
crates/ty_python_semantic/src/types/infer/builder.rs:11019
↓ 33 callersMethodis_always_satisfied
Returns whether this constraint set always holds
crates/ty_python_semantic/src/types/constraints.rs:421
↓ 33 callersMethodis_undefined
Returns `true` if the inner place is undefined (i.e. there is no such member).
crates/ty_python_semantic/src/types/member.rs:36
↓ 33 callersMethoditer
(&self)
crates/ty_python_semantic/src/types/call/arguments.rs:101
↓ 33 callersMethoditer_non_variadic_params
Returns an iterator over all non-variadic parameters included in this [`Parameters`] node. The variadic parameters (`.vararg` and `.kwarg`) can never
crates/ruff_python_ast/src/nodes.rs:3132
↓ 33 callersMethodsecondary
Create a secondary annotation attached to the range of the given value in the file currently being type checked. The annotation returned has no messa
crates/ty_python_semantic/src/types/context.rs:96
← previousnext →301–400 of 27,349, ranked by callers