MCPcopy Create free account

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

Functions31,766 in github.com/astral-sh/ruff

↓ 34 callersMethodget
(&self, index: I)
crates/ruff_index/src/slice.rs:111
↓ 34 callersMethodinto_iter
(self)
crates/ty_python_core/src/frozen.rs:121
↓ 34 callersMethodis_always_false
(self)
crates/ty_python_core/src/lib.rs:1001
↓ 34 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:3340
↓ 34 callersFunctionparse_expression
Parses a single Python expression. This convenience function can be used to parse a single expression without having to specify the Mode or the locat
crates/ruff_python_parser/src/lib.rs:135
↓ 34 callersMethodplace
(&self)
crates/ty_python_semantic/src/types/infer/builder.rs:245
↓ 34 callersMethodprogram
(self, db: &dyn Db)
crates/ty_project/src/lib.rs:279
↓ 34 callersMethodpython_version
(&self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/context.rs:106
↓ 34 callersMethodrange
(&self)
crates/ruff_linter/src/rules/flake8_simplify/rules/collapsible_if.rs:189
↓ 34 callersMethodresolve_name
Resolves the [`ast::ExprName`] to the [`BindingId`] of the symbol it refers to, if any.
crates/ruff_python_semantic/src/model.rs:1156
↓ 34 callersFunctionsingle
(other: Annotated[str, Depends(something_else)])
crates/ruff_linter/resources/test/fixtures/fastapi/FAST003.py:159
↓ 34 callersMethodsystem
(&self)
crates/ty_module_resolver/src/db.rs:105
↓ 34 callersMethodvalues
(&self)
crates/ty_python_core/src/frozen.rs:57
↓ 33 callersMethodas_ref
(&self)
crates/ruff_db/src/system/path.rs:655
↓ 33 callersMethodborrow
(&self)
crates/ruff_index/src/vec.rs:111
↓ 33 callersMethodcurrent_token_kind
(&self)
crates/ruff_python_parser/src/parser/mod.rs:391
↓ 33 callersMethodindexer
The [`Indexer`] for the current file, which contains the offsets of all comments and more.
crates/ruff_linter/src/checkers/ast/mod.rs:538
↓ 33 callersMethodinsert
(&mut self, file: File, is_script: bool)
crates/ty_project/src/files.rs:247
↓ 33 callersMethodinto_iter
(self)
crates/ty_python_semantic/src/types/infer/builder.rs:13565
↓ 33 callersFunctionmap_subscript
Given an [`Expr`] that can be a [`ExprSubscript`][ast::ExprSubscript] or not (like an annotation that may be generic or not), return the underlying ex
crates/ruff_python_ast/src/helpers.rs:902
↓ 33 callersMethodnominal_class
If this type is a class instance, returns its class.
crates/ty_python_semantic/src/types.rs:2899
↓ 33 callersMethodto_instance_approximation
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, )
crates/ty_python_semantic/src/types.rs:9070
↓ 32 callersMethodcount
(&self)
crates/ruff_linter/src/rules/pycodestyle/rules/blank_lines.rs:579
↓ 32 callersMethodcurrent_dir
Sets the working directory for the command.
crates/ruff_db/src/system/command.rs:43
↓ 32 callersMethodget
(&self, index: usize)
crates/ty_python_semantic/src/types/call/arguments.rs:717
↓ 32 callersMethodis_traverse
(self)
crates/ruff_python_ast/src/visitor/source_order.rs:243
↓ 32 callersMethoditer
Iterates over the scripts without duplicates.
crates/ty_project/src/lib.rs:894
↓ 32 callersMethodkind
(self)
crates/ty_python_semantic/src/types/infer/type_context.rs:95
↓ 32 callersMethodline_ending
(&self)
crates/ruff_source_file/src/newlines.rs:241
↓ 32 callersFunctionline_index
(db: &dyn Db, file: File)
crates/ruff_db/src/source.rs:222
↓ 32 callersMethodmembers
( self, db: &'db dyn Db, )
crates/ty_python_semantic/src/types/protocol_class.rs:486
↓ 32 callersMethodpeek
Returns the next line without advancing the cursor.
crates/ty_ide/src/docstring/document/rst.rs:87
↓ 32 callersMethodprogram_environment
(&self)
crates/ty_python_semantic/src/types/constraints/sequents.rs:2163
↓ 32 callersMethodpush
(&mut self, segment: &'a str)
crates/ruff_python_ast/src/name.rs:487
↓ 32 callersMethodroot_path
(&self)
crates/ty/tests/file_watching.rs:62
↓ 32 callersMethodsubclass_of
Return the inner [`SubclassOfInner`] value wrapped by this `SubclassOfType`.
crates/ty_python_semantic/src/types/subclass_of.rs:152
↓ 31 callersMethodas_function_literal
(self)
crates/ty_python_semantic/src/types.rs:3297
↓ 31 callersMethodas_str
Returns the python code as a `str`.
crates/ruff_db/src/source.rs:91
↓ 31 callersMethodbinding_context
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/typevar.rs:1084
↓ 31 callersFunctionbinding_type
Infer the type of a binding.
crates/ty_python_semantic/src/types.rs:285
↓ 31 callersMethodcontains_line_break
(&self, range: TextRange)
crates/ruff_linter/src/locator.rs:177
↓ 31 callersMethodcurrent_scope
(&self)
crates/ty_python_core/src/builder.rs:394
↓ 31 callersMethodfile_name
(&self)
crates/ty_project/src/watch.rs:102
↓ 31 callersMethodfiles
Returns the files belonging to this project.
crates/ty_project/src/lib.rs:804
↓ 31 callersMethodget
Looks up a lint by its name.
crates/ty_python_semantic/src/lint.rs:425
↓ 31 callersMethodis_never_satisfied
Returns whether this constraint set never holds, without checking the type variables' declared bounds or constraints. Use [`Self::has_no_valid_solutio
crates/ty_python_semantic/src/types/constraints.rs:533
↓ 31 callersMethodis_same_typevar_as
Returns whether two bound typevars represent the same occurrence, regardless of e.g. differences in their bounds or constraints due to materialization
crates/ty_python_semantic/src/types/typevar.rs:1276
↓ 31 callersMethodkind
(&self)
crates/ruff_python_ast/src/token.rs:43
↓ 31 callersMethodonly_binding
Resolves the [`ast::ExprName`] to the [`BindingId`] of the symbol it refers to, if it's the only binding to that name in its scope.
crates/ruff_python_semantic/src/model.rs:1162
↓ 31 callersFunctionprogram_file
(db: &TestDb, file: File)
crates/ty_python_core/src/lib.rs:1234
↓ 31 callersMethodresolve_builtin_symbol
If `expr` is a reference to a builtins symbol, return the name of that symbol. Else, return `None`. This method returns `true` both for "builtin bind
crates/ruff_python_semantic/src/model.rs:404
↓ 31 callersFunctiontest_case
(content: &str)
crates/ty_python_core/src/lib.rs:1221
↓ 31 callersMethoduniversal_newlines
(&self)
crates/ruff_source_file/src/newlines.rs:13
↓ 31 callersFunctionunknown_rule_selector_test
()
crates/ruff/tests/cli/lint.rs:919
↓ 30 callersMethodancestors
Returns an iterator of this module name and all of its parent modules. # Examples ``` use ty_module_resolver::ModuleName; assert_eq!( ModuleName::n
crates/ty_module_resolver/src/module_name.rs:309
↓ 30 callersMethodas_slice
(&self)
crates/ty_python_core/src/use_def/place_state.rs:267
↓ 30 callersFunctionassert_fail
(result: Result<Vec<Diagnostic>, FailuresByLine>, messages: &[(usize, &[&str])])
crates/mdtest/src/matcher.rs:598
↓ 30 callersMethodbuild
Build the test server
crates/ruff_server/tests/e2e/main.rs:1152
↓ 30 callersMethodclear
Clears state such that this group is indistinguishable from an empty group.
crates/ty_ide/src/all_symbols.rs:370
↓ 30 callersMethodend_of_scope_symbol_bindings
( &self, symbol: ScopedSymbolId, )
crates/ty_python_core/src/use_def.rs:1222
↓ 30 callersMethodfile_scope
(self, db: &'db dyn Db)
crates/ty_python_core/src/definition.rs:100
↓ 30 callersFunctionfilter_result_id
Redact result_id values since they are hash-based and non-deterministic
crates/ty_server/tests/e2e/pull_diagnostics.rs:922
↓ 30 callersMethodinto_owned
(self)
crates/ty_python_semantic/src/types/signatures.rs:5913
↓ 30 callersMethodis_own_line
(self)
crates/ruff_python_trivia/src/comments.rs:97
↓ 30 callersMethoditer
(&self, context: &ResolverContext<'db>)
crates/ty_module_resolver/src/resolve/search.rs:1039
↓ 30 callersMethodlast_mut
(&mut self)
crates/ruff_index/src/slice.rs:54
↓ 30 callersFunctionmap_callable
Given an [`Expr`] that can be callable or not (like a decorator, which could be used with or without explicit call syntax), return the underlying call
crates/ruff_python_ast/src/helpers.rs:890
↓ 30 callersMethodor
(self, other: Self)
crates/ty_python_semantic/src/types/dedicated/pydantic.rs:582
↓ 30 callersMethodrange
(&self)
crates/ruff_linter/src/rules/flake8_commas/rules/trailing_commas.rs:41
↓ 30 callersMethodsend
(&mut self, message: Message)
crates/ty_server/tests/e2e/main.rs:383
↓ 30 callersMethodstarts_with
(&self, other: &QualifiedName<'_>)
crates/ruff_python_ast/src/name.rs:373
↓ 30 callersMethodstore_expression_type
(&mut self, expression: &ast::Expr, ty: Type<'db>)
crates/ty_python_semantic/src/types/infer/builder.rs:7320
↓ 30 callersFunctionwalk_stmt
(checker: &Checker, body: &[Stmt], f: fn(&Stmt) -> bool)
crates/ruff_linter/src/rules/flake8_bugbear/rules/jump_statement_in_finally.rs:58
↓ 30 callersMethodwrite_project_file
( &self, relative_path: impl AsRef<SystemPath>, content: &str, )
crates/ty/tests/file_watching.rs:388
↓ 29 callersFunctionPython
({ height = 24, width = 24, }: { height?: number; width?: number; })
playground/shared/src/Icons.tsx:209
↓ 29 callersMethodas_attribute_expr
(&self)
crates/ruff_python_ast/src/generated.rs:2569
↓ 29 callersMethodas_system_path
(&self)
crates/ty_module_resolver/src/path.rs:827
↓ 29 callersFunctionassert_parameter_documentation
(raw: &str, expected: &[(&str, &str)])
crates/ty_ide/src/docstring/document/google.rs:1640
↓ 29 callersFunctioncreate_constraint
( db: &'db TestDb, builder: &'c ConstraintSetBuilder<'db>, bound_typevar: BoundTypeVar
crates/ty_python_semantic/src/types/constraints.rs:5283
↓ 29 callersMethodextension
(&self)
crates/ruff_db/src/files/path.rs:96
↓ 29 callersFunctionfile_to_module
( db: &'db dyn Db, resolver_file: ResolverFile<'db>, )
crates/ty_module_resolver/src/resolve.rs:394
↓ 29 callersMethodinterface
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/instance.rs:2094
↓ 29 callersMethodis_dynamic
(self)
crates/ty_python_semantic/src/types/subclass_of.rs:176
↓ 29 callersMethoditer_mut
( &mut self, )
crates/ty_python_core/src/frozen.rs:50
↓ 29 callersMethodline_start
Compute the start position of the docstring's opening line
crates/ruff_linter/src/docstrings/mod.rs:40
↓ 29 callersMethodnext
Advances the cursor and returns the next line.
crates/ty_ide/src/docstring/document/rst.rs:93
↓ 29 callersMethodnode
(self, db: &'db dyn Db)
crates/ty_python_core/src/scope.rs:42
↓ 29 callersMethodreference
(&self, id: ResolvedReferenceId)
crates/ruff_python_semantic/src/model.rs:265
↓ 29 callersFunctionsetup_rayon
()
crates/ruff_benchmark/benches/ty_shared/mod.rs:21
↓ 29 callersMethodsignature
Typed internally-visible signature for this function. This represents the annotations on the function itself, unmodified by decorators and overloads.
crates/ty_python_semantic/src/types/function.rs:551
↓ 29 callersMethodtake_watch_changes
(&self, matcher: M)
crates/ty/tests/file_watching.rs:194
↓ 29 callersMethodto_comments
(&self)
crates/ruff_python_formatter/src/comments/mod.rs:578
↓ 29 callersFunctiontoken
(text: &'static str)
crates/ruff_formatter/src/builders.rs:254
↓ 29 callersFunctiontokenize
(source: &'static str)
crates/ruff_python_trivia_integration_tests/tests/simple_tokenizer.rs:45
↓ 29 callersMethodwith_file
( mut self, path: &'a (impl AsRef<SystemPath> + ?Sized), content: &'a str,
crates/ty_python_semantic/src/db.rs:272
↓ 29 callersMethodwith_mocked_typeshed
Use a mock typeshed directory for this test case
crates/ty_module_resolver/src/testing.rs:202
↓ 28 callersMethodalways
(&self)
crates/ty_python_semantic/src/types/relation.rs:1859
↓ 28 callersMethodas_class
(&self)
crates/ty_python_core/src/scope.rs:415
↓ 28 callersMethodas_class_literal
(self)
crates/ty_python_semantic/src/types.rs:3077
↓ 28 callersMethodas_single
Returns `(left, operator, right)` if there is exactly one operator and two operands.
crates/ruff_python_ast/src/nodes.rs:161
← previousnext →501–600 of 31,766, ranked by callers