MCPcopy Create free account

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

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

↓ 6 callersMethodbuild
(self)
crates/ty_project/src/glob/exclude.rs:90
↓ 6 callersMethodbuild
(self)
crates/ty_python_core/src/db.rs:159
↓ 6 callersMethodbump_any
Bumps the current token regardless of its kind and advances to the next token. # Panics If the parser is at end of file.
crates/ruff_python_parser/src/parser/mod.rs:588
↓ 6 callersMethodbump_revision
Bumps the revision. The revision is used to track when workspace diagnostics may have changed and need to be re-run. It's okay if a bump doesn't nece
crates/ty_server/src/session.rs:414
↓ 6 callersMethodcache_key
(&self)
crates/ty_project/src/uv/service.rs:180
↓ 6 callersMethodcall
(param)
crates/ruff_python_formatter/resources/test/fixtures/black/cases/fmtonoff5.py:52
↓ 6 callersMethodcancel
(&mut self, request_id: &RequestId)
crates/ty_server/tests/e2e/main.rs:784
↓ 6 callersMethodcell_offsets
Return the [`CellOffsets`] for the concatenated source code corresponding the Jupyter notebook.
crates/ruff_notebook/src/notebook.rs:399
↓ 6 callersMethodcharge_type
Charges the set-theoretic terms that a type constructor may flatten or inspect. Aliases are included so a large union cannot evade the limit by being
crates/ty_python_semantic/src/types/constraints/projection.rs:73
↓ 6 callersFunctioncheck
()
crates/ty_wasm/tests/api.rs:7
↓ 6 callersFunctioncheck_file
(db: &dyn Db, file: ProgramFile<'_>)
crates/ty_python_semantic/src/lib.rs:235
↓ 6 callersMethodcheck_types_impl
( &mut self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, constraints: &Con
crates/ty_python_semantic/src/types/call/bind.rs:1405
↓ 6 callersMethodclear_salsa_events
Clears the emitted salsa events.
crates/ruff_db/src/lib.rs:181
↓ 6 callersMethodclone
(self, checkout_dir: Path)
scripts/ty_benchmark/src/benchmark/projects.py:43
↓ 6 callersMethodcmp
(&self, other: &Self)
crates/ty_python_semantic/src/types/constraints/paths.rs:187
↓ 6 callersMethodcodes_as_str
Return the suppressed codes as strings
crates/ruff_linter/src/suppression.rs:79
↓ 6 callersMethodcombine
(self, other: Self)
crates/ty_combine/src/lib.rs:82
↓ 6 callersFunctioncommand
()
crates/ruff/tests/analyze_graph.rs:15
↓ 6 callersMethodcomments_in_range
Returns the comments who are within the range
crates/ruff_python_trivia/src/comment_ranges.rs:94
↓ 6 callersFunctioncompletion
( db: &'db dyn Db, settings: &CompletionSettings, capabilities: CompletionCapabilities, file:
crates/ty_ide/src/completion.rs:36
↓ 6 callersMethodcompose_thunk
(self, other: F)
crates/ty_python_semantic/src/types/variance.rs:154
↓ 6 callersMethodconstructed_instance_type
(&self)
crates/ty_python_semantic/src/types/call/bind/constructor.rs:77
↓ 6 callersMethodcontents
(&self)
crates/ty_server/src/document/text_document.rs:77
↓ 6 callersMethodcontext
Set the number of contextual lines to include for each snippet in diagnostic rendering.
crates/ruff_db/src/diagnostic/render.rs:2560
↓ 6 callersFunctioncreate_diagnostics
( filename: &str, source: &str, edit: impl IntoIterator<Item = Edit>, )
crates/ruff_linter/src/fix/mod.rs:184
↓ 6 callersFunctioncreate_notebook_diagnostics
Create Ruff-style diagnostics for testing the various output formats for a notebook.
crates/ruff_db/src/diagnostic/render.rs:3140
↓ 6 callersMethodcurrent_scope_id
(&self)
crates/ty_python_core/src/builder.rs:398
↓ 6 callersMethodcurrent_token_text
(&self)
crates/ruff_python_parser/src/parser/mod.rs:497
↓ 6 callersFunctioncustom_enum_method
Returns the enum method defined in `scope`, including opaque bindings.
crates/ty_python_semantic/src/types/enums.rs:1507
↓ 6 callersFunctiondataclass_kind
Return the kind of dataclass this class definition is (stdlib or `attrs`), or `None` if the class is not a dataclass.
crates/ruff_linter/src/rules/ruff/helpers.rs:106
↓ 6 callersMethoddeclarations_id
(self)
crates/ty_python_core/src/use_def.rs:342
↓ 6 callersMethoddeclared
(self)
crates/ty_python_semantic/src/types/infer.rs:1208
↓ 6 callersMethoddedent
(&mut self)
crates/ruff_python_parser/src/lexer/indentation.rs:121
↓ 6 callersMethoddefer_annotations
Are we currently inferring types in file with deferred types? This is true for stub files, for files with `__future__.annotations`, and by default for
crates/ty_python_semantic/src/types/infer/builder.rs:1039
↓ 6 callersMethoddefinition
Returns where this type is defined. It's the foundation for the editor's "Go to type definition" feature where the user clicks on a value and it take
crates/ty_python_semantic/src/types.rs:10914
↓ 6 callersMethoddefinition
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/cyclic.rs:299
↓ 6 callersMethoddefinition_span
Returns a [`Span`] pointing to the definition of this class. For static classes, this is the class header (name and arguments). For dynamic classes,
crates/ty_python_semantic/src/types/class.rs:2577
↓ 6 callersFunctiondefinitions_for_name
Returns definitions for IDE navigation, expanding numeric annotations to their accepted classes.
crates/ty_python_semantic/src/types/ide_support.rs:83
↓ 6 callersMethoddeprecated_functions
Returns the deprecated functions invoked by each union alternative, including downstream constructor methods. An intersection only reports deprecation
crates/ty_python_semantic/src/types/call/bind.rs:988
↓ 6 callersFunctiondeserialize
(deserializer: D)
crates/ty_project/src/uv/metadata/string_interner.rs:37
↓ 6 callersMethoddispose
()
playground/ty/src/Editor/Editor.tsx:556
↓ 6 callersMethodeat_if
Eats the next character if `predicate` returns `true`.
crates/ruff_python_trivia/src/cursor.rs:152
↓ 6 callersMethodemit
(&mut self, text: &dyn Debug)
crates/ruff_python_ast_integration_tests/tests/source_order.rs:176
↓ 6 callersFunctionempty
()
crates/ty_python_core/src/lib.rs:1305
↓ 6 callersMethodentries
Adds the contents of an iterator of entries to the join output.
crates/ruff_formatter/src/builders.rs:2491
↓ 6 callersFunctionenumerate_argument_types
( arguments: &'a CallArguments<'a, 'db>, )
crates/ty_python_semantic/src/types/call/bind.rs:5963
↓ 6 callersMethodenv_remove
Removes an environment variable from the command.
crates/ruff_db/src/system/command.rs:61
↓ 6 callersMethodescape_for_display
(mut self)
crates/ruff_python_literal/src/escape.rs:84
↓ 6 callersMethodevaluate
( &self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, id: ScopedPredicateId
crates/ty_python_semantic/src/reachability.rs:851
↓ 6 callersMethodevaluate_expr_compare_op
( &self, lhs_ty: Type<'db>, rhs_ty: Type<'db>, op: ast::CmpOp, is_posi
crates/ty_python_semantic/src/types/narrow.rs:3919
↓ 6 callersFunctionevaluate_reachability_with_cache
Evaluates a reachability constraint, optionally using an inference-local cache.
crates/ty_python_semantic/src/reachability.rs:2263
↓ 6 callersFunctionexact
( db: &'db TestDb, builder: &'c ConstraintSetBuilder<'db>, typevar: BoundTypeVarInstance<'db>,
crates/ty_python_semantic/src/types/constraints/projection/tests.rs:39
↓ 6 callersFunctionexpect_formatted
(result: FormatResult)
crates/ruff_server/src/format.rs:389
↓ 6 callersMethodexpect_union
(self)
crates/ty_python_semantic/src/types.rs:3279
↓ 6 callersMethodexplicit_bases
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/enum_literal.rs:162
↓ 6 callersMethodextend_cycle_recovery
(&mut self, other: Option<Type<'db>>)
crates/ty_python_semantic/src/types/infer/builder.rs:632
↓ 6 callersMethodextend_definition
( &mut self, definition: Definition<'db>, inference: &DefinitionInference<'db>, )
crates/ty_python_semantic/src/types/infer/builder.rs:651
↓ 6 callersMethodextend_expression_types
Replacing an expression's type also replaces any truthiness override. A newly inferred comparison may no longer need an override, so extending the spa
crates/ty_python_semantic/src/types/infer/builder.rs:798
↓ 6 callersFunctionextract_result_ids_from_response
(response: &WorkspaceDiagnosticReport)
crates/ty_server/tests/e2e/pull_diagnostics.rs:1634
↓ 6 callersMethodfile_expression_type
Get the type of an expression from any scope in the same file. If the expression is in the current scope, and we are inferring the entire scope, just
crates/ty_python_semantic/src/types/infer/builder.rs:1149
↓ 6 callersFunctionfile_renames
(paths: &[(&str, &str)])
crates/ty_ide/src/will_rename.rs:2438
↓ 6 callersFunctionfile_to_uri
Returns a [`Uri`] for the given [`File`].
crates/ty_server/src/system.rs:26
↓ 6 callersFunctionfind_best_suggestion
( options: O, typo: &str, hide_underscored_suggestions: HideUnderscoredSuggestions, )
crates/ty_python_semantic/src/diagnostic/levenshtein.rs:27
↓ 6 callersMethodfirst_help_text
Returns the message of the first sub-diagnostic with a `Help` severity. Note that this is used as the fix title/suggestion for some of Ruff's output
crates/ruff_db/src/diagnostic/mod.rs:483
↓ 6 callersFunctionfix_all
Applies all fixes for the given fix mode. `check_file` is a separate parameter so that tests can easily mock out a file's diagnostics.
crates/ty_python_semantic/src/fixes.rs:80
↓ 6 callersFunctionfixture_bindings_for_parameter
( db: &'db dyn Db, parameter: Definition<'db>, )
crates/ty_python_semantic/src/types/dedicated/pytest/fixtures.rs:131
↓ 6 callersFunctionfixture_exposures_for_definition
Returns the available pytest fixture exposures contributed by `definition`. A decorated function contributes an exposure directly: ```python # fixtu
crates/ty_python_semantic/src/types/dedicated/pytest/fixtures.rs:307
↓ 6 callersMethodflow_snapshot
(&self)
crates/ty_python_core/src/builder.rs:1329
↓ 6 callersFunctionfoo
()
crates/ruff_linter/resources/test/fixtures/flake8_pytest_style/PT031.py:37
↓ 6 callersMethodfor_inheritance
Return the metaclass guaranteed by class declarations, without the typeshed fallback.
crates/ty_python_semantic/src/types/class.rs:3562
↓ 6 callersFunctionfull
()
crates/ty_python_semantic/src/types/signatures.rs:6779
↓ 6 callersMethodfuture_annotations_or_stub
(&self)
crates/ruff_linter/src/checkers/ast/mod.rs:921
↓ 6 callersMethodget
Get a resolved glob.
crates/ruff/src/commands/analyze_graph.rs:304
↓ 6 callersMethodget
(&self, directive: MdtestDirective)
crates/mdtest/src/parser.rs:1101
↓ 6 callersMethodget_default
Returns the most appropriate type of this argument when there is no specific declared type.
crates/ty_python_semantic/src/types/call/arguments.rs:472
↓ 6 callersMethodhas
Returns `true` if this set has an option that resolves to `name`. The name can be separated by `.` to find a nested option. ## Examples ### Test fo
crates/ruff_options_metadata/src/lib.rs:199
↓ 6 callersMethodhas_aliases
Returns `true` if any direct element of this union is a type alias.
crates/ty_python_semantic/src/types/set_theoretic.rs:231
↓ 6 callersMethodhas_cyclic_mro
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class_base.rs:474
↓ 6 callersMethodhas_dangling
Returns `true` if node has any [dangling comments](self#dangling-comments).
crates/ruff_python_formatter/src/comments/mod.rs:308
↓ 6 callersMethodhas_generated_slots
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/slots.rs:266
↓ 6 callersMethodhas_implicit_receiver
Returns true if this overload has an implicit `self` or `cls` receiver parameter.
crates/ty_python_semantic/src/types/function.rs:382
↓ 6 callersMethodhas_known_fields
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/named_tuple.rs:485
↓ 6 callersMethodhas_relation_to
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, target: Type<'db>,
crates/ty_python_semantic/src/types/relation.rs:872
↓ 6 callersMethodhas_relation_to_with_typevar_evaluation
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, target: Type<'db>,
crates/ty_python_semantic/src/types/relation.rs:894
↓ 6 callersMethodhas_unspecialized_type_var
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, )
crates/ty_python_semantic/src/types/typevar.rs:142
↓ 6 callersMethodheader_span
Returns a [`Span`] pointing to the definition of this class. For static classes, this is the class header (name and arguments). For dynamic classes,
crates/ty_python_semantic/src/types/class.rs:1000
↓ 6 callersMethodhover
(&self)
crates/ty_ide/src/hover.rs:7556
↓ 6 callersFunctionimported_symbol
Infers the public type of an imported symbol. If `requires_explicit_reexport` is [`None`], it will be inferred from the file's source type. For stub
crates/ty_python_semantic/src/place.rs:539
↓ 6 callersMethodin_boolean_test
Return `true` if the model is in boolean test.
crates/ruff_python_semantic/src/model.rs:2280
↓ 6 callersMethodin_init_module
Returns whether the file under analysis is an `__init__.py` file.
crates/ruff_linter/src/checkers/ast/mod.rs:558
↓ 6 callersMethodin_pep_257_docstring
Return `true` if the model is in a docstring as described in [PEP 257]. [PEP 257]: https://peps.python.org/pep-0257/#what-is-a-docstring
crates/ruff_python_semantic/src/model.rs:2303
↓ 6 callersMethodin_runtime_evaluated_annotation
Return `true` if the context is in a runtime-evaluated type annotation.
crates/ruff_python_semantic/src/model.rs:2130
↓ 6 callersMethodinfer_optional_expression
( &mut self, expression: Option<&ast::Expr>, tcx: TypeContext<'db>, )
crates/ty_python_semantic/src/types/infer/builder.rs:6781
↓ 6 callersFunctioninfer_unpack_types
(db: &'db dyn Db, unpack: Unpack<'db>)
crates/ty_python_semantic/src/types/infer.rs:894
↓ 6 callersMethodinferred_metaclass
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class.rs:746
↓ 6 callersMethodinsert
Insert a resolved glob.
crates/ruff/src/commands/analyze_graph.rs:299
↓ 6 callersMethodinsert
Insert the type of this argument when inferred with the provided type context.
crates/ty_python_semantic/src/types/call/arguments.rs:507
↓ 6 callersMethodintern_bindings
(&mut self, bindings: &Bindings)
crates/ty_python_core/src/use_def.rs:376
↓ 6 callersMethodinterpolations
Returns an iterator over all the [`InterpolatedElement`] nodes contained in this f-string.
crates/ruff_python_ast/src/nodes.rs:1427
↓ 6 callersMethodinto_code
Access the resulting code, consuming the result
crates/ruff_formatter/src/lib.rs:419
← previousnext →2,301–2,400 of 31,766, ranked by callers