예제 #1
0
        public static void SByte32()
        {
            bool     result = true;
            Random64 x      = new Random64(47);

            for (int i = 0; i < Tests.SByte32.NUM_TESTS; i++)
            {
                bool32  b = x.NextBool32();
                sbyte32 a = maxmath.negate(Tests.SByte32.TestData_LHS[i], b);

                result &= maxmath.all(a == maxmath.select(Tests.SByte32.TestData_LHS[i], -Tests.SByte32.TestData_LHS[i], b));
            }

            Assert.AreEqual(true, result);
        }