+2003-07-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * fixinc/fixfixes.c fixinc/fixincl.c fixinc/fixlib.c
+ fixinc/server.c objc/objc-act.c: Remove unnecessary casts.
+
2003-07-19 Ulrich Weigand <uweigand@de.ibm.com>
* config/s390/s390.c (legitimize_pic_address): Access local symbols
+2003-07-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * 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.
+
2003-07-18 Nathan Sidwell <nathan@codesourcery.com>
* cp-tree.h (finish_non_static_data_member): Add object param.
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;
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;
{
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. */
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);
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;
|| 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;
/* 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;
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;
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;
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
{
/* 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,
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++)
{
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)
{
/* 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;
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);
}
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;
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;
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;
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;
{
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;
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. */
/* 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)
{
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. */
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. */
/* 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.
/* 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
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);
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]));
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;
}
{
/* 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));
}
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++)
{
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)
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;
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. */
+Sat Jul 19 12:03:03 2003 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * 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.
+
Thu Jul 17 06:34:41 2003 Neil Booth <neil@daikokuya.co.uk>
* lang-options.h: Remove.
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 ();
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 ();
}
else
{
- dir = (char *) xmalloc (p - filename + 1);
+ dir = xmalloc (p - filename + 1);
memcpy (dir, filename, p - filename);
dir[p - filename] = '\0';
from = p + 1;
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;
;
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. */
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;
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;
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;
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_,
{
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;
/* 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;
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)
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;
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;
}
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;
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;
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];
}
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];
}
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;
if (buffer_length == 0)
{
- directive_buffer = (char *)xmalloc (128);
+ directive_buffer = xmalloc (128);
buffer_length = 128;
}
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];
}
++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;
}
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;
{
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;
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)
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);
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++;
/* 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;
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)
{
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;
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;
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;
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
{
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;
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
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;
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);
#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) \
{ \
#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) \
{ \
{
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;
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;
}
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;
}
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
{
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");
+ 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 );
}
/* 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;
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,
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;
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);
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;
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;
}
}
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);
}
+2003-07-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * class.c java-tree.h jcf-write.c jvspec.c: Remove unnecessary
+ casts.
+
2003-07-19 Neil Booth <neil@daikokuya.co.uk>
* lang.opt: Don't show -MD_ and -MDD_.
{
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;
{
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
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; \
}
#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)
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);
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;
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);
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);
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;
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);
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;
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;
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)
}
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
{
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)));
}
= 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
len++;
}
- buf = (char *) alloca (len + 1);
+ buf = alloca (len + 1);
/* Start the buffer out as an empty string. */
buf[0] = '\0';
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
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;
{
attr obj;
- obj = (attr) ggc_alloc (sizeof (struct hashed_attribute));
+ obj = ggc_alloc (sizeof (struct hashed_attribute));
obj->next = entry->list;
obj->value = value;
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;
{
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>; */
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);
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);
gcc_obstack_init (&util_obstack);
util_firstobj = (char *) obstack_finish (&util_obstack);
- errbuf = (char *) xmalloc (BUFSIZE);
+ errbuf = xmalloc (BUFSIZE);
hash_init ();
synth_module_prologue ();
}
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;
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);
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
+2003-07-19 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * treetree.c: Remove unnecessary casts.
+
2003-07-15 Neil Booth <neil@daikokuya.co.uk>
* lang-options.h: Remove.
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;