Lines Matching refs:fd

614     FixedDecimal fd = df->getFixedDecimal(44, status);  in TestFixedDecimal()  local
616 ASSERT_EQUAL(44, fd.source); in TestFixedDecimal()
617 ASSERT_EQUAL(0, fd.visibleDecimalDigitCount); in TestFixedDecimal()
618 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
620 fd = df->getFixedDecimal(-44, status); in TestFixedDecimal()
622 ASSERT_EQUAL(44, fd.source); in TestFixedDecimal()
623 ASSERT_EQUAL(0, fd.visibleDecimalDigitCount); in TestFixedDecimal()
624 ASSERT_EQUAL(TRUE, fd.isNegative); in TestFixedDecimal()
628 fd = df->getFixedDecimal(123.456, status); in TestFixedDecimal()
630 ASSERT_EQUAL(3, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
631 ASSERT_EQUAL(456, fd.decimalDigits); // f in TestFixedDecimal()
632 ASSERT_EQUAL(456, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
633 ASSERT_EQUAL(123, fd.intValue); // i in TestFixedDecimal()
634 ASSERT_EQUAL(123.456, fd.source); // n in TestFixedDecimal()
635 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
636 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
638 fd = df->getFixedDecimal(-123.456, status); in TestFixedDecimal()
640 ASSERT_EQUAL(3, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
641 ASSERT_EQUAL(456, fd.decimalDigits); // f in TestFixedDecimal()
642 ASSERT_EQUAL(456, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
643 ASSERT_EQUAL(123, fd.intValue); // i in TestFixedDecimal()
644 ASSERT_EQUAL(123.456, fd.source); // n in TestFixedDecimal()
645 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
646 ASSERT_EQUAL(TRUE, fd.isNegative); in TestFixedDecimal()
650 fd = df->getFixedDecimal(123.456, status); in TestFixedDecimal()
652 ASSERT_EQUAL(3, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
653 ASSERT_EQUAL(456, fd.decimalDigits); // f in TestFixedDecimal()
654 ASSERT_EQUAL(456, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
655 ASSERT_EQUAL(23, fd.intValue); // i in TestFixedDecimal()
656 ASSERT_EQUAL(23.456, fd.source); // n in TestFixedDecimal()
657 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
658 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
660 fd = df->getFixedDecimal(-123.456, status); in TestFixedDecimal()
662 ASSERT_EQUAL(3, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
663 ASSERT_EQUAL(456, fd.decimalDigits); // f in TestFixedDecimal()
664 ASSERT_EQUAL(456, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
665 ASSERT_EQUAL(23, fd.intValue); // i in TestFixedDecimal()
666 ASSERT_EQUAL(23.456, fd.source); // n in TestFixedDecimal()
667 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
668 ASSERT_EQUAL(TRUE, fd.isNegative); in TestFixedDecimal()
673 fd = df->getFixedDecimal(123.456, status); in TestFixedDecimal()
675 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
676 ASSERT_EQUAL(46, fd.decimalDigits); // f in TestFixedDecimal()
677 ASSERT_EQUAL(46, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
678 ASSERT_EQUAL(123, fd.intValue); // i in TestFixedDecimal()
679 ASSERT_EQUAL(123.46, fd.source); // n in TestFixedDecimal()
680 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
681 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
683 fd = df->getFixedDecimal(-123.456, status); in TestFixedDecimal()
685 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
686 ASSERT_EQUAL(46, fd.decimalDigits); // f in TestFixedDecimal()
687 ASSERT_EQUAL(46, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
688 ASSERT_EQUAL(123, fd.intValue); // i in TestFixedDecimal()
689 ASSERT_EQUAL(123.46, fd.source); // n in TestFixedDecimal()
690 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
691 ASSERT_EQUAL(TRUE, fd.isNegative); in TestFixedDecimal()
697 fd = df->getFixedDecimal(30.0, status); in TestFixedDecimal()
699 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
700 ASSERT_EQUAL(20, fd.decimalDigits); // f in TestFixedDecimal()
701 ASSERT_EQUAL(2, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
702 ASSERT_EQUAL(29, fd.intValue); // i in TestFixedDecimal()
703 ASSERT_EQUAL(29.2, fd.source); // n in TestFixedDecimal()
704 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
705 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
707 fd = df->getFixedDecimal(-30.0, status); in TestFixedDecimal()
709 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); // v in TestFixedDecimal()
710 ASSERT_EQUAL(20, fd.decimalDigits); // f in TestFixedDecimal()
711 ASSERT_EQUAL(2, fd.decimalDigitsWithoutTrailingZeros); // t in TestFixedDecimal()
712 ASSERT_EQUAL(29, fd.intValue); // i in TestFixedDecimal()
713 ASSERT_EQUAL(29.2, fd.source); // n in TestFixedDecimal()
714 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
715 ASSERT_EQUAL(TRUE, fd.isNegative); in TestFixedDecimal()
719 fd = df->getFixedDecimal(123.456, status); in TestFixedDecimal()
721 ASSERT_EQUAL(0, fd.visibleDecimalDigitCount); in TestFixedDecimal()
722 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
723 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
724 ASSERT_EQUAL(123, fd.intValue); in TestFixedDecimal()
725 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
726 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
730 fd = df->getFixedDecimal(123.01, status); in TestFixedDecimal()
732 ASSERT_EQUAL(1, fd.visibleDecimalDigitCount); in TestFixedDecimal()
733 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
734 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
735 ASSERT_EQUAL(123, fd.intValue); in TestFixedDecimal()
736 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
737 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
741 fd = df->getFixedDecimal(123.06, status); in TestFixedDecimal()
743 ASSERT_EQUAL(1, fd.visibleDecimalDigitCount); in TestFixedDecimal()
744 ASSERT_EQUAL(1, fd.decimalDigits); in TestFixedDecimal()
745 ASSERT_EQUAL(1, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
746 ASSERT_EQUAL(123, fd.intValue); in TestFixedDecimal()
747 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
748 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
752 fd = df->getFixedDecimal(123, status); in TestFixedDecimal()
754 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
755 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
756 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
757 ASSERT_EQUAL(123, fd.intValue); in TestFixedDecimal()
758 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
759 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
763 fd = df->getFixedDecimal(1.23, status); in TestFixedDecimal()
765 ASSERT_EQUAL(4, fd.visibleDecimalDigitCount); in TestFixedDecimal()
766 ASSERT_EQUAL(2300, fd.decimalDigits); in TestFixedDecimal()
767 ASSERT_EQUAL(23, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
768 ASSERT_EQUAL(1, fd.intValue); in TestFixedDecimal()
769 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
770 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
772 fd = df->getFixedDecimal(uprv_getInfinity(), status); in TestFixedDecimal()
774 ASSERT_EQUAL(TRUE, fd.isNanOrInfinity); in TestFixedDecimal()
775 fd = df->getFixedDecimal(0.0, status); in TestFixedDecimal()
776 ASSERT_EQUAL(FALSE, fd.isNanOrInfinity); in TestFixedDecimal()
777 fd = df->getFixedDecimal(uprv_getNaN(), status); in TestFixedDecimal()
778 ASSERT_EQUAL(TRUE, fd.isNanOrInfinity); in TestFixedDecimal()
789 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
791 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
792 ASSERT_EQUAL(34, fd.decimalDigits); in TestFixedDecimal()
793 ASSERT_EQUAL(34, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
794 ASSERT_EQUAL(12, fd.intValue); in TestFixedDecimal()
795 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
796 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
800 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
802 ASSERT_EQUAL(22, fd.visibleDecimalDigitCount); in TestFixedDecimal()
803 ASSERT_EQUAL(345678901234567890LL, fd.decimalDigits); in TestFixedDecimal()
804 ASSERT_EQUAL(34567890123456789LL, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
805 ASSERT_EQUAL(12, fd.intValue); in TestFixedDecimal()
806 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
807 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
812 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
814 ASSERT_EQUAL(22, fd.visibleDecimalDigitCount); in TestFixedDecimal()
815 ASSERT_EQUAL(123456789012345678LL, fd.decimalDigits); in TestFixedDecimal()
816 ASSERT_EQUAL(123456789012345678LL, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
817 ASSERT_EQUAL(345678901234567890LL, fd.intValue); in TestFixedDecimal()
818 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
819 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
824 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
826 ASSERT_EQUAL(22, fd.visibleDecimalDigitCount); in TestFixedDecimal()
827 ASSERT_EQUAL(12, fd.decimalDigits); in TestFixedDecimal()
828 ASSERT_EQUAL(12, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
829 ASSERT_EQUAL(1, fd.intValue); in TestFixedDecimal()
830 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
831 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
836 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
838 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
839 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
840 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
841 ASSERT_EQUAL(1, fd.intValue); in TestFixedDecimal()
842 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
843 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
848 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
850 ASSERT_EQUAL(22, fd.visibleDecimalDigitCount); in TestFixedDecimal()
851 ASSERT_EQUAL(12, fd.decimalDigits); in TestFixedDecimal()
852 ASSERT_EQUAL(12, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
853 ASSERT_EQUAL(1, fd.intValue); in TestFixedDecimal()
854 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
855 ASSERT_EQUAL(TRUE, fd.isNegative); in TestFixedDecimal()
860 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
862 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
863 ASSERT_EQUAL(30, fd.decimalDigits); in TestFixedDecimal()
864 ASSERT_EQUAL(3, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
865 ASSERT_EQUAL(100000000000000000LL, fd.intValue); in TestFixedDecimal()
866 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
867 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
871 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
873 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
874 ASSERT_EQUAL(30, fd.decimalDigits); in TestFixedDecimal()
875 ASSERT_EQUAL(3, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
876 ASSERT_EQUAL(50000LL, fd.intValue); in TestFixedDecimal()
877 ASSERT_EQUAL(FALSE, fd.hasIntegerValue); in TestFixedDecimal()
878 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
883 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
885 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
886 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
887 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
888 ASSERT_EQUAL(4503599627370496LL, fd.intValue); in TestFixedDecimal()
889 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
890 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
894 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
896 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
897 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
898 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
899 ASSERT_EQUAL(4503599627370497LL, fd.intValue); in TestFixedDecimal()
900 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
901 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()
905 fd = df->getFixedDecimal(fable, status); in TestFixedDecimal()
907 ASSERT_EQUAL(2, fd.visibleDecimalDigitCount); in TestFixedDecimal()
908 ASSERT_EQUAL(0, fd.decimalDigits); in TestFixedDecimal()
909 ASSERT_EQUAL(0, fd.decimalDigitsWithoutTrailingZeros); in TestFixedDecimal()
913 if (!(fd.intValue == 223372036854775807LL || fd.intValue == 9223372036854775807LL)) { in TestFixedDecimal()
914 dataerrln("File %s, Line %d, fd.intValue = %lld", __FILE__, __LINE__, fd.intValue); in TestFixedDecimal()
916 ASSERT_EQUAL(TRUE, fd.hasIntegerValue); in TestFixedDecimal()
917 ASSERT_EQUAL(FALSE, fd.isNegative); in TestFixedDecimal()