This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Patch installed for unnecessary casts in gcc/ subdirs


This patch eliminates unnecessary casts in gcc/ subdirectories.

Bootstrapped on sparc-sun-solaris2.7 (minus java), no regressions.  I
also enabled with java and treelang and did a "make" to ensure it
compiled and introduced no warnings.

Installed as pre-approved ISO C conversion.

		--Kaveh


2003-07-19  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>

gcc:
	* fixinc/fixfixes.c fixinc/fixincl.c fixinc/fixlib.c
	fixinc/server.c objc/objc-act.c: Remove unnecessary casts.

f:
	* com.c data.c expr.c fini.c g77spec.c global.c lab.c lex.c name.c
	sta.c stc.c std.c storag.c stt.c stw.c symbol.c target.c type.c:
	Remove unnecessary casts.
	
cp:
	* call.c class.c decl.c decl2.c g++spec.c lex.c parser.c pt.c rtti.c
	semantics.c typeck.c: Remove unnecessary casts.

java:
	* class.c java-tree.h jcf-write.c jvspec.c: Remove unnecessary
	casts.

treelang:
	* treetree.c: Remove unnecessary casts.

diff -rup orig/egcc-CVS20030716/gcc/f/com.c egcc-CVS20030716/gcc/f/com.c
--- orig/egcc-CVS20030716/gcc/f/com.c	2003-07-09 17:57:38.000000000 -0400
+++ egcc-CVS20030716/gcc/f/com.c	2003-07-17 16:22:20.961449000 -0400
@@ -13787,8 +13787,7 @@ pop_f_function_context (void)
 static void
 push_f_function_context (void)
 {
-  struct f_function *p
-  = (struct f_function *) xmalloc (sizeof (struct f_function));
+  struct f_function *p = xmalloc (sizeof (struct f_function));
 
   push_function_context ();
 
@@ -14216,7 +14215,7 @@ static bool
 ffe_init (void)
 {
 #ifdef IO_BUFFER_SIZE
-  setvbuf (finput, (char *) xmalloc (IO_BUFFER_SIZE), _IOFBF, IO_BUFFER_SIZE);
+  setvbuf (finput, xmalloc (IO_BUFFER_SIZE), _IOFBF, IO_BUFFER_SIZE);
 #endif
 
   ffecom_init_decl_processing ();
@@ -15226,7 +15225,7 @@ open_include_file (char *filename, struc
     }
   else
     {
-      dir = (char *) xmalloc (p - filename + 1);
+      dir = xmalloc (p - filename + 1);
       memcpy (dir, filename, p - filename);
       dir[p - filename] = '\0';
       from = p + 1;
@@ -15357,8 +15356,7 @@ read_name_map (const char *dirname)
     if (! strcmp (map_list_ptr->map_list_name, dirname))
       return map_list_ptr->map_list_map;
 
-  map_list_ptr = ((struct file_name_map_list *)
-		  xmalloc (sizeof (struct file_name_map_list)));
+  map_list_ptr = xmalloc (sizeof (struct file_name_map_list));
   map_list_ptr->map_list_name = xstrdup (dirname);
   map_list_ptr->map_list_map = NULL;
 
@@ -15388,8 +15386,7 @@ read_name_map (const char *dirname)
 	    ;
 	  to = read_filename_string (ch, f);
 
-	  ptr = ((struct file_name_map *)
-		 xmalloc (sizeof (struct file_name_map)));
+	  ptr = xmalloc (sizeof (struct file_name_map));
 	  ptr->map_from = from;
 
 	  /* Make the real filename absolute.  */
@@ -15429,7 +15426,7 @@ ffecom_file_ (const char *name)
      early #line directives (when -g is in effect).  */
 
   fp = &instack[++indepth];
-  memset ((char *) fp, 0, sizeof (FILE_BUF));
+  memset (fp, 0, sizeof (FILE_BUF));
   if (name == NULL)
     name = "";
   fp->nominal_fname = fp->fname = name;
@@ -15454,8 +15451,8 @@ ffecom_decode_include_option (const char
     ignore_srcdir = 1;
   else
     {
-      struct file_name_list *dirtmp = (struct file_name_list *)
-	xmalloc (sizeof (struct file_name_list));
+      struct file_name_list *dirtmp
+	= xmalloc (sizeof (struct file_name_list));
       dirtmp->next = 0;		/* New one goes on the end */
       dirtmp->fname = dir;
       dirtmp->got_name_map = 0;
@@ -15647,7 +15644,7 @@ ffecom_open_include_ (char *name, ffewhe
   instack[indepth].column = ffewhere_column_use (c);
 
   fp = &instack[indepth + 1];
-  memset ((char *) fp, 0, sizeof (FILE_BUF));
+  memset (fp, 0, sizeof (FILE_BUF));
   fp->nominal_fname = fp->fname = fname;
   fp->dir = searchptr;
 
diff -rup orig/egcc-CVS20030716/gcc/f/data.c egcc-CVS20030716/gcc/f/data.c
--- orig/egcc-CVS20030716/gcc/f/data.c	2003-07-06 20:01:53.000000000 -0400
+++ egcc-CVS20030716/gcc/f/data.c	2003-07-17 16:22:32.310333000 -0400
@@ -723,8 +723,8 @@ ffedata_convert_ (ffebld source, ffelexT
 
       if (max > ffedata_convert_cache_max_)
 	{
-	  cache = (ffedataConvertCache_) malloc_new_ks (malloc_pool_image (),
-				    "FFEDATA cache", max * sizeof (*cache));
+	  cache = malloc_new_ks (malloc_pool_image (),
+				 "FFEDATA cache", max * sizeof (*cache));
 	  if (ffedata_convert_cache_max_ != 0)
 	    {
 	      memcpy (cache, ffedata_convert_cache_,
diff -rup orig/egcc-CVS20030716/gcc/f/expr.c egcc-CVS20030716/gcc/f/expr.c
--- orig/egcc-CVS20030716/gcc/f/expr.c	2003-07-06 20:01:54.000000000 -0400
+++ egcc-CVS20030716/gcc/f/expr.c	2003-07-17 23:33:25.065642000 -0400
@@ -8488,8 +8488,7 @@ ffeexpr_expr_new_ (void)
 {
   ffeexprExpr_ e;
 
-  e = (ffeexprExpr_) malloc_new_ks (ffe_pool_program_unit (), "FFEEXPR expr",
-				    sizeof (*e));
+  e = malloc_new_ks (ffe_pool_program_unit (), "FFEEXPR expr", sizeof (*e));
   e->previous = NULL;
   e->type = FFEEXPR_exprtypeUNKNOWN_;
   e->token = NULL;
diff -rup orig/egcc-CVS20030716/gcc/f/fini.c egcc-CVS20030716/gcc/f/fini.c
--- orig/egcc-CVS20030716/gcc/f/fini.c	2002-12-16 13:22:27.000000000 -0500
+++ egcc-CVS20030716/gcc/f/fini.c	2003-07-17 23:34:18.990616000 -0400
@@ -367,7 +367,7 @@ main (int argc, char **argv)
 
       /* Make new name object to store name and its keyword. */
 
-      newname = (name) xmalloc (sizeof (*newname));
+      newname = xmalloc (sizeof (*newname));
       newname->namelen = strlen (buf);
       newname->kwlen = strlen (kwname);
       total_length = newname->kwlen + fixlengths;
diff -rup orig/egcc-CVS20030716/gcc/f/g77spec.c egcc-CVS20030716/gcc/f/g77spec.c
--- orig/egcc-CVS20030716/gcc/f/g77spec.c	2003-07-06 20:01:54.000000000 -0400
+++ egcc-CVS20030716/gcc/f/g77spec.c	2003-07-17 23:34:29.839612000 -0400
@@ -219,7 +219,7 @@ append_arg (const char *arg)
       int i;
 
       newargsize = (g77_xargc << 2) + 20;	/* This should handle all. */
-      g77_newargv = (const char **) xmalloc (newargsize * sizeof (char *));
+      g77_newargv = xmalloc (newargsize * sizeof (char *));
 
       /* Copy what has been done so far.  */
       for (i = 0; i < g77_newargc; ++i)
diff -rup orig/egcc-CVS20030716/gcc/f/global.c egcc-CVS20030716/gcc/f/global.c
--- orig/egcc-CVS20030716/gcc/f/global.c	2003-07-07 02:15:35.000000000 -0400
+++ egcc-CVS20030716/gcc/f/global.c	2003-07-17 23:35:09.975856000 -0400
@@ -107,8 +107,7 @@ ffeglobal_new_ (ffename n)
 
   assert (n != NULL);
 
-  g = (ffeglobal) malloc_new_ks (malloc_pool_image (), "FFEGLOBAL",
-				 sizeof (*g));
+  g = malloc_new_ks (malloc_pool_image (), "FFEGLOBAL", sizeof (*g));
   g->n = n;
   g->hook = FFECOM_globalNULL;
   g->tick = 0;
@@ -780,10 +779,9 @@ ffeglobal_proc_def_nargs (ffesymbol s, i
       return;
     }
 
-  g->u.proc.arg_info
-    = (ffeglobalArgInfo_) malloc_new_ks (malloc_pool_image (),
-					 "ffeglobalArgInfo_",
-					 n_args * sizeof (g->u.proc.arg_info[0]));
+  g->u.proc.arg_info = malloc_new_ks (malloc_pool_image (),
+				      "ffeglobalArgInfo_",
+				      n_args * sizeof (g->u.proc.arg_info[0]));
   while (n_args-- > 0)
     g->u.proc.arg_info[n_args].t = NULL;
 }
@@ -1123,10 +1121,9 @@ ffeglobal_proc_ref_nargs (ffesymbol s, i
       return TRUE;
     }
 
-  g->u.proc.arg_info
-    = (ffeglobalArgInfo_) malloc_new_ks (malloc_pool_image (),
-					 "ffeglobalArgInfo_",
-					 n_args * sizeof (g->u.proc.arg_info[0]));
+  g->u.proc.arg_info = malloc_new_ks (malloc_pool_image (),
+				      "ffeglobalArgInfo_",
+				      n_args * sizeof (g->u.proc.arg_info[0]));
   while (n_args-- > 0)
     g->u.proc.arg_info[n_args].t = NULL;
 
diff -rup orig/egcc-CVS20030716/gcc/f/lab.c egcc-CVS20030716/gcc/f/lab.c
--- orig/egcc-CVS20030716/gcc/f/lab.c	2003-07-06 20:01:55.000000000 -0400
+++ egcc-CVS20030716/gcc/f/lab.c	2003-07-17 23:35:18.594993000 -0400
@@ -141,7 +141,7 @@ ffelab_new (ffelabValue v)
   ffelab l;
 
   ++ffelab_num_news_;
-  l = (ffelab) malloc_new_ks (ffe_pool_any_unit (), "FFELAB label", sizeof (*l));
+  l = malloc_new_ks (ffe_pool_any_unit (), "FFELAB label", sizeof (*l));
   l->next = ffelab_list_;
   l->hook = FFECOM_labelNULL;
   l->value = v;
diff -rup orig/egcc-CVS20030716/gcc/f/lex.c egcc-CVS20030716/gcc/f/lex.c
--- orig/egcc-CVS20030716/gcc/f/lex.c	2003-07-08 11:33:58.000000000 -0400
+++ egcc-CVS20030716/gcc/f/lex.c	2003-07-17 23:36:31.738248000 -0400
@@ -694,7 +694,7 @@ ffelex_cfelex_ (ffelexToken *xtoken, FIL
 	      register unsigned bytes_used = (p - q);
 
 	      buffer_length *= 2;
-	      q = (char *)xrealloc (q, buffer_length);
+	      q = xrealloc (q, buffer_length);
 	      p = &q[bytes_used];
 	      r = &q[buffer_length];
 	    }
@@ -754,7 +754,7 @@ ffelex_cfelex_ (ffelexToken *xtoken, FIL
 		  register unsigned bytes_used = (p - q);
 
 		  buffer_length = bytes_used * 2;
-		  q = (char *)xrealloc (q, buffer_length);
+		  q = xrealloc (q, buffer_length);
 		  p = &q[bytes_used];
 		  r = &q[buffer_length];
 		}
@@ -805,8 +805,7 @@ ffelex_file_pop_ (const char *filename)
 static void
 ffelex_file_push_ (int old_lineno, const char *filename)
 {
-  struct file_stack *p
-    = (struct file_stack *) xmalloc (sizeof (struct file_stack));
+  struct file_stack *p = xmalloc (sizeof (struct file_stack));
 
   input_file_stack->location.line = old_lineno;
   p->next = input_file_stack;
@@ -923,7 +922,7 @@ ffelex_get_directive_line_ (char **text,
 
   if (buffer_length == 0)
     {
-      directive_buffer = (char *)xmalloc (128);
+      directive_buffer = xmalloc (128);
       buffer_length = 128;
     }
 
@@ -939,8 +938,7 @@ ffelex_get_directive_line_ (char **text,
 	  register unsigned bytes_used = (p - directive_buffer);
 
 	  buffer_length *= 2;
-	  directive_buffer
-	    = (char *)xrealloc (directive_buffer, buffer_length);
+	  directive_buffer = xrealloc (directive_buffer, buffer_length);
 	  p = &directive_buffer[bytes_used];
 	  buffer_limit = &directive_buffer[buffer_length];
 	}
@@ -1591,8 +1589,7 @@ ffelex_token_new_ (void)
 
   ++ffelex_total_tokens_;
 
-  t = (ffelexToken) malloc_new_ks (malloc_pool_image (),
-				   "FFELEX token", sizeof (*t));
+  t = malloc_new_ks (malloc_pool_image (), "FFELEX token", sizeof (*t));
   t->id_ = ffelex_token_nextid_++;
   return t;
 }
diff -rup orig/egcc-CVS20030716/gcc/f/name.c egcc-CVS20030716/gcc/f/name.c
--- orig/egcc-CVS20030716/gcc/f/name.c	1999-03-27 05:24:01.000000000 -0500
+++ egcc-CVS20030716/gcc/f/name.c	2003-07-17 23:36:50.326500000 -0400
@@ -105,7 +105,7 @@ ffename_find (ffenameSpace ns, ffelexTok
   if (found)
     return n;
 
-  newn = (ffename) malloc_new_ks (ns->pool, "FFENAME name", sizeof (*n));
+  newn = malloc_new_ks (ns->pool, "FFENAME name", sizeof (*n));
   newn->next = n;
   newn->previous = n->previous;
   n->previous = newn;
@@ -232,8 +232,7 @@ ffename_space_new (mallocPool pool)
 {
   ffenameSpace ns;
 
-  ns = (ffenameSpace) malloc_new_ks (pool, "FFENAME space",
-				     sizeof (*ns));
+  ns = malloc_new_ks (pool, "FFENAME space", sizeof (*ns));
   ns->first = (ffename) &ns->first;
   ns->last = (ffename) &ns->first;
   ns->pool = pool;
diff -rup orig/egcc-CVS20030716/gcc/f/sta.c egcc-CVS20030716/gcc/f/sta.c
--- orig/egcc-CVS20030716/gcc/f/sta.c	2003-07-06 20:01:56.000000000 -0400
+++ egcc-CVS20030716/gcc/f/sta.c	2003-07-17 23:38:20.508087000 -0400
@@ -247,9 +247,8 @@ ffesta_save_ (ffelexToken t)
   if (saved_tokens == NULL)
     {
       saved_tokens
-	= (ffelexToken *) malloc_new_ksr (malloc_pool_image (),
-					  "FFEST Saved Tokens",
-			     (max_saved_tokens = 8) * sizeof (ffelexToken));
+	= malloc_new_ksr (malloc_pool_image (), "FFEST Saved Tokens",
+			  (max_saved_tokens = 8) * sizeof (ffelexToken));
       /* Start off with 8. */
     }
   else if (num_saved_tokens >= max_saved_tokens)
@@ -258,10 +257,9 @@ ffesta_save_ (ffelexToken t)
       max_saved_tokens <<= 1;	/* Multiply by two. */
       assert (max_saved_tokens > toknum);
       saved_tokens
-	= (ffelexToken *) malloc_resize_ksr (malloc_pool_image (),
-					     saved_tokens,
-				    max_saved_tokens * sizeof (ffelexToken),
-					     toknum * sizeof (ffelexToken));
+	= malloc_resize_ksr (malloc_pool_image (), saved_tokens,
+			     max_saved_tokens * sizeof (ffelexToken),
+			     toknum * sizeof (ffelexToken));
     }
 
   *(saved_tokens + num_saved_tokens++) = ffelex_token_use (t);
@@ -1319,10 +1317,8 @@ ffesta_init_0 (void)
   ffestaPossible_ ptr;
   int i;
 
-  ptr = (ffestaPossible_) malloc_new_kp (malloc_pool_image (),
-					 "FFEST possibles",
-					 FFESTA_maxPOSSIBLES_
-					 * sizeof (*ptr));
+  ptr = malloc_new_kp (malloc_pool_image (), "FFEST possibles",
+		       FFESTA_maxPOSSIBLES_ * sizeof (*ptr));
 
   for (i = 0; i < FFESTA_maxPOSSIBLES_; ++i)
     ffesta_possibles_[i] = ptr++;
diff -rup orig/egcc-CVS20030716/gcc/f/stc.c egcc-CVS20030716/gcc/f/stc.c
--- orig/egcc-CVS20030716/gcc/f/stc.c	2003-07-06 20:01:57.000000000 -0400
+++ egcc-CVS20030716/gcc/f/stc.c	2003-07-17 23:38:59.474498000 -0400
@@ -6748,7 +6748,7 @@ ffestc_R809 (ffelexToken construct_name,
   /* Init block to manage CASE list. */
 
   pool = malloc_pool_new ("Select", ffe_pool_any_unit (), 1024);
-  s = (ffestwSelect) malloc_new_kp (pool, "Select", sizeof (*s));
+  s = malloc_new_kp (pool, "Select", sizeof (*s));
   s->first_rel = (ffestwCase) &s->first_rel;
   s->last_rel = (ffestwCase) &s->first_rel;
   s->first_stmt = (ffestwCase) &s->first_rel;
diff -rup orig/egcc-CVS20030716/gcc/f/std.c egcc-CVS20030716/gcc/f/std.c
--- orig/egcc-CVS20030716/gcc/f/std.c	2003-07-06 20:01:58.000000000 -0400
+++ egcc-CVS20030716/gcc/f/std.c	2003-07-17 23:40:02.858645000 -0400
@@ -984,8 +984,8 @@ ffestd_subr_copy_easy_ (ffestpInquireIx 
   ffestpInquireStmt *stmt;
   ffestpInquireIx ix;
 
-  stmt = (ffestpInquireStmt *) malloc_new_kp (ffesta_output_pool,
-				  "FFESTD easy", sizeof (ffestpFile) * max);
+  stmt = malloc_new_kp (ffesta_output_pool, "FFESTD easy",
+			sizeof (ffestpFile) * max);
 
   for (ix = 0; ix < max; ++ix)
     {
@@ -2229,8 +2229,7 @@ ffestd_R909_item (ffebld expr, ffelexTok
 
   ffestd_check_item_ ();
 
-  item = (ffestdExprItem_) malloc_new_kp (ffesta_output_pool,
-					  "ffestdExprItem_", sizeof (*item));
+  item = malloc_new_kp (ffesta_output_pool, "ffestdExprItem_", sizeof (*item));
 
   item->next = NULL;
   item->expr = expr;
@@ -2306,8 +2305,7 @@ ffestd_R910_item (ffebld expr, ffelexTok
 
   ffestd_check_item_ ();
 
-  item = (ffestdExprItem_) malloc_new_kp (ffesta_output_pool,
-					  "ffestdExprItem_", sizeof (*item));
+  item = malloc_new_kp (ffesta_output_pool, "ffestdExprItem_", sizeof (*item));
 
   item->next = NULL;
   item->expr = expr;
@@ -2366,8 +2364,7 @@ ffestd_R911_item (ffebld expr, ffelexTok
 
   ffestd_check_item_ ();
 
-  item = (ffestdExprItem_) malloc_new_kp (ffesta_output_pool,
-					  "ffestdExprItem_", sizeof (*item));
+  item = malloc_new_kp (ffesta_output_pool, "ffestdExprItem_", sizeof (*item));
 
   item->next = NULL;
   item->expr = expr;
@@ -2535,8 +2532,7 @@ ffestd_R923B_item (ffebld expr)
 
   ffestd_check_item_ ();
 
-  item = (ffestdExprItem_) malloc_new_kp (ffesta_output_pool,
-					  "ffestdExprItem_", sizeof (*item));
+  item = malloc_new_kp (ffesta_output_pool, "ffestdExprItem_", sizeof (*item));
 
   item->next = NULL;
   item->expr = expr;
diff -rup orig/egcc-CVS20030716/gcc/f/storag.c egcc-CVS20030716/gcc/f/storag.c
--- orig/egcc-CVS20030716/gcc/f/storag.c	2003-07-06 20:01:58.000000000 -0400
+++ egcc-CVS20030716/gcc/f/storag.c	2003-07-17 23:40:18.127255000 -0400
@@ -416,8 +416,7 @@ ffestorag_new (ffestoragList sl)
 {
   ffestorag s;
 
-  s = (ffestorag) malloc_new_kp (ffe_pool_program_unit (), "ffestorag",
-				 sizeof (*s));
+  s = malloc_new_kp (ffe_pool_program_unit (), "ffestorag", sizeof (*s));
   s->next = (ffestorag) &sl->first;
   s->previous = sl->last;
   s->hook = FFECOM_storageNULL;
diff -rup orig/egcc-CVS20030716/gcc/f/stt.c egcc-CVS20030716/gcc/f/stt.c
--- orig/egcc-CVS20030716/gcc/f/stt.c	2003-07-06 20:01:58.000000000 -0400
+++ egcc-CVS20030716/gcc/f/stt.c	2003-07-17 23:42:19.945830000 -0400
@@ -79,8 +79,7 @@ ffestt_caselist_append (ffesttCaseList l
 {
   ffesttCaseList new;
 
-  new = (ffesttCaseList) malloc_new_kp (ffesta_scratch_pool,
-					"FFEST case list", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST case list", sizeof (*new));
   new->next = list->previous->next;
   new->previous = list->previous;
   new->next->previous = new;
@@ -103,9 +102,8 @@ ffestt_caselist_create (void)
 {
   ffesttCaseList new;
 
-  new = (ffesttCaseList) malloc_new_kp (ffesta_scratch_pool,
-					"FFEST case list root",
-					sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST case list root",
+		       sizeof (*new));
   new->next = new->previous = new;
   new->t = NULL;
   new->expr1 = NULL;
@@ -151,8 +149,7 @@ ffestt_dimlist_append (ffesttDimList lis
 {
   ffesttDimList new;
 
-  new = (ffesttDimList) malloc_new_kp (ffesta_scratch_pool,
-				       "FFEST dim list", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST dim list", sizeof (*new));
   new->next = list->previous->next;
   new->previous = list->previous;
   new->next->previous = new;
@@ -400,8 +397,8 @@ ffestt_dimlist_create (void)
 {
   ffesttDimList new;
 
-  new = (ffesttDimList) malloc_new_kp (ffesta_scratch_pool,
-				       "FFEST dim list root", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST dim list root",
+		       sizeof (*new));
   new->next = new->previous = new;
   new->t = NULL;
   new->lower = NULL;
@@ -503,8 +500,7 @@ ffestt_exprlist_append (ffesttExprList l
 {
   ffesttExprList new;
 
-  new = (ffesttExprList) malloc_new_kp (ffesta_scratch_pool,
-					"FFEST expr list", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST expr list", sizeof (*new));
   new->next = list->previous->next;
   new->previous = list->previous;
   new->next->previous = new;
@@ -525,8 +521,8 @@ ffestt_exprlist_create (void)
 {
   ffesttExprList new;
 
-  new = (ffesttExprList) malloc_new_kp (ffesta_scratch_pool,
-				     "FFEST expr list root", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST expr list root",
+		       sizeof (*new));
   new->next = new->previous = new;
   new->expr = NULL;
   new->t = NULL;
@@ -592,8 +588,8 @@ ffestt_formatlist_append (ffesttFormatLi
 {
   ffesttFormatList new;
 
-  new = (ffesttFormatList) malloc_new_kp (ffesta_scratch_pool,
-					"FFEST format list", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST format list",
+		       sizeof (*new));
   new->next = list->previous->next;
   new->previous = list->previous;
   new->next->previous = new;
@@ -613,8 +609,8 @@ ffestt_formatlist_create (ffesttFormatLi
 {
   ffesttFormatList new;
 
-  new = (ffesttFormatList) malloc_new_kp (ffesta_scratch_pool,
-				   "FFEST format list root", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST format list root",
+		       sizeof (*new));
   new->next = new->previous = new;
   new->type = FFESTP_formattypeNone;
   new->t = t;
@@ -720,8 +716,7 @@ ffestt_implist_append (ffesttImpList lis
 {
   ffesttImpList new;
 
-  new = (ffesttImpList) malloc_new_kp (ffesta_scratch_pool,
-				       "FFEST token list", sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST token list", sizeof (*new));
   new->next = list->previous->next;
   new->previous = list->previous;
   new->next->previous = new;
@@ -742,9 +737,8 @@ ffestt_implist_create (void)
 {
   ffesttImpList new;
 
-  new = (ffesttImpList) malloc_new_kp (ffesta_scratch_pool,
-				       "FFEST token list root",
-				       sizeof (*new));
+  new = malloc_new_kp (ffesta_scratch_pool, "FFEST token list root",
+		       sizeof (*new));
   new->next = new->previous = new;
   new->first = NULL;
   new->last = NULL;
@@ -807,8 +801,7 @@ ffestt_tokenlist_append (ffesttTokenList
 {
   ffesttTokenItem ti;
 
-  ti = (ffesttTokenItem) malloc_new_kp (ffesta_scratch_pool,
-					"FFEST token item", sizeof (*ti));
+  ti = malloc_new_kp (ffesta_scratch_pool, "FFEST token item", sizeof (*ti));
   ti->next = (ffesttTokenItem) &tl->first;
   ti->previous = tl->last;
   ti->next->previous = ti;
@@ -829,8 +822,7 @@ ffestt_tokenlist_create (void)
 {
   ffesttTokenList tl;
 
-  tl = (ffesttTokenList) malloc_new_kp (ffesta_scratch_pool,
-					"FFEST token list", sizeof (*tl));
+  tl = malloc_new_kp (ffesta_scratch_pool, "FFEST token list", sizeof (*tl));
   tl->first = tl->last = (ffesttTokenItem) &tl->first;
   tl->count = 0;
   return tl;
diff -rup orig/egcc-CVS20030716/gcc/f/stw.c egcc-CVS20030716/gcc/f/stw.c
--- orig/egcc-CVS20030716/gcc/f/stw.c	2003-07-06 20:01:58.000000000 -0400
+++ egcc-CVS20030716/gcc/f/stw.c	2003-07-17 23:42:45.043480000 -0400
@@ -282,8 +282,8 @@ ffestw_init_0 (void)
 {
   ffestw b;
 
-  ffestw_stack_top_ = b = (ffestw) malloc_new_kp (malloc_pool_image (),
-					  "FFESTW stack base", sizeof (*b));
+  ffestw_stack_top_ = b = malloc_new_kp (malloc_pool_image (),
+					 "FFESTW stack base", sizeof (*b));
   b->uses_ = 0;			/* catch if anyone uses, kills, &c this
 				   block. */
   b->next_ = NULL;
@@ -324,7 +324,7 @@ ffestw_new (void)
 {
   ffestw b;
 
-  b = (ffestw) malloc_new_kp (malloc_pool_image (), "FFESTW", sizeof (*b));
+  b = malloc_new_kp (malloc_pool_image (), "FFESTW", sizeof (*b));
   b->uses_ = 1;
 
   return b;
diff -rup orig/egcc-CVS20030716/gcc/f/symbol.c egcc-CVS20030716/gcc/f/symbol.c
--- orig/egcc-CVS20030716/gcc/f/symbol.c	2003-07-06 20:01:59.000000000 -0400
+++ egcc-CVS20030716/gcc/f/symbol.c	2003-07-17 23:44:47.451932000 -0400
@@ -206,8 +206,7 @@ ffesymbol_new_ (ffename n)
 
   assert (n != NULL);
 
-  s = (ffesymbol) malloc_new_ks (FFESYMBOL_SPACE_POOL_, "FFESYMBOL",
-				 sizeof (*s));
+  s = malloc_new_ks (FFESYMBOL_SPACE_POOL_, "FFESYMBOL", sizeof (*s));
   s->name = n;
   s->other_space_name = NULL;
 #if FFEGLOBAL_ENABLED
@@ -258,8 +257,8 @@ ffesymbol_new_ (ffename n)
       return s;
     }
 
-  r = (ffesymbolRetract_) malloc_new_kp (ffesymbol_retract_pool_,
-					 "FFESYMBOL retract", sizeof (*r));
+  r = malloc_new_kp (ffesymbol_retract_pool_, "FFESYMBOL retract",
+		     sizeof (*r));
   r->next = NULL;
   r->command = FFESYMBOL_retractcommandDELETE_;
   r->live = s;
@@ -1104,13 +1103,13 @@ ffesymbol_signal_change (ffesymbol s)
   if (!ffesymbol_retractable_ || s->have_old)
     return;
 
-  r = (ffesymbolRetract_) malloc_new_kp (ffesymbol_retract_pool_,
-					 "FFESYMBOL retract", sizeof (*r));
+  r = malloc_new_kp (ffesymbol_retract_pool_, "FFESYMBOL retract",
+		     sizeof (*r));
   r->next = NULL;
   r->command = FFESYMBOL_retractcommandRETRACT_;
   r->live = s;
-  r->symbol = sym = (ffesymbol) malloc_new_ks (FFESYMBOL_SPACE_POOL_,
-					       "FFESYMBOL", sizeof (*sym));
+  r->symbol = sym = malloc_new_ks (FFESYMBOL_SPACE_POOL_,
+				   "FFESYMBOL", sizeof (*sym));
   *sym = *s;			/* Make an exact copy of the symbol in case
 				   we need it back. */
   sym->info = ffeinfo_use (s->info);
diff -rup orig/egcc-CVS20030716/gcc/f/target.c egcc-CVS20030716/gcc/f/target.c
--- orig/egcc-CVS20030716/gcc/f/target.c	2003-01-16 10:58:34.000000000 -0500
+++ egcc-CVS20030716/gcc/f/target.c	2003-07-17 23:45:18.259100000 -0400
@@ -2244,8 +2244,7 @@ ffetarget_real1 (ffetargetReal1 *value, 
 #undef dotoktxt
 
   if (sz > ARRAY_SIZE (ffetarget_string_))
-    p = ptr = (char *) malloc_new_ks (malloc_pool_image (), "ffetarget_real1",
-				      sz);
+    p = ptr = malloc_new_ks (malloc_pool_image (), "ffetarget_real1", sz);
 
 #define dotoktxt(x) if (x != NULL)				   \
 		  {						   \
@@ -2327,7 +2326,7 @@ ffetarget_real2 (ffetargetReal2 *value, 
 #undef dotoktxt
 
   if (sz > ARRAY_SIZE (ffetarget_string_))
-    p = ptr = (char *) malloc_new_ks (malloc_pool_image (), "ffetarget_real1", sz);
+    p = ptr = malloc_new_ks (malloc_pool_image (), "ffetarget_real1", sz);
 
 #define dotoktxt(x) if (x != NULL)				   \
 		  {						   \
diff -rup orig/egcc-CVS20030716/gcc/f/type.c egcc-CVS20030716/gcc/f/type.c
--- orig/egcc-CVS20030716/gcc/f/type.c	1999-02-15 13:18:13.000000000 -0500
+++ egcc-CVS20030716/gcc/f/type.c	2003-07-17 23:45:58.265373000 -0400
@@ -53,8 +53,7 @@ ffetype_new (void)
 {
   ffetype type;
 
-  type = (ffetype) malloc_new_kp (malloc_pool_image (), "ffetype",
-				    sizeof (*type));
+  type = malloc_new_kp (malloc_pool_image (), "ffetype", sizeof (*type));
   type->kinds_ = NULL;
   type->stars_ = NULL;
   type->alignment_ = 0;
@@ -74,9 +73,8 @@ ffetype_set_kind (ffetype base_type, int
       int i;
 
       base_type->kinds_
-	= (ffetype_indexes_) malloc_new_kp (malloc_pool_image (),
-					    "ffetype_indexes_[kinds]",
-					    sizeof (*(base_type->kinds_)));
+	= malloc_new_kp (malloc_pool_image (), "ffetype_indexes_[kinds]",
+			 sizeof (*(base_type->kinds_)));
       for (i = 0; ((size_t) i) < ARRAY_SIZE (base_type->kinds_->type_); ++i)
 	base_type->kinds_->type_[i] = NULL;
     }
@@ -94,9 +92,8 @@ ffetype_set_star (ffetype base_type, int
       int i;
 
       base_type->stars_
-	= (ffetype_indexes_) malloc_new_kp (malloc_pool_image (),
-					    "ffetype_indexes_[stars]",
-					    sizeof (*(base_type->stars_)));
+	= malloc_new_kp (malloc_pool_image (), "ffetype_indexes_[stars]",
+			 sizeof (*(base_type->stars_)));
       for (i = 0; ((size_t) i) < ARRAY_SIZE (base_type->stars_->type_); ++i)
 	base_type->stars_->type_[i] = NULL;
     }
diff -rup orig/egcc-CVS20030716/gcc/cp/call.c egcc-CVS20030716/gcc/cp/call.c
--- orig/egcc-CVS20030716/gcc/cp/call.c	2003-07-16 20:01:47.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/call.c	2003-07-17 16:10:45.105881000 -0400
@@ -1207,8 +1207,7 @@ add_candidate (struct z_candidate **cand
 	       tree fn, tree args, tree convs, tree access_path, 
 	       tree conversion_path, int viable)
 {
-  struct z_candidate *cand
-    = (struct z_candidate *) ggc_alloc_cleared (sizeof (struct z_candidate));
+  struct z_candidate *cand = ggc_alloc_cleared (sizeof (struct z_candidate));
 
   cand->fn = fn;
   cand->args = args;
diff -rup orig/egcc-CVS20030716/gcc/cp/class.c egcc-CVS20030716/gcc/cp/class.c
--- orig/egcc-CVS20030716/gcc/cp/class.c	2003-07-16 20:01:47.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/class.c	2003-07-17 16:11:34.351249000 -0400
@@ -5380,8 +5380,7 @@ init_class_processing (void)
   current_class_depth = 0;
   current_class_stack_size = 10;
   current_class_stack 
-    = (class_stack_node_t) xmalloc (current_class_stack_size 
-				    * sizeof (struct class_stack_node));
+    = xmalloc (current_class_stack_size * sizeof (struct class_stack_node));
   VARRAY_TREE_INIT (local_classes, 8, "local_classes");
 
   ridpointers[(int) RID_PUBLIC] = access_public_node;
@@ -5426,9 +5425,9 @@ pushclass (tree type, bool modify)
     {
       current_class_stack_size *= 2;
       current_class_stack
-	= (class_stack_node_t) xrealloc (current_class_stack,
-					 current_class_stack_size
-					 * sizeof (struct class_stack_node));
+	= xrealloc (current_class_stack,
+		    current_class_stack_size
+		    * sizeof (struct class_stack_node));
     }
 
   /* Insert a new entry on the class stack.  */
@@ -6205,8 +6204,7 @@ get_vfield_name (tree type)
     binfo = BINFO_BASETYPE (binfo, 0);
 
   type = BINFO_TYPE (binfo);
-  buf = (char *) alloca (sizeof (VFIELD_NAME_FORMAT)
-			 + TYPE_NAME_LENGTH (type) + 2);
+  buf = alloca (sizeof (VFIELD_NAME_FORMAT) + TYPE_NAME_LENGTH (type) + 2);
   sprintf (buf, VFIELD_NAME_FORMAT,
 	   IDENTIFIER_POINTER (constructor_name (type)));
   return get_identifier (buf);
diff -rup orig/egcc-CVS20030716/gcc/cp/decl.c egcc-CVS20030716/gcc/cp/decl.c
--- orig/egcc-CVS20030716/gcc/cp/decl.c	2003-07-16 20:01:48.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/decl.c	2003-07-17 16:11:51.249805000 -0400
@@ -2220,7 +2220,7 @@ maybe_push_to_top_level (int pseudo)
   int need_pop;
 
   timevar_push (TV_NAME_LOOKUP);
-  s = (struct saved_scope *) ggc_alloc_cleared (sizeof (struct saved_scope));
+  s = ggc_alloc_cleared (sizeof (struct saved_scope));
 
   b = scope_chain ? current_binding_level : 0;
 
@@ -4667,8 +4667,7 @@ use_label (tree decl)
       || named_label_uses->label_decl != decl)
     {
       struct named_label_use_list *new_ent;
-      new_ent = ((struct named_label_use_list *)
-		 ggc_alloc (sizeof (struct named_label_use_list)));
+      new_ent = ggc_alloc (sizeof (struct named_label_use_list));
       new_ent->label_decl = decl;
       new_ent->names_in_scope = current_binding_level->names;
       new_ent->binding_level = current_binding_level;
@@ -4705,8 +4704,7 @@ lookup_label (tree id)
   /* Record this label on the list of labels used in this function.
      We do this before calling make_label_decl so that we get the
      IDENTIFIER_LABEL_VALUE before the new label is declared.  */
-  ent = ((struct named_label_list *)
-	 ggc_alloc_cleared (sizeof (struct named_label_list)));
+  ent = ggc_alloc_cleared (sizeof (struct named_label_list));
   ent->old_value = IDENTIFIER_LABEL_VALUE (id);
   ent->next = named_labels;
   named_labels = ent;
@@ -5001,8 +4999,7 @@ static struct cp_switch *switch_stack;
 void
 push_switch (tree switch_stmt)
 {
-  struct cp_switch *p
-    = (struct cp_switch *) xmalloc (sizeof (struct cp_switch));
+  struct cp_switch *p = xmalloc (sizeof (struct cp_switch));
   p->level = current_binding_level;
   p->next = switch_stack;
   p->switch_stmt = switch_stmt;
@@ -13770,8 +13767,7 @@ save_function_data (tree decl)
 		      19990908);
 
   /* Make a copy.  */
-  f = ((struct language_function *)
-       ggc_alloc (sizeof (struct language_function)));
+  f = ggc_alloc (sizeof (struct language_function));
   memcpy (f, cp_function_chain, sizeof (struct language_function));
   DECL_SAVED_FUNCTION_DATA (decl) = f;
 
@@ -14440,8 +14436,7 @@ void
 cxx_push_function_context (struct function * f)
 {
   struct language_function *p
-    = ((struct language_function *)
-       ggc_alloc_cleared (sizeof (struct language_function)));
+    = ggc_alloc_cleared (sizeof (struct language_function));
   f->language = p;
 
   /* It takes an explicit call to expand_body to generate RTL for a
diff -rup orig/egcc-CVS20030716/gcc/cp/decl2.c egcc-CVS20030716/gcc/cp/decl2.c
--- orig/egcc-CVS20030716/gcc/cp/decl2.c	2003-07-10 14:06:14.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/decl2.c	2003-07-17 16:12:06.028366000 -0400
@@ -2220,7 +2220,7 @@ get_priority_info (int priority)
     {
       /* Create a new priority information structure, and insert it
 	 into the map.  */
-      pi = (priority_info) xmalloc (sizeof (struct priority_info_s));
+      pi = xmalloc (sizeof (struct priority_info_s));
       pi->initializations_p = 0;
       pi->destructions_p = 0;
       splay_tree_insert (priority_info_map,
diff -rup orig/egcc-CVS20030716/gcc/cp/g++spec.c egcc-CVS20030716/gcc/cp/g++spec.c
--- orig/egcc-CVS20030716/gcc/cp/g++spec.c	2003-07-07 20:02:09.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/g++spec.c	2003-07-17 16:12:24.966664000 -0400
@@ -113,7 +113,7 @@ lang_specific_driver (int *in_argc, cons
   argv = *in_argv;
   added_libraries = *in_added_libraries;
 
-  args = (int *) xcalloc (argc, sizeof (int));
+  args = xcalloc (argc, sizeof (int));
 
   for (i = 1; i < argc; i++)
     {
@@ -168,12 +168,12 @@ lang_specific_driver (int *in_argc, cons
 	      saw_speclang = 1;
 	    }
 	  else if (((argv[i][2] == '\0'
-		     && (char *)strchr ("bBVDUoeTuIYmLiA", argv[i][1]) != NULL)
+		     && strchr ("bBVDUoeTuIYmLiA", argv[i][1]) != NULL)
 		    || strcmp (argv[i], "-Xlinker") == 0
 		    || strcmp (argv[i], "-Tdata") == 0))
 	    quote = argv[i];
 	  else if ((argv[i][2] == '\0'
-		    && (char *) strchr ("cSEM", argv[i][1]) != NULL)
+		    && strchr ("cSEM", argv[i][1]) != NULL)
 		   || strcmp (argv[i], "-MM") == 0
 		   || strcmp (argv[i], "-fsyntax-only") == 0)
 	    {
@@ -243,7 +243,7 @@ lang_specific_driver (int *in_argc, cons
 
   /* Make sure to have room for the trailing NULL argument.  */
   num_args = argc + added + need_math + shared_libgcc + (library > 0) + 1;
-  arglist = (const char **) xmalloc (num_args * sizeof (char *));
+  arglist = xmalloc (num_args * sizeof (char *));
 
   i = 0;
   j = 0;
diff -rup orig/egcc-CVS20030716/gcc/cp/lex.c egcc-CVS20030716/gcc/cp/lex.c
--- orig/egcc-CVS20030716/gcc/cp/lex.c	2003-07-16 20:01:50.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/lex.c	2003-07-17 16:13:00.213364000 -0400
@@ -354,7 +354,7 @@ init_reswords (void)
   int mask = ((flag_no_asm ? D_ASM : 0)
 	      | (flag_no_gnu_keywords ? D_EXT : 0));
 
-  ridpointers = (tree *) ggc_calloc ((int) RID_MAX, sizeof (tree));
+  ridpointers = ggc_calloc ((int) RID_MAX, sizeof (tree));
   for (i = 0; i < ARRAY_SIZE (reswords); i++)
     {
       id = get_identifier (reswords[i].word);
@@ -643,7 +643,7 @@ handle_pragma_implementation (cpp_reader
     }
   if (ifiles == 0)
     {
-      ifiles = (struct impl_files*) xmalloc (sizeof (struct impl_files));
+      ifiles = xmalloc (sizeof (struct impl_files));
       ifiles->filename = main_filename;
       ifiles->next = impl_file_chain;
       impl_file_chain = ifiles;
@@ -756,7 +756,7 @@ retrofit_lang_decl (tree t)
   else
     size = sizeof (struct lang_decl_flags);
 
-  ld = (struct lang_decl *) ggc_alloc_cleared (size);
+  ld = ggc_alloc_cleared (size);
 
   ld->decl_flags.can_be_full = CAN_HAVE_FULL_LANG_DECL_P (t) ? 1 : 0;
   ld->decl_flags.u1sel = TREE_CODE (t) == NAMESPACE_DECL ? 1 : 0;
@@ -792,7 +792,7 @@ cxx_dup_lang_specific_decl (tree node)
     size = sizeof (struct lang_decl_flags);
   else
     size = sizeof (struct lang_decl);
-  ld = (struct lang_decl *) ggc_alloc (size);
+  ld = ggc_alloc (size);
   memcpy (ld, DECL_LANG_SPECIFIC (node), size);
   DECL_LANG_SPECIFIC (node) = ld;
 
@@ -829,7 +829,7 @@ copy_lang_type (tree node)
     size = sizeof (struct lang_type);
   else
     size = sizeof (struct lang_type_ptrmem);
-  lt = (struct lang_type *) ggc_alloc (size);
+  lt = ggc_alloc (size);
   memcpy (lt, TYPE_LANG_SPECIFIC (node), size);
   TYPE_LANG_SPECIFIC (node) = lt;
 
@@ -862,8 +862,7 @@ cxx_make_type (enum tree_code code)
     {
       struct lang_type *pi;
 
-      pi = ((struct lang_type *)
-	    ggc_alloc_cleared (sizeof (struct lang_type)));
+      pi = ggc_alloc_cleared (sizeof (struct lang_type));
 
       TYPE_LANG_SPECIFIC (t) = pi;
       pi->u.c.h.is_lang_type_class = 1;
diff -rup orig/egcc-CVS20030716/gcc/cp/parser.c egcc-CVS20030716/gcc/cp/parser.c
--- orig/egcc-CVS20030716/gcc/cp/parser.c	2003-07-16 20:01:50.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/parser.c	2003-07-17 16:17:03.130885000 -0400
@@ -127,7 +127,7 @@ static void cp_token_cache_push_token
 static cp_token_cache *
 cp_token_cache_new ()
 {
-  return (cp_token_cache *) ggc_alloc_cleared (sizeof (cp_token_cache));
+  return ggc_alloc_cleared (sizeof (cp_token_cache));
 }
 
 /* Add *TOKEN to *CACHE.  */
@@ -141,7 +141,7 @@ cp_token_cache_push_token (cp_token_cach
   /* See if we need to allocate a new token block.  */
   if (!b || b->num_tokens == CP_TOKEN_BLOCK_NUM_TOKENS)
     {
-      b = ((cp_token_block *) ggc_alloc_cleared (sizeof (cp_token_block)));
+      b = ggc_alloc_cleared (sizeof (cp_token_block));
       b->prev = cache->last;
       if (cache->last)
 	{
@@ -305,11 +305,10 @@ cp_lexer_new_main (void)
   cpp_get_callbacks (parse_in)->valid_pch = NULL;
 
   /* Allocate the memory.  */
-  lexer = (cp_lexer *) ggc_alloc_cleared (sizeof (cp_lexer));
+  lexer = ggc_alloc_cleared (sizeof (cp_lexer));
 
   /* Create the circular buffer.  */
-  lexer->buffer = ((cp_token *) 
-		   ggc_calloc (CP_TOKEN_BUFFER_SIZE, sizeof (cp_token)));
+  lexer->buffer = ggc_calloc (CP_TOKEN_BUFFER_SIZE, sizeof (cp_token));
   lexer->buffer_end = lexer->buffer + CP_TOKEN_BUFFER_SIZE;
 
   /* There is one token in the buffer.  */
@@ -345,13 +344,13 @@ cp_lexer_new_from_tokens (cp_token_cache
   ptrdiff_t num_tokens;
 
   /* Allocate the memory.  */
-  lexer = (cp_lexer *) ggc_alloc_cleared (sizeof (cp_lexer));
+  lexer = ggc_alloc_cleared (sizeof (cp_lexer));
 
   /* Create a new buffer, appropriately sized.  */
   num_tokens = 0;
   for (block = tokens->first; block != NULL; block = block->next)
     num_tokens += block->num_tokens;
-  lexer->buffer = ((cp_token *) ggc_alloc (num_tokens * sizeof (cp_token)));
+  lexer->buffer = ggc_alloc (num_tokens * sizeof (cp_token));
   lexer->buffer_end = lexer->buffer + num_tokens;
   
   /* Install the tokens.  */
@@ -521,9 +520,8 @@ cp_lexer_maybe_grow_buffer (cp_lexer* le
       /* Compute the current buffer size.  */
       buffer_length = lexer->buffer_end - lexer->buffer;
       /* Allocate a buffer twice as big.  */
-      new_buffer = ((cp_token *)
-		    ggc_realloc (lexer->buffer, 
-				 2 * buffer_length * sizeof (cp_token)));
+      new_buffer = ggc_realloc (lexer->buffer, 
+				2 * buffer_length * sizeof (cp_token));
       
       /* Because the buffer is circular, logically consecutive tokens
 	 are not necessarily placed consecutively in memory.
@@ -1130,11 +1128,10 @@ cp_parser_context_new (cp_parser_context
       /* Pull the first entry from the free list.  */
       context = cp_parser_context_free_list;
       cp_parser_context_free_list = context->next;
-      memset ((char *)context, 0, sizeof (*context));
+      memset (context, 0, sizeof (*context));
     }
   else
-    context = ((cp_parser_context *) 
-	       ggc_alloc_cleared (sizeof (cp_parser_context)));
+    context = ggc_alloc_cleared (sizeof (cp_parser_context));
   /* No errors have occurred yet in this context.  */
   context->status = CP_PARSER_STATUS_KIND_NO_ERROR;
   /* If this is not the bottomost context, copy information that we
@@ -2069,7 +2066,7 @@ cp_parser_new (void)
      cp_lexer_new_main might load a PCH file.  */
   lexer = cp_lexer_new_main ();
 
-  parser = (cp_parser *) ggc_alloc_cleared (sizeof (cp_parser));
+  parser = ggc_alloc_cleared (sizeof (cp_parser));
   parser->lexer = lexer;
   parser->context = cp_parser_context_new (NULL);
 
@@ -13756,10 +13753,9 @@ cp_parser_sizeof_operand (cp_parser* par
   saved_message = parser->type_definition_forbidden_message;
   /* And create the new one.  */
   parser->type_definition_forbidden_message 
-    = ((const char *) 
-       xmalloc (strlen (format) 
-		+ strlen (IDENTIFIER_POINTER (ridpointers[keyword]))
-		+ 1 /* `\0' */));
+    = xmalloc (strlen (format) 
+	       + strlen (IDENTIFIER_POINTER (ridpointers[keyword]))
+	       + 1 /* `\0' */);
   sprintf ((char *) parser->type_definition_forbidden_message,
 	   format, IDENTIFIER_POINTER (ridpointers[keyword]));
 
diff -rup orig/egcc-CVS20030716/gcc/cp/pt.c egcc-CVS20030716/gcc/cp/pt.c
--- orig/egcc-CVS20030716/gcc/cp/pt.c	2003-07-16 20:01:51.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/pt.c	2003-07-17 16:17:37.337632000 -0400
@@ -840,9 +840,8 @@ retrieve_specialization (tree tmpl, tree
 static tree
 retrieve_local_specialization (tree tmpl)
 {
-  tree spec = 
-    (tree) htab_find_with_hash (local_specializations, tmpl,
-				htab_hash_pointer (tmpl));
+  tree spec = htab_find_with_hash (local_specializations, tmpl,
+				   htab_hash_pointer (tmpl));
   return spec ? TREE_PURPOSE (spec) : NULL_TREE;
 }
 
@@ -2409,11 +2408,11 @@ process_partial_specialization (tree dec
 		{
 		  /* We haven't yet initialized TPD2.  Do so now.  */
 		  tpd2.arg_uses_template_parms 
-		    =  (int*) alloca (sizeof (int) * nargs);
+		    = alloca (sizeof (int) * nargs);
 		  /* The number of parameters here is the number in the
 		     main template, which, as checked in the assertion
 		     above, is NARGS.  */
-		  tpd2.parms = (int*) alloca (sizeof (int) * nargs);
+		  tpd2.parms = alloca (sizeof (int) * nargs);
 		  tpd2.level = 
 		    TMPL_PARMS_DEPTH (DECL_TEMPLATE_PARMS (maintmpl));
 		}
@@ -5541,9 +5540,9 @@ static tree
 tsubst_template_arg_vector (tree t, tree args, tsubst_flags_t complain)
 {
   int len = TREE_VEC_LENGTH (t), need_new = 0, i;
-  tree *elts = (tree *) alloca (len * sizeof (tree));
+  tree *elts = alloca (len * sizeof (tree));
   
-  memset ((char *) elts, 0, len * sizeof (tree));
+  memset (elts, 0, len * sizeof (tree));
   
   for (i = 0; i < len; i++)
     {
diff -rup orig/egcc-CVS20030716/gcc/cp/rtti.c egcc-CVS20030716/gcc/cp/rtti.c
--- orig/egcc-CVS20030716/gcc/cp/rtti.c	2003-07-08 11:33:55.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/rtti.c	2003-07-17 16:18:03.575214000 -0400
@@ -1125,7 +1125,7 @@ create_pseudo_type_info (const char *rea
   va_start (ap, ident);
 
   /* Generate the pseudo type name.  */
-  pseudo_name = (char *)alloca (strlen (real_name) + 30);
+  pseudo_name = alloca (strlen (real_name) + 30);
   strcpy (pseudo_name, real_name);
   strcat (pseudo_name, "_pseudo");
   if (ident)
diff -rup orig/egcc-CVS20030716/gcc/cp/semantics.c egcc-CVS20030716/gcc/cp/semantics.c
--- orig/egcc-CVS20030716/gcc/cp/semantics.c	2003-07-16 20:01:51.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/semantics.c	2003-07-17 16:18:23.613360000 -0400
@@ -155,7 +155,7 @@ void push_deferring_access_checks (defer
       deferred_access_free_list = d->next;
     }
   else
-    d = (deferred_access *) ggc_alloc (sizeof (deferred_access));
+    d = ggc_alloc (sizeof (deferred_access));
 
   d->next = deferred_access_stack;
   d->deferred_access_checks = NULL_TREE;
diff -rup orig/egcc-CVS20030716/gcc/cp/typeck.c egcc-CVS20030716/gcc/cp/typeck.c
--- orig/egcc-CVS20030716/gcc/cp/typeck.c	2003-07-15 20:02:03.000000000 -0400
+++ egcc-CVS20030716/gcc/cp/typeck.c	2003-07-17 16:18:49.880965000 -0400
@@ -5966,7 +5966,7 @@ c_expand_asm_operands (tree string, tree
   int noutputs = list_length (outputs);
   register int i;
   /* o[I] is the place that output number I should be written.  */
-  register tree *o = (tree *) alloca (noutputs * sizeof (tree));
+  register tree *o = alloca (noutputs * sizeof (tree));
   register tree tail;
 
   /* Record the contents of OUTPUTS before it is modified.  */
diff -rup orig/egcc-CVS20030716/gcc/java/class.c egcc-CVS20030716/gcc/java/class.c
--- orig/egcc-CVS20030716/gcc/java/class.c	2003-06-28 20:01:31.000000000 -0400
+++ egcc-CVS20030716/gcc/java/class.c	2003-07-17 23:49:55.793214000 -0400
@@ -148,8 +148,7 @@ add_assume_compiled (const char *ident, 
 {
   int len;
   assume_compiled_node *parent;
-  assume_compiled_node *node = 
-    xmalloc (sizeof (assume_compiled_node));
+  assume_compiled_node *node = xmalloc (sizeof (assume_compiled_node));
 
   node->ident = xstrdup (ident);
   node->excludep = excludep;
@@ -2157,7 +2156,7 @@ java_treetreehash_find (htab_t ht, tree 
 {
   struct treetreehash_entry *e;
   hashval_t hv = JAVA_TREEHASHHASH_H (t);
-  e = (struct treetreehash_entry *) htab_find_with_hash (ht, t, hv);
+  e = htab_find_with_hash (ht, t, hv);
   if (e == NULL)
     return NULL;
   else
diff -rup orig/egcc-CVS20030716/gcc/java/java-tree.h egcc-CVS20030716/gcc/java/java-tree.h
--- orig/egcc-CVS20030716/gcc/java/java-tree.h	2003-07-08 20:47:16.000000000 -0400
+++ egcc-CVS20030716/gcc/java/java-tree.h	2003-07-17 11:32:59.545498000 -0400
@@ -946,8 +946,7 @@ union lang_tree_node 
   if (DECL_LANG_SPECIFIC (T) == NULL)				\
     {								\
       DECL_LANG_SPECIFIC ((T))					\
-	= ((struct lang_decl *)					\
-	   ggc_alloc_cleared (sizeof (struct lang_decl)));	\
+	= ggc_alloc_cleared (sizeof (struct lang_decl));	\
       DECL_LANG_SPECIFIC (T)->desc = LANG_DECL_VAR;		\
     }
 
@@ -1050,9 +1049,8 @@ struct lang_decl GTY(())
 #define MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC(T)				 \
   if (TYPE_LANG_SPECIFIC ((T)) == NULL)					 \
     {									 \
-      TYPE_LANG_SPECIFIC ((T)) = 					 \
-	((struct lang_type *) 						 \
-         ggc_alloc_cleared (sizeof (struct lang_type)));		 \
+      TYPE_LANG_SPECIFIC ((T)) 					 	 \
+        = ggc_alloc_cleared (sizeof (struct lang_type));		 \
     }
 
 #define TYPE_FINIT_STMT_LIST(T)  (TYPE_LANG_SPECIFIC(T)->finit_stmt_list)
diff -rup orig/egcc-CVS20030716/gcc/java/jcf-write.c egcc-CVS20030716/gcc/java/jcf-write.c
--- orig/egcc-CVS20030716/gcc/java/jcf-write.c	2003-07-03 09:17:34.000000000 -0400
+++ egcc-CVS20030716/gcc/java/jcf-write.c	2003-07-17 11:38:05.347172000 -0400
@@ -386,8 +386,7 @@ static struct chunk *
 alloc_chunk (struct chunk *last, unsigned char *data,
 	     int size, struct obstack *work)
 {
-  struct chunk *chunk = (struct chunk *)
-    obstack_alloc (work, sizeof(struct chunk));
+  struct chunk *chunk = obstack_alloc (work, sizeof(struct chunk));
 
   if (data == NULL && size > 0)
     data = obstack_alloc (work, size);
@@ -434,8 +433,8 @@ append_chunk_copy (unsigned char *data, 
 static struct jcf_block *
 gen_jcf_label (struct jcf_partial *state)
 {
-  struct jcf_block *block = (struct jcf_block *)
-    obstack_alloc (state->chunk_obstack, sizeof (struct jcf_block));
+  struct jcf_block *block
+    = obstack_alloc (state->chunk_obstack, sizeof (struct jcf_block));
   block->next =	NULL;
   block->linenumber = -1;
   block->pc = UNDEFINED_PC;
@@ -518,8 +517,8 @@ static struct jcf_handler *
 alloc_handler (struct jcf_block *start_label, struct jcf_block *end_label,
 	       struct jcf_partial *state)
 {
-  struct jcf_handler *handler = (struct jcf_handler *)
-    obstack_alloc (state->chunk_obstack, sizeof (struct jcf_handler));
+  struct jcf_handler *handler
+    = obstack_alloc (state->chunk_obstack, sizeof (struct jcf_handler));
   handler->start_label = start_label;
   handler->end_label = end_label;
   handler->handler_label = get_jcf_label_here (state);
@@ -576,8 +575,7 @@ localvar_alloc (tree decl, struct jcf_pa
       ptr = (struct localvar_info**) state->localvars.data + index;
       state->localvars.ptr = (unsigned char *) (ptr + 1 + wide);
     }
-  info = (struct localvar_info *)
-    obstack_alloc (state->chunk_obstack, sizeof (struct localvar_info));
+  info = obstack_alloc (state->chunk_obstack, sizeof (struct localvar_info));
   ptr[0] = info;
   if (wide)
     ptr[1] = (struct localvar_info *)(~0);
@@ -1004,8 +1002,8 @@ static void
 emit_reloc (HOST_WIDE_INT value, int kind,
 	    struct jcf_block *target, struct jcf_partial *state)
 {
-  struct jcf_relocation *reloc = (struct jcf_relocation *)
-    obstack_alloc (state->chunk_obstack, sizeof (struct jcf_relocation));
+  struct jcf_relocation *reloc
+    = obstack_alloc (state->chunk_obstack, sizeof (struct jcf_relocation));
   struct jcf_block *block = state->last_block;
   reloc->next = block->u.relocations;
   block->u.relocations = reloc;
@@ -1582,8 +1580,8 @@ generate_bytecode_insns (tree exp, int t
     case CASE_EXPR:
       {
 	struct jcf_switch_state *sw_state = state->sw_state;
-	struct jcf_relocation *reloc = (struct jcf_relocation *)
-	  obstack_alloc (state->chunk_obstack, sizeof (struct jcf_relocation));
+	struct jcf_relocation *reloc
+	  = obstack_alloc (state->chunk_obstack, sizeof (struct jcf_relocation));
 	HOST_WIDE_INT case_value = TREE_INT_CST_LOW (TREE_OPERAND (exp, 0));
 	reloc->kind = 0;
 	reloc->label = get_jcf_label_here (state);
@@ -1663,8 +1661,8 @@ generate_bytecode_insns (tree exp, int t
 	    HOST_WIDE_INT i;
 	    unsigned HOST_WIDE_INT delta;
 	    /* Copy the chain of relocs into a sorted array. */
-	    struct jcf_relocation **relocs = (struct jcf_relocation **)
-	      xmalloc (sw_state.num_cases * sizeof (struct jcf_relocation *));
+	    struct jcf_relocation **relocs
+	      = xmalloc (sw_state.num_cases * sizeof (struct jcf_relocation *));
 	    /* The relocs arrays is a buffer with a gap.
 	       The assumption is that cases will normally come in "runs". */
 	    int gap_start = 0;
@@ -2669,8 +2667,7 @@ perform_relocations (struct jcf_partial 
       unsigned char *old_ptr = old_buffer + old_size;
       if (new_size != old_size)
 	{
-	  chunk->data = (unsigned char *)
-	    obstack_alloc (state->chunk_obstack, new_size);
+	  chunk->data = obstack_alloc (state->chunk_obstack, new_size);
 	  chunk->size = new_size;
 	}
       new_ptr = chunk->data + new_size;
diff -rup orig/egcc-CVS20030716/gcc/java/jvspec.c egcc-CVS20030716/gcc/java/jvspec.c
--- orig/egcc-CVS20030716/gcc/java/jvspec.c	2003-06-08 20:02:12.000000000 -0400
+++ egcc-CVS20030716/gcc/java/jvspec.c	2003-07-17 15:02:54.900969000 -0400
@@ -319,7 +319,7 @@ lang_specific_driver (in_argc, in_argv, 
 	  else if (argv[i][1] == 'O')
 	    saw_O = 1;
 	  else if ((argv[i][2] == '\0'
-		    && (char *)strchr ("bBVDUoeTuIYmLiA", argv[i][1]) != NULL)
+		    && strchr ("bBVDUoeTuIYmLiA", argv[i][1]) != NULL)
 		   || strcmp (argv[i], "-Tdata") == 0
 		   || strcmp (argv[i], "-MT") == 0
 		   || strcmp (argv[i], "-MF") == 0)
@@ -337,7 +337,7 @@ lang_specific_driver (in_argc, in_argv, 
 	    }
 	  else if (library != 0 
 		   && ((argv[i][2] == '\0'
-			&& (char *) strchr ("cSEM", argv[i][1]) != NULL)
+			&& strchr ("cSEM", argv[i][1]) != NULL)
 		       || strcmp (argv[i], "-MM") == 0))
 	    {
 	      /* Don't specify libraries if we won't link, since that would
diff -rup orig/egcc-CVS20030716/gcc/fixinc/fixfixes.c egcc-CVS20030716/gcc/fixinc/fixfixes.c
--- orig/egcc-CVS20030716/gcc/fixinc/fixfixes.c	2003-07-08 20:01:58.000000000 -0400
+++ egcc-CVS20030716/gcc/fixinc/fixfixes.c	2003-07-17 16:07:40.572890000 -0400
@@ -783,7 +783,7 @@ main( argc, argv )
       return EXIT_FAILURE;
     }
 
-  pz_tmptmp = (char*)xmalloc( strlen( argv[4] ) + 5 );
+  pz_tmptmp = xmalloc (strlen (argv[4]) + 5);
   strcpy( pz_tmptmp, argv[4] );
 
   /* Don't lose because "12345678" and "12345678X" map to the same
diff -rup orig/egcc-CVS20030716/gcc/fixinc/fixincl.c egcc-CVS20030716/gcc/fixinc/fixincl.c
--- orig/egcc-CVS20030716/gcc/fixinc/fixincl.c	2003-07-08 20:01:58.000000000 -0400
+++ egcc-CVS20030716/gcc/fixinc/fixincl.c	2003-07-17 16:09:19.893741000 -0400
@@ -488,12 +488,12 @@ run_compiles ()
 {
   tFixDesc *p_fixd = fixDescList;
   int fix_ct = FIX_COUNT;
-  regex_t *p_re = (regex_t *) xmalloc (REGEX_COUNT * sizeof (regex_t));
+  regex_t *p_re = xmalloc (REGEX_COUNT * sizeof (regex_t));
 
   /*  Make sure compile_re does not stumble across invalid data */
 
-  memset ( (void*)p_re, '\0', REGEX_COUNT * sizeof (regex_t) );
-  memset ( (void*)&incl_quote_re, '\0', sizeof (regex_t) );
+  memset (p_re, '\0', REGEX_COUNT * sizeof (regex_t));
+  memset (&incl_quote_re, '\0', sizeof (regex_t));
 
   compile_re (incl_quote_pat, &incl_quote_re, 1,
               "quoted include", "run_compiles");
@@ -911,7 +911,7 @@ fix_with_system (p_fixd, pz_fix_file, pz
               + strlen( pz_file_source )
               + strlen( pz_temp_file );
 
-      pz_cmd = (char*)xmalloc( argsize );
+      pz_cmd = xmalloc (argsize);
 
       strcpy( pz_cmd, pz_orig_dir );
       pz_scan = pz_cmd + strlen( pz_orig_dir );
@@ -970,7 +970,7 @@ fix_with_system (p_fixd, pz_fix_file, pz
         }
 
       /* Estimated buffer size we will need.  */
-      pz_scan = pz_cmd = (char*)xmalloc( argsize );
+      pz_scan = pz_cmd = xmalloc (argsize);
       /* How much of it do we allot to the program name and its
          arguments.  */
       parg_size = argsize - parg_size;
@@ -1010,7 +1010,7 @@ fix_with_system (p_fixd, pz_fix_file, pz
 	  while (pz_scan == (char*)NULL)
 	    {
 	      size_t already_filled = pz_scan_save - pz_cmd;
-	      pz_cmd = (char*)xrealloc( pz_cmd, argsize += 100 );
+	      pz_cmd = xrealloc (pz_cmd, argsize += 100);
 	      pz_scan_save = pz_scan = pz_cmd + already_filled;
 	      parg_size += 100;
 	      pz_scan = make_raw_shell_str( pz_scan, pArg,
@@ -1058,9 +1058,8 @@ start_fixer (read_fd, p_fixd, pz_fix_fil
   else
     {
       tSCC z_cmd_fmt[] = "file='%s'\n%s";
-      pz_cmd = (char*) xmalloc (strlen (p_fixd->patch_args[2])
-				+ sizeof( z_cmd_fmt )
-				+ strlen( pz_fix_file ));
+      pz_cmd = xmalloc (strlen (p_fixd->patch_args[2])
+			+ sizeof (z_cmd_fmt) + strlen (pz_fix_file));
       sprintf (pz_cmd, z_cmd_fmt, pz_fix_file, p_fixd->patch_args[2]);
       pz_cmd_save = p_fixd->patch_args[2];
       p_fixd->patch_args[2] = pz_cmd;
diff -rup orig/egcc-CVS20030716/gcc/fixinc/fixlib.c egcc-CVS20030716/gcc/fixinc/fixlib.c
--- orig/egcc-CVS20030716/gcc/fixinc/fixlib.c	2003-07-08 20:01:59.000000000 -0400
+++ egcc-CVS20030716/gcc/fixinc/fixlib.c	2003-07-17 12:23:04.928922000 -0400
@@ -49,7 +49,7 @@ load_file_data (fp)
       if (space_left < 1024)
         {
           space_left += 4096;
-	  pz_data = xrealloc ((void*)pz_data, space_left + space_used + 1 );
+	  pz_data = xrealloc (pz_data, space_left + space_used + 1 );
         }
       size_read = fread (pz_data + space_used, 1, space_left, fp);
 
@@ -73,7 +73,7 @@ load_file_data (fp)
       space_used += size_read;
     } while (! feof (fp));
 
-  pz_data = xrealloc ((void*)pz_data, space_used+1 );
+  pz_data = xrealloc (pz_data, space_used+1 );
   pz_data[ space_used ] = NUL;
 
   return pz_data;
diff -rup orig/egcc-CVS20030716/gcc/fixinc/server.c egcc-CVS20030716/gcc/fixinc/server.c
--- orig/egcc-CVS20030716/gcc/fixinc/server.c	2003-07-14 13:42:28.000000000 -0400
+++ egcc-CVS20030716/gcc/fixinc/server.c	2003-07-17 12:23:19.117628000 -0400
@@ -111,7 +111,7 @@ load_data (fp)
           size_t off = (size_t) (pz_scan - pz_text);
 	  
           text_size += 4096;
-          pz_text = xrealloc ((void *) pz_text, text_size);
+          pz_text = xrealloc (pz_text, text_size);
           pz_scan = pz_text + off;
         }
     }
@@ -126,7 +126,7 @@ load_data (fp)
   while ((pz_scan > pz_text) && ISSPACE (pz_scan[-1]))
     pz_scan--;
   *pz_scan = NUL;
-  return xrealloc ((void *) pz_text, strlen (pz_text) + 1);
+  return xrealloc (pz_text, strlen (pz_text) + 1);
 }
 
 
diff -rup orig/egcc-CVS20030716/gcc/objc/objc-act.c egcc-CVS20030716/gcc/objc/objc-act.c
--- orig/egcc-CVS20030716/gcc/objc/objc-act.c	2003-07-14 20:06:58.000000000 -0400
+++ egcc-CVS20030716/gcc/objc/objc-act.c	2003-07-17 23:49:07.647641000 -0400
@@ -4472,7 +4472,7 @@ synth_id_with_class_suffix (preamble, ct
     {
       const char *const class_name
 	= IDENTIFIER_POINTER (CLASS_NAME (objc_implementation_context));
-      string = (char *) alloca (strlen (preamble) + strlen (class_name) + 3);
+      string = alloca (strlen (preamble) + strlen (class_name) + 3);
       sprintf (string, "%s_%s", preamble,
 	       IDENTIFIER_POINTER (CLASS_NAME (ctxt)));
     }
@@ -4484,17 +4484,14 @@ synth_id_with_class_suffix (preamble, ct
 	= IDENTIFIER_POINTER (CLASS_NAME (objc_implementation_context));
       const char *const class_super_name
 	= IDENTIFIER_POINTER (CLASS_SUPER_NAME (objc_implementation_context));
-      string = (char *) alloca (strlen (preamble)
-				+ strlen (class_name)
-				+ strlen (class_super_name)
-				+ 3);
+      string = alloca (strlen (preamble) + strlen (class_name)
+		       + strlen (class_super_name) + 3);
       sprintf (string, "%s_%s_%s", preamble, class_name, class_super_name);
     }
   else if (TREE_CODE (ctxt) == PROTOCOL_INTERFACE_TYPE)
     {
       const char *protocol_name = IDENTIFIER_POINTER (PROTOCOL_NAME (ctxt));
-      string
-	= (char *) alloca (strlen (preamble) + strlen (protocol_name) + 3);
+      string = alloca (strlen (preamble) + strlen (protocol_name) + 3);
       sprintf (string, "%s_%s", preamble, protocol_name);
     }
   else
@@ -4616,7 +4613,7 @@ build_keyword_selector (selector)
 	len++;
     }
 
-  buf = (char *) alloca (len + 1);
+  buf = alloca (len + 1);
   /* Start the buffer out as an empty string.  */
   buf[0] = '\0';
 
@@ -5430,8 +5427,8 @@ hash_func (sel_name)
 static void
 hash_init ()
 {
-  nst_method_hash_list = (hash *) ggc_calloc (SIZEHASHTABLE, sizeof (hash));
-  cls_method_hash_list = (hash *) ggc_calloc (SIZEHASHTABLE, sizeof (hash));
+  nst_method_hash_list = ggc_calloc (SIZEHASHTABLE, sizeof (hash));
+  cls_method_hash_list = ggc_calloc (SIZEHASHTABLE, sizeof (hash));
 }
 
 /* WARNING!!!!  hash_enter is called with a method, and will peek
@@ -5447,7 +5444,7 @@ hash_enter (hashlist, method)
   hash obj;
   int slot = hash_func (METHOD_SEL_NAME (method)) % SIZEHASHTABLE;
 
-  obj = (hash) ggc_alloc (sizeof (struct hashed_entry));
+  obj = ggc_alloc (sizeof (struct hashed_entry));
   obj->list = 0;
   obj->next = hashlist[slot];
   obj->key = method;
@@ -5481,7 +5478,7 @@ hash_add_attr (entry, value)
 {
   attr obj;
 
-  obj = (attr) ggc_alloc (sizeof (struct hashed_attribute));
+  obj = ggc_alloc (sizeof (struct hashed_attribute));
   obj->next = entry->list;
   obj->value = value;
 
@@ -6270,7 +6267,7 @@ continue_class (class)
       if (!objc_class_template)
 	build_class_template ();
 
-      imp_entry = (struct imp_entry *) ggc_alloc (sizeof (struct imp_entry));
+      imp_entry = ggc_alloc (sizeof (struct imp_entry));
 
       imp_entry->next = imp_list;
       imp_entry->imp_context = class;
@@ -6366,7 +6363,7 @@ finish_class (class)
     {
       tree decl_specs;
       const char *class_name = IDENTIFIER_POINTER (CLASS_NAME (class));
-      char *string = (char *) alloca (strlen (class_name) + 3);
+      char *string = alloca (strlen (class_name) + 3);
 
       /* extern struct objc_object *_<my_name>; */
 
@@ -7120,8 +7117,8 @@ really_start_method (method, parmlist)
   method_slot++;
 
   /* Make sure this is big enough for any plausible method label.  */
-  buf = (char *) alloca (50 + strlen (sel_name) + strlen (class_name)
-			 + (cat_name ? strlen (cat_name) : 0));
+  buf = alloca (50 + strlen (sel_name) + strlen (class_name)
+		+ (cat_name ? strlen (cat_name) : 0));
 
   OBJC_GEN_METHOD_LABEL (buf, TREE_CODE (method) == INSTANCE_METHOD_DECL,
 			 class_name, cat_name, sel_name, method_slot);
@@ -8058,7 +8055,7 @@ dump_interface (fp, chain)
      declaration is so long that it doesn't fit in the buffer.  The
      code and all the related functions should be rewritten to avoid
      using fixed size buffers.  */
-  char *buf = (char *) xmalloc (1024 * 10);
+  char *buf = xmalloc (1024 * 10);
   const char *my_name = IDENTIFIER_POINTER (CLASS_NAME (chain));
   tree ivar_decls = CLASS_RAW_IVARS (chain);
   tree nst_methods = CLASS_NST_METHODS (chain);
@@ -8184,7 +8181,7 @@ init_objc ()
   gcc_obstack_init (&util_obstack);
   util_firstobj = (char *) obstack_finish (&util_obstack);
 
-  errbuf = (char *) xmalloc (BUFSIZE);
+  errbuf = xmalloc (BUFSIZE);
   hash_init ();
   synth_module_prologue ();
 }
@@ -8364,7 +8361,7 @@ handle_class_ref (chain)
      tree chain;
 {
   const char *name = IDENTIFIER_POINTER (TREE_VALUE (chain));
-  char *string = (char *) alloca (strlen (name) + 30);
+  char *string = alloca (strlen (name) + 30);
   tree decl;
   tree exp;
 
@@ -8414,7 +8411,7 @@ handle_impent (impent)
       const char *const class_name =
 	IDENTIFIER_POINTER (CLASS_NAME (impent->imp_context));
 
-      string = (char *) alloca (strlen (class_name) + 30);
+      string = alloca (strlen (class_name) + 30);
 
       sprintf (string, "%sobjc_class_name_%s",
                (flag_next_runtime ? "." : "__"), class_name);
@@ -8426,7 +8423,7 @@ handle_impent (impent)
       const char *const class_super_name =
         IDENTIFIER_POINTER (CLASS_SUPER_NAME (impent->imp_context));
 
-      string = (char *) alloca (strlen (class_name)
+      string = alloca (strlen (class_name)
 				+ strlen (class_super_name) + 30);
 
       /* Do the same for categories.  Even though no references to
diff -rup orig/egcc-CVS20030716/gcc/treelang/treetree.c egcc-CVS20030716/gcc/treelang/treetree.c
--- orig/egcc-CVS20030716/gcc/treelang/treetree.c	2003-07-10 14:01:04.000000000 -0400
+++ egcc-CVS20030716/gcc/treelang/treetree.c	2003-07-18 00:44:56.546648000 -0400
@@ -1124,8 +1124,7 @@ void
 pushlevel (ignore)
      int ignore ATTRIBUTE_UNUSED;
 {
-  struct binding_level *newlevel
-    = (struct binding_level *) xmalloc (sizeof (struct binding_level));
+  struct binding_level *newlevel = xmalloc (sizeof (struct binding_level));
 
   *newlevel = clear_binding_level;
 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]