diff liboctave/oct-alloc.cc @ 2800:9aeba8e006a4

[project @ 1997-03-09 09:50:20 by jwe]
author jwe
date Sun, 09 Mar 1997 09:50:39 +0000
parents 1d7925d6bede
children 8b262e771614
line wrap: on
line diff
--- a/liboctave/oct-alloc.cc
+++ b/liboctave/oct-alloc.cc
@@ -53,10 +53,10 @@
 octave_allocator::free (void *p, size_t size)
 {
   if (size != item_size)
-    ::delete [] ((char *) p);
+    ::delete [] (static_cast<char *> (p));
   else
     {
-      link *tmp = (link *) p;
+      link *tmp = static_cast<link *> (p);
       tmp->next = head;
       head = tmp;
     }
@@ -79,13 +79,13 @@
       while (p < last)
 	{
 	  char *next = p + item_size;
-	  ((link *) p) -> next = (link *) next;
+	  (static_cast<link *> (p)) -> next = static_cast<link *> (next);
 	  p = next;
 	}
 
-      ((link *) last) -> next = 0;
+      (static_cast<link *> (last)) -> next = 0;
 
-      head = (link *) start;
+      head = static_cast<link *> (start);
     }
   else
     {