From 9c02cf684cc13bf6b9e88a5a55b02bc2ccac7a7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20L=C3=B3pez-Ib=C3=A1=C3=B1ez?= Date: Mon, 18 Aug 2008 16:17:16 +0000 Subject: real.h (dconst_e, [...]): Declare. 2008-08-18 Manuel Lopez-Ibanez * real.h (dconst_e, dconst_third, dconst_sqrt2, dconst_e_ptr, dconst_third_ptr, dconst_sqrt2_ptr): Declare. (enum real_value_const): Delete. (get_real_const): Delete. * real.c (get_real_const): Delete. (dconst_e_ptr): Define. (dconst_third_ptr): Define. (dconst_sqrt2_ptr): Define. * builtins.c: Update all callers. From-SVN: r139202 --- gcc/real.h | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'gcc/real.h') diff --git a/gcc/real.h b/gcc/real.h index 8cdf471..44e79c3 100644 --- a/gcc/real.h +++ b/gcc/real.h @@ -409,16 +409,18 @@ extern REAL_VALUE_TYPE dconst2; extern REAL_VALUE_TYPE dconstm1; extern REAL_VALUE_TYPE dconsthalf; -/* Enumerate the special constant values we need. */ -enum real_value_const { - rv_e, - rv_third, - rv_sqrt2, - rv_max -}; +#define dconst_e() (*dconst_e_ptr ()) +#define dconst_third() (*dconst_third_ptr ()) +#define dconst_sqrt2() (*dconst_sqrt2_ptr ()) + +/* Function to return the real value special constant 'e'. */ +extern const REAL_VALUE_TYPE * dconst_e_ptr (void); + +/* Returns the special REAL_VALUE_TYPE corresponding to 1/3. */ +extern const REAL_VALUE_TYPE * dconst_third_ptr (void); -/* Function to return a real value special constant. */ -extern const REAL_VALUE_TYPE * get_real_const (enum real_value_const); +/* Returns the special REAL_VALUE_TYPE corresponding to sqrt(2). */ +extern const REAL_VALUE_TYPE * dconst_sqrt2_ptr (void); /* Function to return a real value (not a tree node) from a given integer constant. */ -- cgit v1.1