Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
System.Decimal.DecCalc Struct Reference

Classes

struct  Buf12
 
struct  Buf16
 
struct  Buf24
 
struct  Buf28
 
struct  PowerOvfl
 

Static Package Functions

static unsafe void DecAddSub (ref DecCalc d1, ref DecCalc d2, bool sign)
 
static long VarCyFromDec (ref DecCalc pdecIn)
 
static int VarDecCmp (in decimal d1, in decimal d2)
 
static unsafe void VarDecMul (ref DecCalc d1, ref DecCalc d2)
 
static void VarDecFromR4 (float input, out DecCalc result)
 
static void VarDecFromR8 (double input, out DecCalc result)
 
static float VarR4FromDec (in decimal value)
 
static double VarR8FromDec (in decimal value)
 
static int GetHashCode (in decimal d)
 
static unsafe void VarDecDiv (ref DecCalc d1, ref DecCalc d2)
 
static void VarDecMod (ref DecCalc d1, ref DecCalc d2)
 
static void InternalRound (ref DecCalc d, uint scale, MidpointRounding mode)
 
static uint DecDivMod1E9 (ref DecCalc value)
 

Properties

uint High [get, set]
 
uint Low [get, set]
 
uint Mid [get, set]
 
bool IsNegative [get]
 
int Scale [get]
 
ulong Low64 [get, set]
 

Static Private Member Functions

static unsafe uint GetExponent (float f)
 
static unsafe uint GetExponent (double d)
 
static ulong UInt32x32To64 (uint a, uint b)
 
static void UInt64x64To128 (ulong a, ulong b, ref DecCalc result)
 
static uint Div96By32 (ref Buf12 bufNum, uint den)
 
static bool Div96ByConst (ref ulong high64, ref uint low, uint pow)
 
static void Unscale (ref uint low, ref ulong high64, ref int scale)
 
static uint Div96By64 (ref Buf12 bufNum, ulong den)
 
static uint Div128By96 (ref Buf16 bufNum, ref Buf12 bufDen)
 
static uint IncreaseScale (ref Buf12 bufNum, uint power)
 
static void IncreaseScale64 (ref Buf12 bufNum, uint power)
 
static unsafe int ScaleResult (Buf24 *bufRes, uint hiRes, int scale)
 
static unsafe uint DivByConst (uint *result, uint hiRes, out uint quotient, out uint remainder, uint power)
 
static int OverflowUnscale (ref Buf12 bufQuo, int scale, bool sticky)
 
static int SearchScale (ref Buf12 bufQuo, int scale)
 
static bool Add32To96 (ref Buf12 bufNum, uint value)
 
static int VarDecCmpSub (in decimal d1, in decimal d2)
 
static unsafe void VarDecModFull (ref DecCalc d1, ref DecCalc d2, int scale)
 

Private Attributes

uint uflags
 
uint uhi
 
uint ulo
 
uint umid
 
ulong ulomid
 

Static Private Attributes

static readonly uint[] s_powers10 = new uint[10] { 1u, 10u, 100u, 1000u, 10000u, 100000u, 1000000u, 10000000u, 100000000u, 1000000000u }
 
static readonly ulong[] s_ulongPowers10
 
static readonly double[] s_doublePowers10
 
static readonly PowerOvfl[] PowerOvflValues
 

Detailed Description

Definition at line 20 of file Decimal.cs.


The documentation for this struct was generated from the following file: