/dports/devel/rust-analyzer/rust-analyzer-2021-12-20/crates/ide_assists/src/handlers/ |
H A D | generate_delegate_methods.rs | 80 let impl_def = find_struct_impl(ctx, &adt, &name).flatten(); in generate_delegate_methods() localVariable 118 match impl_def { in generate_delegate_methods() 119 Some(impl_def) => { in generate_delegate_methods() 121 let impl_def = impl_def.clone_for_update(); in generate_delegate_methods() localVariable 122 let old_range = impl_def.syntax().text_range(); in generate_delegate_methods() 125 let assoc_items = impl_def.get_or_create_assoc_item_list(); in generate_delegate_methods() 131 let snippet = render_snippet(cap, impl_def.syntax(), cursor); in generate_delegate_methods() 135 builder.replace(old_range, impl_def.syntax().to_string()); in generate_delegate_methods() 146 let assoc_items = impl_def.get_or_create_assoc_item_list(); in generate_delegate_methods() 153 let snippet = render_snippet(cap, impl_def.syntax(), cursor); in generate_delegate_methods() [all …]
|
H A D | add_missing_impl_members.rs | 104 let impl_def = ctx.find_node_at_offset::<ast::Impl>()?; in add_missing_impl_members_inner() localVariable 105 let trait_ = resolve_target_trait(&ctx.sema, &impl_def)?; in add_missing_impl_members_inner() 109 &ide_db::traits::get_missing_assoc_items(&ctx.sema, &impl_def), in add_missing_impl_members_inner() 117 let target = impl_def.syntax().text_range(); in add_missing_impl_members_inner() 119 let target_scope = ctx.sema.scope(impl_def.syntax()); in add_missing_impl_members_inner() 135 impl_def.clone(), in add_missing_impl_members_inner() 144 if try_gen_trait_body(ctx, func, &trait_, &impl_def).is_none() { in add_missing_impl_members_inner() 168 impl_def: &ast::Impl, in try_gen_trait_body() 171 let hir_ty = ctx.sema.resolve_type(&impl_def.self_ty()?)?; in try_gen_trait_body()
|
H A D | generate_setter.rs | 41 let impl_def = find_struct_impl( in generate_setter() localVariable 60 if impl_def.is_some() { in generate_setter() 81 let start_offset = impl_def in generate_setter() 82 .and_then(|impl_def| find_impl_block_end(impl_def, &mut buf)) in generate_setter()
|
H A D | generate_new.rs | 39 let impl_def = find_struct_impl(ctx, &ast::Adt::Struct(strukt.clone()), "new")?; in generate_new() localVariable 45 if impl_def.is_some() { in generate_new() 59 let start_offset = impl_def in generate_new() 60 .and_then(|impl_def| find_impl_block_start(impl_def, &mut buf)) in generate_new()
|
H A D | introduce_named_lifetime.rs | 45 } else if let Some(impl_def) = lifetime.syntax().ancestors().find_map(ast::Impl::cast) { in introduce_named_lifetime() 46 generate_impl_def_assist(acc, impl_def, lifetime_loc, lifetime) in introduce_named_lifetime() 105 impl_def: ast::Impl, in generate_impl_def_assist() 109 let new_lifetime_param = generate_unique_lifetime_param_name(impl_def.generic_param_list())?; in generate_impl_def_assist() 111 let impl_def = builder.make_mut(impl_def); in generate_impl_def_assist() localVariable 114 impl_def.get_or_create_generic_param_list().add_generic_param( in generate_impl_def_assist()
|
H A D | generate_getter.rs | 94 let impl_def = find_struct_impl(ctx, &ast::Adt::Struct(strukt.clone()), fn_name.as_str())?; in generate_getter_impl() localVariable 110 if impl_def.is_some() { in generate_getter_impl() 148 let start_offset = impl_def in generate_getter_impl() 149 .and_then(|impl_def| find_impl_block_end(impl_def, &mut buf)) in generate_getter_impl()
|
/dports/lang/rust/rustc-1.58.1-src/src/tools/rust-analyzer/crates/ide_assists/src/handlers/ |
H A D | generate_delegate_methods.rs | 81 let impl_def = find_struct_impl(ctx, &adt, &name).flatten(); in generate_delegate_methods() localVariable 119 match impl_def { in generate_delegate_methods() 120 Some(impl_def) => { in generate_delegate_methods() 122 let impl_def = impl_def.clone_for_update(); in generate_delegate_methods() localVariable 123 let old_range = impl_def.syntax().text_range(); in generate_delegate_methods() 126 let assoc_items = impl_def.get_or_create_assoc_item_list(); in generate_delegate_methods() 132 let snippet = render_snippet(cap, impl_def.syntax(), cursor); in generate_delegate_methods() 136 builder.replace(old_range, impl_def.syntax().to_string()); in generate_delegate_methods() 147 let assoc_items = impl_def.get_or_create_assoc_item_list(); in generate_delegate_methods() 154 let snippet = render_snippet(cap, impl_def.syntax(), cursor); in generate_delegate_methods() [all …]
|
H A D | add_missing_impl_members.rs | 104 let impl_def = ctx.find_node_at_offset::<ast::Impl>()?; in add_missing_impl_members_inner() localVariable 105 let trait_ = resolve_target_trait(&ctx.sema, &impl_def)?; in add_missing_impl_members_inner() 109 &ide_db::traits::get_missing_assoc_items(&ctx.sema, &impl_def), in add_missing_impl_members_inner() 117 let target = impl_def.syntax().text_range(); in add_missing_impl_members_inner() 119 let target_scope = ctx.sema.scope(impl_def.syntax()); in add_missing_impl_members_inner() 124 impl_def.clone(), in add_missing_impl_members_inner() 133 if try_gen_trait_body(ctx, func, &trait_, &impl_def).is_none() { in add_missing_impl_members_inner() 157 impl_def: &ast::Impl, in try_gen_trait_body() 160 let hir_ty = ctx.sema.resolve_type(&impl_def.self_ty()?)?; in try_gen_trait_body()
|
H A D | generate_setter.rs | 41 let impl_def = find_struct_impl( in generate_setter() localVariable 60 if impl_def.is_some() { in generate_setter() 81 let start_offset = impl_def in generate_setter() 82 .and_then(|impl_def| find_impl_block_end(impl_def, &mut buf)) in generate_setter()
|
H A D | generate_new.rs | 39 let impl_def = find_struct_impl(ctx, &ast::Adt::Struct(strukt.clone()), "new")?; in generate_new() localVariable 45 if impl_def.is_some() { in generate_new() 59 let start_offset = impl_def in generate_new() 60 .and_then(|impl_def| find_impl_block_start(impl_def, &mut buf)) in generate_new()
|
H A D | introduce_named_lifetime.rs | 45 } else if let Some(impl_def) = lifetime.syntax().ancestors().find_map(ast::Impl::cast) { in introduce_named_lifetime() 46 generate_impl_def_assist(acc, impl_def, lifetime_loc, lifetime) in introduce_named_lifetime() 105 impl_def: ast::Impl, in generate_impl_def_assist() 109 let new_lifetime_param = generate_unique_lifetime_param_name(impl_def.generic_param_list())?; in generate_impl_def_assist() 111 let impl_def = builder.make_mut(impl_def); in generate_impl_def_assist() localVariable 114 impl_def.get_or_create_generic_param_list().add_generic_param( in generate_impl_def_assist()
|
H A D | generate_getter.rs | 94 let impl_def = find_struct_impl(ctx, &ast::Adt::Struct(strukt.clone()), fn_name.as_str())?; in generate_getter_impl() localVariable 110 if impl_def.is_some() { in generate_getter_impl() 148 let start_offset = impl_def in generate_getter_impl() 149 .and_then(|impl_def| find_impl_block_end(impl_def, &mut buf)) in generate_getter_impl()
|
/dports/devel/rust-analyzer/rust-analyzer-2021-12-20/crates/ide_completion/src/completions/ |
H A D | trait_impl.rs | 54 if let Some((kind, trigger, impl_def)) = completion_match(ctx.token.clone()) { in complete_trait_impl() 55 if let Some(hir_impl) = ctx.sema.to_def(&impl_def) { in complete_trait_impl() 56 get_missing_assoc_items(&ctx.sema, &impl_def).into_iter().for_each(|item| match item { in complete_trait_impl() 116 let impl_def = ast::Impl::cast(impl_item.parent()?.parent()?)?; in completion_match() localVariable 126 Some((kind, impl_item, impl_def)) in completion_match() 134 impl_def: hir::Impl, in add_function_impl() 182 impl_def: hir::Impl, in get_transformed_assoc_item() 185 let trait_ = impl_def.trait_(ctx.db)?; in get_transformed_assoc_item() 187 let target_scope = &ctx.sema.scope(ctx.sema.source(impl_def)?.syntax().value); in get_transformed_assoc_item() 192 impl_def.source(ctx.db)?.value, in get_transformed_assoc_item() [all …]
|
/dports/lang/rust/rustc-1.58.1-src/src/tools/rust-analyzer/crates/ide_completion/src/completions/ |
H A D | trait_impl.rs | 54 if let Some((kind, trigger, impl_def)) = completion_match(ctx.token.clone()) { in complete_trait_impl() 55 if let Some(hir_impl) = ctx.sema.to_def(&impl_def) { in complete_trait_impl() 56 get_missing_assoc_items(&ctx.sema, &impl_def).into_iter().for_each(|item| match item { in complete_trait_impl() 116 let impl_def = ast::Impl::cast(impl_item.parent()?.parent()?)?; in completion_match() localVariable 126 Some((kind, impl_item, impl_def)) in completion_match() 134 impl_def: hir::Impl, in add_function_impl() 182 impl_def: hir::Impl, in get_transformed_assoc_item() 185 let trait_ = impl_def.trait_(ctx.db)?; in get_transformed_assoc_item() 187 let target_scope = &ctx.sema.scope(ctx.sema.source(impl_def)?.syntax().value); in get_transformed_assoc_item() 192 impl_def.source(ctx.db)?.value, in get_transformed_assoc_item() [all …]
|
/dports/devel/rust-analyzer/rust-analyzer-2021-12-20/crates/ide_db/src/ |
H A D | traits.rs | 14 impl_def: &ast::Impl, in resolve_target_trait() 17 impl_def.trait_().map(|it| it.syntax().clone()).and_then(ast::PathType::cast)?.path()?; in resolve_target_trait() 29 impl_def: &ast::Impl, in get_missing_assoc_items() 36 if let Some(item_list) = impl_def.assoc_item_list() { in get_missing_assoc_items() 61 resolve_target_trait(sema, impl_def).map_or(vec![], |target_trait| { in get_missing_assoc_items()
|
/dports/lang/rust/rustc-1.58.1-src/src/tools/rust-analyzer/crates/ide_db/src/ |
H A D | traits.rs | 14 impl_def: &ast::Impl, in resolve_target_trait() 17 impl_def.trait_().map(|it| it.syntax().clone()).and_then(ast::PathType::cast)?.path()?; in resolve_target_trait() 29 impl_def: &ast::Impl, in get_missing_assoc_items() 36 if let Some(item_list) = impl_def.assoc_item_list() { in get_missing_assoc_items() 61 resolve_target_trait(sema, impl_def).map_or(vec![], |target_trait| { in get_missing_assoc_items()
|
/dports/net-im/zkgroup/zkgroup-0.7.4/cargo-crates/packed_simd-0.3.3/src/codegen/math/float/ |
H A D | sin_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
H A D | cos_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
/dports/textproc/ripgrep/ripgrep-13.0.0/cargo-crates/packed_simd_2-0.3.6/src/codegen/math/float/ |
H A D | sin_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
H A D | cos_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
/dports/www/firefox/firefox-99.0/third_party/rust/packed_simd/src/codegen/math/float/ |
H A D | cos_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
H A D | sin_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
/dports/mail/thunderbird/thunderbird-91.8.0/third_party/rust/packed_simd/src/codegen/math/float/ |
H A D | cos_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
H A D | sin_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|
/dports/www/geckodriver/mozilla-central-e9783a644016aa9b317887076618425586730d73/testing/geckodriver/cargo-crates/packed_simd-0.3.3/src/codegen/math/float/ |
H A D | sin_pi.rs | 14 macro_rules! impl_def { macro 26 impl_def!($vid, crate::f32::consts::PI); 31 impl_def!($vid, crate::f64::consts::PI);
|