From c76240e9342142bbfd80aedab9598db374739c67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mike=20Kr=C3=BCger?= Date: Thu, 7 Feb 2013 09:49:50 +0100 Subject: [PATCH] Revert "Revert "[TypeSystem] Specialized method now contains a flag specifying the"" This reverts commit b758539431a287c3ad23f1911e07f72d939d928f. --- .../Resolver/OverloadResolution.cs | 2 ++ .../TypeSystem/Implementation/SpecializedMethod.cs | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/ICSharpCode.NRefactory.CSharp/Resolver/OverloadResolution.cs b/ICSharpCode.NRefactory.CSharp/Resolver/OverloadResolution.cs index a4efe127f5..13aecd79d8 100644 --- a/ICSharpCode.NRefactory.CSharp/Resolver/OverloadResolution.cs +++ b/ICSharpCode.NRefactory.CSharp/Resolver/OverloadResolution.cs @@ -950,6 +950,8 @@ namespace ICSharpCode.NRefactory.CSharp.Resolver if (member == null) throw new InvalidOperationException(); + if (this.IsExtensionMethodInvocation && member is SpecializedMethod) + ((SpecializedMethod)member).IsExtendedExtensionMethod = true; return new CSharpInvocationResolveResult( this.IsExtensionMethodInvocation ? new TypeResolveResult(member.DeclaringType) : targetResolveResult, member, diff --git a/ICSharpCode.NRefactory/TypeSystem/Implementation/SpecializedMethod.cs b/ICSharpCode.NRefactory/TypeSystem/Implementation/SpecializedMethod.cs index 087bf89f74..5636a5b457 100644 --- a/ICSharpCode.NRefactory/TypeSystem/Implementation/SpecializedMethod.cs +++ b/ICSharpCode.NRefactory/TypeSystem/Implementation/SpecializedMethod.cs @@ -153,6 +153,14 @@ namespace ICSharpCode.NRefactory.TypeSystem.Implementation accessorOwner = value; } } + + /// + /// Gets/Sets whether the method is an extension method that are being called using extension method syntax. + /// + public bool IsExtendedExtensionMethod { + get; + set; + } public override IMemberReference ToMemberReference() {