Change c# projects to dotnet framework version 4.5 due to dependencies not being available for newer versions

This commit is contained in:
Jan 2019-10-27 13:31:50 +01:00
parent 5245f40307
commit 146c992dd5
3 changed files with 10 additions and 1 deletions

View File

@ -20,6 +20,7 @@ function ZoneCodeGenerator:project()
location "%{wks.location}/src/%{prj.name}" location "%{wks.location}/src/%{prj.name}"
kind "ConsoleApp" kind "ConsoleApp"
language "C#" language "C#"
dotnetframework "4.5"
namespace "ZoneCodeGenerator" namespace "ZoneCodeGenerator"
files { files {

View File

@ -1,4 +1,5 @@
using System.Collections.Generic; using System;
using System.Collections.Generic;
namespace ZoneCodeGenerator.Utils namespace ZoneCodeGenerator.Utils
{ {
@ -9,5 +10,11 @@ namespace ZoneCodeGenerator.Utils
m1 = keyValuePair.Key; m1 = keyValuePair.Key;
m2 = keyValuePair.Value; m2 = keyValuePair.Value;
} }
public static void Deconstruct<T1, T2>(this Tuple<T1, T2> keyValuePair, out T1 m1, out T2 m2)
{
m1 = keyValuePair.Item1;
m2 = keyValuePair.Item2;
}
} }
} }

View File

@ -20,6 +20,7 @@ function ZoneCodeGeneratorTests:project()
location "%{wks.location}/test/%{prj.name}" location "%{wks.location}/test/%{prj.name}"
kind "SharedLib" kind "SharedLib"
language "C#" language "C#"
dotnetframework "4.5"
files { files {
path.join(folder, "ZoneCodeGeneratorTests/**.cs") path.join(folder, "ZoneCodeGeneratorTests/**.cs")