Made two changes; one, added convertToString and convertToDecimal/BigInt private functions to Decimal and BigInt which allow conversion of various valid types to Decimal/BigInt, thus freeing the functions from requiring the specific Decimal/BigInt types; second, change the return types to return new static, which allows a class to extend Decimal/BigInt and retain the proper return types.