Skip to content

Commit

Permalink
[C#] 0.3.0.
Browse files Browse the repository at this point in the history
  • Loading branch information
Konard committed Dec 20, 2020
1 parent 77528ba commit f9be036
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/CD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
submodules: true
- name: Test
run: dotnet test -c Release -f netcoreapp3.1
run: dotnet test -c Release -f net5
- name: Generate PDF with CSharp code
if: github.event_name == 'push'
run: |
Expand Down
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -329,9 +329,6 @@ ASALocalRun/
# MFractors (Xamarin productivity tool) working folder
.mfractor/

# GitHub refuses chages to .github folder at the moment
.github/

# Code translation
*.AssemblyInfo.cpp
*.AssemblyInfo.h
Expand Down
2 changes: 1 addition & 1 deletion CSharpToCppTranslator
10 changes: 7 additions & 3 deletions csharp/Platform.Ranges.Tests/Platform.Ranges.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net472;netcoreapp2.1;netcoreapp3.1</TargetFrameworks>
<TargetFrameworks>net472;netcoreapp2.1;netcoreapp3.1;net5</TargetFrameworks>
<IsPackable>false</IsPackable>
<LangVersion>latest</LangVersion>
</PropertyGroup>
Expand All @@ -21,8 +21,12 @@
<ProjectReference Include="..\Platform.Ranges\Platform.Ranges.csproj" />
</ItemGroup>

<Target Name="CSharpToCppTranslation" AfterTargets="PostBuildEvent" Condition="'$(OS)' == 'Windows_NT' AND $(TargetFramework) == 'netcoreapp3.1'">
<Exec Command="..\..\CSharpToCppTranslator\bin\$(Configuration)\netcoreapp3.0\CSharpToCppTranslator.exe $(ProjectDir) $(SolutionDir)cpp\$(ProjectName)\ .cs .cpp"></Exec>
<Target Name="CSharpToCppTranslation" AfterTargets="PostBuildEvent" Condition="'$(OS)' == 'Windows_NT' AND $(TargetFramework) == 'net5'">
<Exec Command="..\..\CSharpToCppTranslator\bin\$(Configuration)\net5\CSharpToCppTranslator.exe $(ProjectDir) $(SolutionDir)cpp\$(ProjectName)\ .cs .cpp"></Exec>
</Target>

<Target Name="CSharpToCppTranslation" AfterTargets="PostBuildEvent" Condition="'$(OS)' == 'Unix' AND $(TargetFramework) == 'net5'">
<Exec Command="../../CSharpToCppTranslator/bin/$(Configuration)/net5/CSharpToCppTranslator $(ProjectDir) $(SolutionDir)cpp/$(ProjectName)/ .cs .cpp"></Exec>
</Target>

</Project>
15 changes: 9 additions & 6 deletions csharp/Platform.Ranges/Platform.Ranges.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
<Description>LinksPlatform's Platform.Ranges Class Library</Description>
<Copyright>Konstantin Diachenko</Copyright>
<AssemblyTitle>Platform.Ranges</AssemblyTitle>
<VersionPrefix>0.2.0</VersionPrefix>
<VersionPrefix>0.3.0</VersionPrefix>
<Authors>Konstantin Diachenko</Authors>
<TargetFrameworks>net472;netstandard2.0;netstandard2.1</TargetFrameworks>
<TargetFrameworks>net472;netstandard2.0;netstandard2.1;net5</TargetFrameworks>
<AssemblyName>Platform.Ranges</AssemblyName>
<PackageId>Platform.Ranges</PackageId>
<PackageTags>LinksPlatform;Ranges;Range;RangeExtensions;EnsureExtensions</PackageTags>
Expand All @@ -24,8 +24,7 @@
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
<LangVersion>latest</LangVersion>
<PackageReleaseNotes>Lowest supported version of .NET Framework is now 4.7.2.
Platform.Exceptions dependency updated from 0.2.1 to 0.3.0.</PackageReleaseNotes>
<PackageReleaseNotes>Added support for .NET 5.</PackageReleaseNotes>
</PropertyGroup>

<ItemGroup Condition="$(TargetFramework.StartsWith('net4')) AND '$(MSBuildRuntimeType)' == 'Core' AND '$(OS)' != 'Windows_NT'">
Expand All @@ -40,8 +39,12 @@ Platform.Exceptions dependency updated from 0.2.1 to 0.3.0.</PackageReleaseNotes
<PackageReference Include="Platform.Exceptions" Version="0.4.0" />
</ItemGroup>

<Target Name="CSharpToCppTranslation" AfterTargets="PostBuildEvent" Condition="'$(OS)' == 'Windows_NT' AND $(TargetFramework) == 'netstandard2.1'">
<Exec Command="..\..\CSharpToCppTranslator\bin\$(Configuration)\netcoreapp3.0\CSharpToCppTranslator.exe $(ProjectDir) $(SolutionDir)cpp\$(ProjectName)\"></Exec>
<Target Name="CSharpToCppTranslation" AfterTargets="PostBuildEvent" Condition="'$(OS)' == 'Windows_NT' AND $(TargetFramework) == 'net5'">
<Exec Command="..\..\CSharpToCppTranslator\bin\$(Configuration)\net5\CSharpToCppTranslator.exe $(ProjectDir) $(SolutionDir)cpp\$(ProjectName)\"></Exec>
</Target>

<Target Name="CSharpToCppTranslation" AfterTargets="PostBuildEvent" Condition="'$(OS)' == 'Unix' AND $(TargetFramework) == 'net5'">
<Exec Command="../../CSharpToCppTranslator/bin/$(Configuration)/net5/CSharpToCppTranslator $(ProjectDir) $(SolutionDir)cpp/$(ProjectName)/"></Exec>
</Target>

</Project>
6 changes: 3 additions & 3 deletions csharp/Platform.Ranges/Range[T].cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
namespace Platform.Ranges
{
/// <summary>
/// <para>Represents a range between minumum and maximum values.</para>
/// <para>Represents a range between minimum and maximum values.</para>
/// <para>Представляет диапазон между минимальным и максимальным значениями.</para>
/// </summary>
/// <remarks>
/// <para>Based on <a href="http://stackoverflow.com/questions/5343006/is-there-a-c-sharp-type-for-representing-an-integer-range">the question at StackOveflow</a>.</para>
/// <para>Основано на <a href="http://stackoverflow.com/questions/5343006/is-there-a-c-sharp-type-for-representing-an-integer-range">вопросе в StackOveflow</a>.</para>
/// <para>Based on <a href="http://stackoverflow.com/questions/5343006/is-there-a-c-sharp-type-for-representing-an-integer-range">the question at StackOverflow</a>.</para>
/// <para>Основано на <a href="http://stackoverflow.com/questions/5343006/is-there-a-c-sharp-type-for-representing-an-integer-range">вопросе в StackOverflow</a>.</para>
/// </remarks>
public struct Range<T> : IEquatable<Range<T>>
{
Expand Down

0 comments on commit f9be036

Please sign in to comment.