Skip to content

Commit 282d594

Browse files
committed
NH-3990 - Upgrade to VS2017.3 for VB project.
1 parent 9527cb0 commit 282d594

File tree

3 files changed

+45
-150
lines changed

3 files changed

+45
-150
lines changed
Lines changed: 35 additions & 144 deletions
Original file line numberDiff line numberDiff line change
@@ -1,160 +1,51 @@
1-
<?xml version="1.0" encoding="utf-8"?>
2-
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
33
<PropertyGroup>
4-
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
5-
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
6-
<ProductVersion>
7-
</ProductVersion>
8-
<SchemaVersion>
9-
</SchemaVersion>
10-
<ProjectGuid>{7C2EF610-BCA0-4D1F-898A-DE9908E4970C}</ProjectGuid>
11-
<OutputType>Library</OutputType>
12-
<RootNamespace>NHibernate.Test.VisualBasic</RootNamespace>
13-
<AssemblyName>NHibernate.Test.VisualBasic</AssemblyName>
14-
<FileAlignment>512</FileAlignment>
15-
<MyType>Windows</MyType>
16-
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
17-
<TargetFrameworkProfile />
18-
<StartAction>Program</StartAction>
19-
<StartProgram>$(MSBuildProjectDirectory)\..\..\Tools\nunit\nunit-x86.exe</StartProgram>
20-
<StartArguments>NHibernate.Test.VisualBasic.dll</StartArguments>
4+
<TargetFramework>net461</TargetFramework>
5+
<GenerateAssemblyTitleAttribute>False</GenerateAssemblyTitleAttribute>
6+
<GenerateAssemblyProductAttribute>False</GenerateAssemblyProductAttribute>
7+
<GenerateAssemblyCompanyAttribute>False</GenerateAssemblyCompanyAttribute>
8+
<GenerateAssemblyDescriptionAttribute>False</GenerateAssemblyDescriptionAttribute>
9+
<GenerateAssemblyVersionAttribute>False</GenerateAssemblyVersionAttribute>
10+
<GenerateAssemblyFileVersionAttribute>False</GenerateAssemblyFileVersionAttribute>
11+
<GenerateAssemblyInformationalVersionAttribute>False</GenerateAssemblyInformationalVersionAttribute>
12+
<NoWarn>$(NoWarn);3001;3002;3003;3005</NoWarn>
2113
</PropertyGroup>
22-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
23-
<DebugSymbols>true</DebugSymbols>
24-
<DebugType>full</DebugType>
25-
<DefineDebug>true</DefineDebug>
26-
<DefineTrace>true</DefineTrace>
27-
<OutputPath>bin\Debug\</OutputPath>
28-
<DocumentationFile>NHibernate.Test.VisualBasic.xml</DocumentationFile>
29-
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
30-
<Prefer32Bit>false</Prefer32Bit>
31-
</PropertyGroup>
32-
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
33-
<DebugType>pdbonly</DebugType>
34-
<DefineDebug>false</DefineDebug>
35-
<DefineTrace>true</DefineTrace>
36-
<Optimize>true</Optimize>
37-
<OutputPath>bin\Release\</OutputPath>
38-
<DocumentationFile>NHibernate.Test.VisualBasic.xml</DocumentationFile>
39-
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
40-
<Prefer32Bit>false</Prefer32Bit>
41-
</PropertyGroup>
42-
<PropertyGroup>
43-
<OptionExplicit>On</OptionExplicit>
44-
</PropertyGroup>
45-
<PropertyGroup>
46-
<OptionCompare>Binary</OptionCompare>
47-
</PropertyGroup>
48-
<PropertyGroup>
49-
<OptionStrict>Off</OptionStrict>
50-
</PropertyGroup>
51-
<PropertyGroup>
52-
<OptionInfer>On</OptionInfer>
53-
</PropertyGroup>
54-
<ItemGroup>
55-
<Reference Include="nunit.framework, Version=3.6.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
56-
<HintPath>..\packages\NUnit.3.6.0\lib\net45\nunit.framework.dll</HintPath>
57-
</Reference>
58-
<Reference Include="System" />
59-
<Reference Include="System.Data" />
60-
<Reference Include="System.Xml" />
61-
<Reference Include="System.Core" />
62-
<Reference Include="System.Xml.Linq" />
63-
<Reference Include="System.Data.DataSetExtensions" />
64-
</ItemGroup>
65-
<ItemGroup>
66-
<Import Include="Microsoft.VisualBasic" />
67-
<Import Include="System" />
68-
<Import Include="System.Collections" />
69-
<Import Include="System.Collections.Generic" />
70-
<Import Include="System.Data" />
71-
<Import Include="System.Diagnostics" />
72-
<Import Include="System.Linq" />
73-
<Import Include="System.Xml.Linq" />
74-
</ItemGroup>
14+
7515
<ItemGroup>
76-
<Compile Include="..\SharedAssemblyInfo.vb">
77-
<Link>SharedAssemblyInfo.vb</Link>
78-
</Compile>
79-
<Compile Include="AssemblyInfo.vb" />
80-
<Compile Include="Issues\NH2966\Client.vb" />
81-
<Compile Include="Issues\NH2966\Fixture.vb" />
82-
<Compile Include="Issues\NH3302\Entity.vb" />
83-
<Compile Include="Issues\NH3302\Fixture.vb" />
84-
<Compile Include="Issues\NH2963\Entity.vb" />
85-
<Compile Include="Issues\NH2963\Fixture.vb" />
86-
<Compile Include="Issues\NH0000\Entity.vb" />
87-
<Compile Include="Issues\NH0000\Fixture.vb" />
88-
<Compile Include="Issues\IssueTestCase.vb" />
89-
<Compile Include="Issues\NH2545\Fixture.vb" />
90-
<Compile Include="Issues\NH2545\Entity.vb" />
91-
<Compile Include="Issues\NH2966\Order.vb" />
92-
<Compile Include="My Project\AssemblyInfo.vb" />
93-
<Compile Include="My Project\Application.Designer.vb">
94-
<AutoGen>True</AutoGen>
95-
<DependentUpon>Application.myapp</DependentUpon>
96-
</Compile>
97-
<Compile Include="My Project\Resources.Designer.vb">
98-
<AutoGen>True</AutoGen>
99-
<DesignTime>True</DesignTime>
100-
<DependentUpon>Resources.resx</DependentUpon>
101-
</Compile>
102-
<Compile Include="My Project\Settings.Designer.vb">
103-
<AutoGen>True</AutoGen>
104-
<DependentUpon>Settings.settings</DependentUpon>
105-
<DesignTimeSharedInput>True</DesignTimeSharedInput>
106-
</Compile>
16+
<Compile Remove="Issues\NH3302\**" /> <!--"Like" not supported in new dotnet compiler, not implemented anyways in .net framework-->
10717
</ItemGroup>
18+
10819
<ItemGroup>
109-
<EmbeddedResource Include="My Project\Resources.resx">
110-
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
111-
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
112-
<CustomToolNamespace>My.Resources</CustomToolNamespace>
113-
<SubType>Designer</SubType>
114-
</EmbeddedResource>
20+
<None Remove="**\*.hbm.xml" />
11521
</ItemGroup>
22+
11623
<ItemGroup>
117-
<None Include="..\NHibernate.Test\App.config">
118-
<Link>App.config</Link>
119-
<SubType>Designer</SubType>
120-
</None>
121-
<None Include="My Project\Application.myapp">
122-
<Generator>MyApplicationCodeGenerator</Generator>
123-
<LastGenOutput>Application.Designer.vb</LastGenOutput>
124-
</None>
125-
<None Include="My Project\Settings.settings">
126-
<Generator>SettingsSingleFileGenerator</Generator>
127-
<CustomToolNamespace>My</CustomToolNamespace>
128-
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
129-
</None>
130-
<None Include="packages.config" />
24+
<EmbeddedResource Include="**\*.hbm.xml" />
13125
</ItemGroup>
26+
13227
<ItemGroup>
133-
<ProjectReference Include="..\NHibernate.Test\NHibernate.Test.csproj">
134-
<Project>{7AEE5B37-C552-4E59-9B6F-88755BCB5070}</Project>
135-
<Name>NHibernate.Test</Name>
136-
</ProjectReference>
137-
<ProjectReference Include="..\NHibernate\NHibernate.csproj">
138-
<Project>{5909BFE7-93CF-4E5F-BE22-6293368AF01D}</Project>
139-
<Name>NHibernate</Name>
140-
</ProjectReference>
28+
<Compile Include="..\SharedAssemblyInfo.vb" Link="SharedAssemblyInfo.vb" />
14129
</ItemGroup>
30+
14231
<ItemGroup>
143-
<EmbeddedResource Include="Issues\NH2545\Issues.NH2545.Mappings.hbm.xml" />
32+
<None Include="..\NHibernate.Test\App.config" Link="App.config" />
14433
</ItemGroup>
34+
14535
<ItemGroup>
146-
<EmbeddedResource Include="Issues\NH0000\Issues.NH0000.Mappings.hbm.xml" />
36+
<PackageReference Include="Antlr3.Runtime" Version="3.5.1" />
37+
<PackageReference Include="Iesi.Collections" Version="4.0.2" />
38+
<PackageReference Include="log4net" Version="2.0.8" />
39+
<PackageReference Include="nunit" Version="3.6.0" />
40+
<PackageReference Include="Remotion.Linq" Version="2.1.2" />
41+
<PackageReference Include="Remotion.Linq.EagerFetching" Version="2.1.0" />
42+
<PackageReference Include="System.Linq.Dynamic.Core" Version="1.0.7.6" />
43+
<PackageReference Include="System.Threading.Tasks.Extensions" Version="4.3.0" />
14744
</ItemGroup>
45+
14846
<ItemGroup>
149-
<EmbeddedResource Include="Issues\NH2966\Issues.NH2966.Mappings.hbm.xml" />
150-
<EmbeddedResource Include="Issues\NH3302\Issues.NH3302.Mappings.hbm.xml" />
47+
<ProjectReference Include="..\NHibernate\NHibernate.csproj" />
48+
<ProjectReference Include="..\NHibernate.Test\NHibernate.Test.csproj" ExcludeAssets="ContentFiles" />
15149
</ItemGroup>
152-
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
153-
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
154-
Other similar extension points exist, see Microsoft.Common.targets.
155-
<Target Name="BeforeBuild">
156-
</Target>
157-
<Target Name="AfterBuild">
158-
</Target>
159-
-->
160-
</Project>
50+
51+
</Project>

