This repository has been archived by the owner on Aug 2, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 344
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #764 from benaadams/dec64
Initial interface for Dec64
- Loading branch information
Showing
8 changed files
with
721 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<PropertyGroup> | ||
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">14.0</VisualStudioVersion> | ||
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath> | ||
</PropertyGroup> | ||
|
||
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.Props" Condition="'$(VSToolsPath)' != ''" /> | ||
<PropertyGroup Label="Globals"> | ||
<ProjectGuid>329b9be5-3f34-42a2-9e8c-d7bdd6b1ee55</ProjectGuid> | ||
<RootNamespace>System.Numerics</RootNamespace> | ||
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)'=='' ">.\obj</BaseIntermediateOutputPath> | ||
<OutputPath Condition="'$(OutputPath)'=='' ">.\bin\</OutputPath> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup> | ||
<SchemaVersion>2.0</SchemaVersion> | ||
</PropertyGroup> | ||
<Import Project="$(VSToolsPath)\DotNet\Microsoft.DotNet.targets" Condition="'$(VSToolsPath)' != ''" /> | ||
</Project> |
52 changes: 52 additions & 0 deletions
52
src/System.Numerics.Dec64/System/Numerics/Dec64.Comparable.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
|
||
namespace System.Numerics | ||
{ | ||
public partial struct Dec64 : IComparable, IFormattable, IComparable<Dec64>, IEquatable<Dec64> | ||
{ | ||
public bool Equals(Dec64 other) => _value == other._value; | ||
|
||
public bool Equals(long other) | ||
{ | ||
return default(bool); | ||
} | ||
|
||
public override bool Equals(object obj) | ||
{ | ||
return default(bool); | ||
} | ||
|
||
public bool Equals(ulong other) | ||
{ | ||
return default(bool); | ||
} | ||
|
||
public static int Compare(Dec64 left, Dec64 right) | ||
{ | ||
return default(int); | ||
} | ||
|
||
public int CompareTo(long other) | ||
{ | ||
return default(int); | ||
} | ||
|
||
public int CompareTo(Dec64 other) | ||
{ | ||
|
||
return default(int); | ||
} | ||
|
||
public int CompareTo(ulong other) | ||
{ | ||
return default(int); | ||
} | ||
|
||
int System.IComparable.CompareTo(object obj) | ||
{ | ||
return default(int); | ||
} | ||
} | ||
} |
64 changes: 64 additions & 0 deletions
64
src/System.Numerics.Dec64/System/Numerics/Dec64.Formattable.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
|
||
namespace System.Numerics | ||
{ | ||
public partial struct Dec64 : IComparable, IFormattable, IComparable<Dec64>, IEquatable<Dec64> | ||
{ | ||
public static bool TryParse(string value, System.Globalization.NumberStyles style, System.IFormatProvider provider, out Dec64 result) | ||
{ | ||
result = default(Dec64); return default(bool); | ||
} | ||
|
||
public static bool TryParse(string value, out Dec64 result) | ||
{ | ||
result = default(Dec64); return default(bool); | ||
} | ||
|
||
public static Dec64 Parse(string value) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Parse(string value, System.Globalization.NumberStyles style) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Parse(string value, System.Globalization.NumberStyles style, System.IFormatProvider provider) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Parse(string value, System.IFormatProvider provider) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public byte[] ToByteArray() | ||
{ | ||
return default(byte[]); | ||
} | ||
|
||
public override string ToString() | ||
{ | ||
return default(string); | ||
} | ||
|
||
public string ToString(System.IFormatProvider provider) | ||
{ | ||
return default(string); | ||
} | ||
|
||
public string ToString(string format) | ||
{ | ||
return default(string); | ||
} | ||
|
||
public string ToString(string format, System.IFormatProvider provider) | ||
{ | ||
return default(string); | ||
} | ||
} | ||
} |
129 changes: 129 additions & 0 deletions
129
src/System.Numerics.Dec64/System/Numerics/Dec64.Maths.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,129 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
|
||
namespace System.Numerics | ||
{ | ||
public partial struct Dec64 : IComparable, IFormattable, IComparable<Dec64>, IEquatable<Dec64> | ||
{ | ||
public bool IsEven | ||
{ | ||
get | ||
{ | ||
return default(bool); | ||
} | ||
} | ||
|
||
public bool IsOne | ||
{ | ||
get | ||
{ | ||
return default(bool); | ||
} | ||
} | ||
|
||
public bool IsPowerOfTwo | ||
{ | ||
get | ||
{ | ||
return default(bool); | ||
} | ||
} | ||
|
||
public bool IsZero | ||
{ | ||
get | ||
{ | ||
return default(bool); | ||
} | ||
} | ||
|
||
public int Sign | ||
{ | ||
get | ||
{ | ||
return default(int); | ||
} | ||
} | ||
|
||
public static Dec64 Abs(Dec64 value) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Add(Dec64 left, Dec64 right) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Divide(Dec64 dividend, Dec64 divisor) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 DivRem(Dec64 dividend, Dec64 divisor, out Dec64 remainder) | ||
{ | ||
remainder = default(Dec64); return default(Dec64); | ||
} | ||
|
||
public static Dec64 GreatestCommonDivisor(Dec64 left, Dec64 right) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static double Log(Dec64 value) | ||
{ | ||
return default(double); | ||
} | ||
|
||
public static double Log(Dec64 value, double baseValue) | ||
{ | ||
return default(double); | ||
} | ||
|
||
public static double Log10(Dec64 value) | ||
{ | ||
return default(double); | ||
} | ||
|
||
public static Dec64 Max(Dec64 left, Dec64 right) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Min(Dec64 left, Dec64 right) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 ModPow(Dec64 value, Dec64 exponent, Dec64 modulus) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Multiply(Dec64 left, Dec64 right) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Negate(Dec64 value) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Pow(Dec64 value, int exponent) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Remainder(Dec64 dividend, Dec64 divisor) | ||
{ | ||
return default(Dec64); | ||
} | ||
|
||
public static Dec64 Subtract(Dec64 left, Dec64 right) | ||
{ | ||
return default(Dec64); | ||
} | ||
} | ||
} |
Oops, something went wrong.