Home
last modified time | relevance | path

Searched defs:TextRange (Results 1 – 25 of 74) sorted by relevance

123

/third_party/rust/rust/src/tools/rust-analyzer/crates/ide/src/annotations/
Dfn_references.rs14 ) -> Vec<(TextRange, Option<TextRange>)> { in find_all_methods()
20 fn method_range(item: SyntaxNode) -> Option<(TextRange, Option<TextRange>)> { in method_range()
93 fn check_result(refs: &[(TextRange, Option<TextRange>)], expected: &[RangeInclusive<u32>]) { in check_result()
/third_party/rust/rust/src/tools/rust-analyzer/crates/mbe/src/
Dtoken_map.rs17 fn by_kind(self, kind: SyntaxKind) -> Option<TextRange> { in by_kind()
71 ) -> Option<TextRange> { in first_range_by_token()
80 pub(crate) fn insert(&mut self, token_id: tt::TokenId, relative_range: TextRange) { in insert()
91 open_relative_range: TextRange, in insert_delim()
92 close_relative_range: TextRange, in insert_delim()
101 pub(crate) fn update_close_delim(&mut self, idx: usize, close_relative_range: TextRange) { in update_close_delim()
/third_party/rust/rust/src/tools/rust-analyzer/crates/syntax/test_data/parser/fuzz-failures/
D0001.rs7 pub fn extend_selection(file: &File, range: TextRange) -> Option<TextRange> { in extend_selection()
12 pub(crate) fn extend(root: SyntaxNodeRef, range: TextRange) -> Option<TextRange> { in extend()
39 fn extend_ws(root: SyntaxNodeRef, ws: SyntaxNodeRef, offset: TextUnit) -> TextRange { in extend_ws()
73 fn extend_comments(node: SyntaxNodeRef) -> Option<TextRange> { in extend_comments()
D0000.rs67 pub fn replace(range: TextRange, replace_with: String) -> AtomTextEdit { in replace()
96 pub /*(meh)*/ fn replace_range(mut text: String, range: TextRange, replace_with: &str) -> String { in replace_range()
118 pub fn replace(range: TextRange, replace_with: String) -> AtomTextEdit {
148 pub /*(meh)*/ fn replace_range(mut text: String, range: TextRange, replace_with: &str) -> String {
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide-db/src/syntax_helpers/
Dformat_string.rs56 mut callback: &mut dyn FnMut(TextRange, FormatSpecifier), in lex_format_specifiers()
256 F: FnMut(TextRange, FormatSpecifier), in lex_format_specifiers()
265 F: FnMut(TextRange, FormatSpecifier), in lex_format_specifiers()
283 F: FnMut(TextRange, FormatSpecifier), in lex_format_specifiers()
301 F: FnMut(TextRange, FormatSpecifier), in lex_format_specifiers()
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide/src/
Dextend_selection.rs29 pub(crate) fn extend_selection(db: &RootDatabase, frange: FileRange) -> TextRange { in extend_selection()
39 ) -> Option<TextRange> { in try_extend_selection()
125 original_range: TextRange, in extend_tokens_from_range()
126 ) -> Option<TextRange> { in extend_tokens_from_range()
197 ) -> Option<TextRange> { in extend_single_word_in_comment_or_string()
221 fn extend_ws(root: &SyntaxNode, ws: SyntaxToken, offset: TextSize) -> TextRange { in extend_ws()
256 fn extend_list_item(node: &SyntaxNode) -> Option<TextRange> { in extend_list_item()
298 fn extend_comments(comment: ast::Comment) -> Option<TextRange> { in extend_comments()
Dfolding_ranges.rs214 ) -> Option<TextRange> { in contiguous_range_for_comment()
261 fn fold_range_for_where_clause(where_clause: ast::WhereClause) -> Option<TextRange> { in fold_range_for_where_clause()
273 fn fold_range_for_multiline_match_arm(match_arm: ast::MatchArm) -> Option<TextRange> { in fold_range_for_multiline_match_arm()
Dmove_item.rs101 range: TextRange, in move_in_direction()
121 range: TextRange, in swap_sibling_in_list()
140 range: TextRange, in replace_nodes()
Dannotations.rs152 ) -> Option<(TextRange, Option<TextRange>)> { in annotations()
Dsyntax_highlighting.rs187 range_to_highlight: Option<TextRange>, in highlight()
224 range_to_highlight: TextRange, in traverse()
/third_party/rust/rust/src/tools/rust-analyzer/crates/test-utils/src/
Dlib.rs83 pub fn extract_range(text: &str) -> (TextRange, String) { in extract_range()
92 fn try_extract_range(text: &str) -> Option<(TextRange, String)> { in try_extract_range()
111 pub fn expect_range(self) -> TextRange { in expect_range()
117 pub fn range_or_empty(self) -> TextRange { in range_or_empty()
125 impl From<RangeOrOffset> for TextRange { implementation
148 pub fn extract_tags(mut text: &str, tag: &str) -> (Vec<(TextRange, Option<String>)>, String) { in extract_tags()
232 pub fn extract_annotations(text: &str) -> Vec<(TextRange, String)> { in extract_annotations()
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide/src/syntax_highlighting/
Dinjector.rs15 pub(super) fn add(&mut self, text: &str, source_range: TextRange) { in add()
75 impl ops::Add<Delta<TextSize>> for TextRange { implementation
78 fn add(self, rhs: Delta<TextSize>) -> TextRange { in add()
Dformat.rs14 range: TextRange, in highlight_format_string()
/third_party/rust/rust/src/tools/rust-analyzer/crates/syntax/src/parsing/
Dreparsing.rs24 ) -> Option<(GreenNode, Vec<SyntaxError>, TextRange)> { in incremental_reparse() argument
38 ) -> Option<(GreenNode, Vec<SyntaxError>, TextRange)> { in reparse_token() argument
87 ) -> Option<(GreenNode, Vec<SyntaxError>, TextRange)> { in reparse_block() argument
152 range_before_reparse: TextRange, in merge_errors()
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide-assists/src/handlers/
Dextract_module.rs238 ) -> (HashMap<FileId, Vec<(TextRange, String)>>, Vec<SyntaxNode>) { in get_usages_and_record_fields()
323 refs_in_files: &mut HashMap<FileId, Vec<(TextRange, String)>>, in expand_and_group_usages_file_wise()
401 ) -> Vec<TextRange> { in resolve_imports()
476 ) -> Option<TextRange> { in process_names_and_namerefs_for_import_resolve()
628 ) -> Option<(Vec<ast::Path>, Option<TextRange>)> { in process_use_stmt_for_import_resolve()
661 import_paths_to_be_removed: &mut Vec<TextRange>, in check_intersection_and_push()
662 mut import_path: TextRange, in check_intersection_and_push()
685 selection_range: TextRange, in does_source_exists_outside_sel_in_same_mod()
914 fn indent_range_before_given_node(node: &SyntaxNode) -> Option<TextRange> { in indent_range_before_given_node()
Dintroduce_named_lifetime.rs56 lifetime_loc: TextRange, in generate_fn_def_assist()
106 lifetime_loc: TextRange, in generate_impl_def_assist()
Dfix_visibility.rs152 ) -> Option<(TextSize, Option<ast::Visibility>, TextRange, FileId, Option<hir::Name>)> { in target_data_for_def() argument
156 ) -> Option<(TextSize, Option<ast::Visibility>, TextRange, FileId)> in target_data_for_def() argument
Dsort_items.rs117 target: TextRange, in add_rewrite()
129 target: TextRange, in add_rewrite()
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide-assists/src/
Dassist_context.rs103 pub(crate) fn selection_trimmed(&self) -> TextRange { in selection_trimmed()
157 target: TextRange, in add()
169 target: TextRange, in add_group()
181 target: TextRange, in add_impl()
/third_party/rust/rust/src/tools/rust-analyzer/crates/text-edit/src/
Dlib.rs41 pub fn replace(range: TextRange, replace_with: String) -> Indel { in replace()
69 pub fn replace(range: TextRange, replace_with: String) -> TextEdit { in replace()
167 pub fn replace(&mut self, range: TextRange, replace_with: String) { in replace()
170 pub fn delete(&mut self, range: TextRange) { in delete()
228 fn range(start: u32, end: u32) -> TextRange { in range()
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide-ssr/src/
Dfrom_comment.rs21 ) -> Option<(MatchFinder<'_>, TextRange)> { in ssr_from_comment() argument
/third_party/rust/rust/src/tools/rust-analyzer/crates/ide-diagnostics/src/
Dlib.rs201 precise_location: Option<TextRange>, in resolve_precise_location()
202 ) -> TextRange { in resolve_precise_location()
341 adj: &dyn Fn(N) -> Option<TextRange>, in adjusted_display_range()
342 ) -> TextRange { in adjusted_display_range()
/third_party/rust/rust/src/tools/rust-analyzer/crates/syntax/src/
Dsyntax_error.rs30 pub fn range(&self) -> TextRange { in range()
/third_party/rust/rust/src/tools/rust-analyzer/crates/syntax/src/ast/
Dtoken_ext.rs162 fn text_range_between_quotes(&self) -> Option<TextRange> { in text_range_between_quotes()
165 fn open_quote_text_range(&self) -> Option<TextRange> { in open_quote_text_range()
168 fn close_quote_text_range(&self) -> Option<TextRange> { in close_quote_text_range()
173 cb: &mut dyn FnMut(TextRange, Result<char, rustc_lexer::unescape::EscapeError>), in escaped_char_ranges()
190 fn map_range_up(&self, range: TextRange) -> Option<TextRange> { in map_range_up()
/third_party/rust/rust/src/tools/rust-analyzer/lib/line-index/tests/
Dit.rs38 fn r(lo: u32, hi: u32) -> TextRange { in test_splitlines()

123