TypeReference FixTypeReference(TypeReference type, Location location, ICompilationUnit domCu, ReturnTypeOptions options) { if (type == null || type.IsKeyword) { return(type); } ICSharpCode.SharpDevelop.Dom.IClass curType = domCu.GetInnermostClass(location.Y, location.X); IReturnType rt = SharpDevelop.Dom.NRefactoryResolver.TypeVisitor.CreateReturnType( type, curType, null, location.Y, location.X, domCu.ProjectContent, options); if (rt != null && rt.GetUnderlyingClass() != null) { return(SharpDevelop.Dom.Refactoring.CodeGenerator.ConvertType(rt, null)); } else { return(type); } }
TypeReference FixTypeReference(TypeReference type, Location location, ICompilationUnit domCu, ReturnTypeOptions options) { if (type == null || type.IsKeyword) return type; ICSharpCode.SharpDevelop.Dom.IClass curType = domCu.GetInnermostClass(location.Y, location.X); IReturnType rt = SharpDevelop.Dom.NRefactoryResolver.TypeVisitor.CreateReturnType( type, curType, null, location.Y, location.X, domCu.ProjectContent, options); if (rt != null && rt.GetUnderlyingClass() != null) { return SharpDevelop.Dom.Refactoring.CodeGenerator.ConvertType(rt, null); } else { return type; } }