// ftruncate().

// General includes.
#include "cl_sysdep.h"

// Specification.
#include "cln/real.h"


// Implementation.

#include "cl_R.h"
#include "cl_RA.h"
#include "cln/integer.h"
#include "cln/sfloat.h"
#include "cln/ffloat.h"
#include "cln/dfloat.h"
#include "cln/lfloat.h"

namespace cln {

const cl_F ftruncate (const cl_R& x)
{
	realcase6(x
	,	return cl_float(x);
	,	var const cl_I& a = numerator(x);
		var const cl_I& b = denominator(x);
		return cl_float(truncate1(a,b));
	,	return ftruncate(x);
	,	return ftruncate(x);
	,	return ftruncate(x);
	,	return ftruncate(x);
	);
}

}  // namespace cln


syntax highlighted by Code2HTML, v. 0.9.1