src/NHibernate.Test.VisualBasic/packages.config

Lines changed: 0 additions & 4 deletions
This file was deleted.

src/NHibernate/Linq/Functions/CompareGenerator.cs

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,17 @@ internal static bool IsCompareMethod(MethodInfo methodInfo)
4444
return true;
4545

4646
// This is .Net 4 only, and in the System.Data.Services assembly, which we don't depend directly on.
47-
return methodInfo != null && methodInfo.Name == "Compare" &&
47+
if (methodInfo != null && methodInfo.Name == "Compare" &&
4848
methodInfo.DeclaringType != null &&
49-
methodInfo.DeclaringType.FullName == "System.Data.Services.Providers.DataServiceProviderMethods";
49+
methodInfo.DeclaringType.FullName == "System.Data.Services.Providers.DataServiceProviderMethods")
50+
return true;
51+
52+
if (methodInfo != null && methodInfo.Name == "CompareString" &&
53+
methodInfo.DeclaringType != null &&
54+
(methodInfo.DeclaringType.FullName == "Microsoft.VisualBasic.CompilerServices.Operators" || methodInfo.DeclaringType.FullName == "Microsoft.VisualBasic.CompilerServices.EmbeddedOperators"))
55+
return true;
56+
57+
return false;
5058
}
5159

5260

0 commit comments

Comments
 (0)