From 77a02dba353a95a8e4b940f4dc80b927a27b980d Mon Sep 17 00:00:00 2001 From: Richard Kenner Date: Sat, 15 Apr 2000 16:59:10 +0000 Subject: toplev.c: Make *_time variable long to reduce chance of overflow. * toplev.c: Make *_time variable long to reduce chance of overflow. (TIMEVAR): Likewise for `otime'. (print_time): Arg is now long; compute percentage in FP and round. * toplev.h (print_time): Arg is long. * tree.c: Minor whitespace changes. From-SVN: r33168 --- gcc/tree.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'gcc/tree.c') diff --git a/gcc/tree.c b/gcc/tree.c index 24eca04..72d670c 100644 --- a/gcc/tree.c +++ b/gcc/tree.c @@ -5170,7 +5170,7 @@ int_fits_type_p (c, type) } /* Given a DECL or TYPE, return the scope in which it was declared, or - NUL_TREE if there is no containing scope. */ + NULL_TREE if there is no containing scope. */ tree get_containing_scope (t) @@ -5193,6 +5193,7 @@ decl_function_context (decl) if (TREE_CODE (decl) == SAVE_EXPR) context = SAVE_EXPR_CONTEXT (decl); + /* C++ virtual functions use DECL_CONTEXT for the class of the vtable where we look up the function at runtime. Such functions always take a first argument of type 'pointer to real context'. @@ -5200,8 +5201,9 @@ decl_function_context (decl) C++ should really be fixed to use DECL_CONTEXT for the real context, and use something else for the "virtual context". */ else if (TREE_CODE (decl) == FUNCTION_DECL && DECL_VINDEX (decl)) - context = TYPE_MAIN_VARIANT - (TREE_TYPE (TREE_VALUE (TYPE_ARG_TYPES (TREE_TYPE (decl))))); + context + = TYPE_MAIN_VARIANT + (TREE_TYPE (TREE_VALUE (TYPE_ARG_TYPES (TREE_TYPE (decl))))); else context = DECL_CONTEXT (decl); -- cgit v1.1