本文整理汇总了C#中SimpleForth.Forth.PushUInt64方法的典型用法代码示例。如果您正苦于以下问题:C# Forth.PushUInt64方法的具体用法?C# Forth.PushUInt64怎么用?C# Forth.PushUInt64使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SimpleForth.Forth
的用法示例。
在下文中一共展示了Forth.PushUInt64方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: And
public static void And(Forth f)
{
ulong b = f.PopUInt64();
ulong a = f.PopUInt64();
f.PushUInt64(a & b);
}
示例2: Xor
public static void Xor(Forth f)
{
ulong b = f.PopUInt64();
ulong a = f.PopUInt64();
f.PushUInt64(a ^ b);
}
示例3: UnsignedDivide
public static void UnsignedDivide(Forth f)
{
ulong b = f.PopUInt64();
ulong a = f.PopUInt64();
f.PushUInt64(unchecked(a / b));
}
示例4: UnsignedModulus
public static void UnsignedModulus(Forth f)
{
ulong b = f.PopUInt64();
ulong a = f.PopUInt64();
f.PushUInt64(unchecked(a % b));
}
示例5: Invert
public static void Invert(Forth f)
{
ulong u = f.PopUInt64();
f.PushUInt64(~u);
}
示例6: UnsignedMax
public static void UnsignedMax(Forth f)
{
ulong b = f.PopUInt64();
ulong a = f.PopUInt64();
f.PushUInt64((a > b) ? a : b);
}
示例7: RShift
public static void RShift(Forth f)
{
ulong shiftCount = f.PopUInt64();
ulong value = f.PopUInt64();
if (shiftCount > 63)
{
f.PushUInt64(0ul);
}
else
{
f.PushUInt64(value >> (int)shiftCount);
}
}
示例8: ZeroExtendInt32
public static void ZeroExtendInt32(Forth f)
{
ulong value = f.PopUInt64();
value &= 0xFFFFFFFFul;
f.PushUInt64(value);
}
示例9: SignExtendInt32
public static void SignExtendInt32(Forth f)
{
ulong value = f.PopUInt64();
if ((value & 0x80000000ul) != 0) value |= 0xFFFFFFFF80000000ul;
else value &= 0x7FFFFFFFul;
f.PushUInt64(value);
}