|
|
|
@ -106,11 +106,6 @@ namespace ICSharpCode.Decompiler.TypeSystem
@@ -106,11 +106,6 @@ namespace ICSharpCode.Decompiler.TypeSystem
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public override ITypeReference ToTypeReference() |
|
|
|
|
{ |
|
|
|
|
return new AnonymousTypeReference(unresolvedProperties); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public override string Name { |
|
|
|
|
get { return "Anonymous Type"; } |
|
|
|
|
} |
|
|
|
@ -197,25 +192,4 @@ namespace ICSharpCode.Decompiler.TypeSystem
@@ -197,25 +192,4 @@ namespace ICSharpCode.Decompiler.TypeSystem
|
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Anonymous type reference.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[Serializable] |
|
|
|
|
public class AnonymousTypeReference : ITypeReference |
|
|
|
|
{ |
|
|
|
|
readonly IUnresolvedProperty[] unresolvedProperties; |
|
|
|
|
|
|
|
|
|
public AnonymousTypeReference(IUnresolvedProperty[] properties) |
|
|
|
|
{ |
|
|
|
|
if (properties == null) |
|
|
|
|
throw new ArgumentNullException("properties"); |
|
|
|
|
this.unresolvedProperties = properties; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
public IType Resolve(ITypeResolveContext context) |
|
|
|
|
{ |
|
|
|
|
return new AnonymousType(context.Compilation, unresolvedProperties); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|