Browse Source

Set NRefactory back to .NET 4.0 (we're not going to port ILSpy to .NET 3.5)

newNRvisualizers
Daniel Grunwald 15 years ago
parent
commit
65bf46a924
  1. 6
      ICSharpCode.NRefactory/CSharp/Ast/TypeMembers/Accessor.cs
  2. 8
      ICSharpCode.NRefactory/ICSharpCode.NRefactory.csproj
  3. 4
      ICSharpCode.NRefactory/Utils/DotNet35Compat.cs

6
ICSharpCode.NRefactory/CSharp/Ast/TypeMembers/Accessor.cs

@ -56,11 +56,7 @@ namespace ICSharpCode.NRefactory.CSharp @@ -56,11 +56,7 @@ namespace ICSharpCode.NRefactory.CSharp
get { return GetChildByRole (Roles.Body); }
set { SetChildByRole (Roles.Body, value); }
}
public AstNodeCollection<ParameterDeclaration> Parameters {
get { return GetChildrenByRole(Roles.Parameter); }
}
public override S AcceptVisitor<T, S>(IAstVisitor<T, S> visitor, T data)
{
return visitor.VisitAccessor (this, data);

8
ICSharpCode.NRefactory/ICSharpCode.NRefactory.csproj

@ -7,7 +7,7 @@ @@ -7,7 +7,7 @@
<OutputType>Library</OutputType>
<RootNamespace>ICSharpCode.NRefactory</RootNamespace>
<AssemblyName>ICSharpCode.NRefactory</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<AppDesignerFolder>Properties</AppDesignerFolder>
<ProductVersion>10.0.0</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
@ -15,7 +15,7 @@ @@ -15,7 +15,7 @@
<NoStdLib>False</NoStdLib>
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
<NoWarn>1591,0618</NoWarn>
<TargetFrameworkProfile />
<TargetFrameworkProfile>Client</TargetFrameworkProfile>
<RunCodeAnalysis>False</RunCodeAnalysis>
<CodeAnalysisRules>-Microsoft.Design#CA1026;-Microsoft.Security#CA2104</CodeAnalysisRules>
</PropertyGroup>
@ -30,14 +30,14 @@ @@ -30,14 +30,14 @@
<OutputPath>bin\Debug\</OutputPath>
<DebugType>Full</DebugType>
<Optimize>False</Optimize>
<DefineConstants>DEBUG;TRACE;FULL_AST;DOTNET35</DefineConstants>
<DefineConstants>DEBUG;TRACE;FULL_AST</DefineConstants>
<CheckForOverflowUnderflow>False</CheckForOverflowUnderflow>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
<OutputPath>bin\Release\</OutputPath>
<DebugType>None</DebugType>
<Optimize>True</Optimize>
<DefineConstants>TRACE;FULL_AST;DOTNET35</DefineConstants>
<DefineConstants>TRACE;FULL_AST</DefineConstants>
<CheckForOverflowUnderflow>False</CheckForOverflowUnderflow>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">

4
ICSharpCode.NRefactory/Utils/DotNet35Compat.cs

@ -16,7 +16,7 @@ internal static class DotNet35Compat @@ -16,7 +16,7 @@ internal static class DotNet35Compat
#endif
}
public static IEnumerable<U> SafeCast<T, U>(this IEnumerable<T> elements) where T : U
public static IEnumerable<U> SafeCast<T, U>(this IEnumerable<T> elements) where T : class, U where U : class
{
#if DOTNET35
foreach (T item in elements)
@ -26,7 +26,7 @@ internal static class DotNet35Compat @@ -26,7 +26,7 @@ internal static class DotNet35Compat
#endif
}
public static Predicate<U> SafeCast<T, U>(this Predicate<T> predicate) where U : T
public static Predicate<U> SafeCast<T, U>(this Predicate<T> predicate) where U : class, T where T : class
{
#if DOTNET35
return e => predicate(e);

Loading…
Cancel
Save