From 012fec54dc508896493d5d3073b4786c93d66fe9 Mon Sep 17 00:00:00 2001 From: Muhammad Mominul Huque Date: Mon, 8 Jul 2019 03:29:38 +0600 Subject: Constify KnownName's --- crates/ra_hir/src/generics.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'crates/ra_hir/src/generics.rs') diff --git a/crates/ra_hir/src/generics.rs b/crates/ra_hir/src/generics.rs index 521e47090..3ad2c551a 100644 --- a/crates/ra_hir/src/generics.rs +++ b/crates/ra_hir/src/generics.rs @@ -9,6 +9,7 @@ use ra_syntax::ast::{self, DefaultTypeParamOwner, NameOwner, TypeBoundsOwner, Ty use crate::{ db::{AstDatabase, DefDatabase, HirDatabase}, + name::SELF_TYPE, path::Path, type_ref::TypeRef, AdtDef, AsName, Container, Enum, EnumVariant, Function, HasSource, ImplBlock, Name, Struct, @@ -83,7 +84,7 @@ impl GenericParams { // traits get the Self type as an implicit first type parameter generics.params.push(GenericParam { idx: start, - name: Name::self_type(), + name: SELF_TYPE, default: None, }); generics.fill(&*it.source(db).ast, start + 1); -- cgit v1.2.3