mirror of
https://github.com/vim/vim.git
synced 2025-10-27 09:24:23 -04:00
patch 8.1.1393: unnecessary type casts
Problem: Unnecessary type casts. Solution: Remove type casts from alloc() and lalloc() calls. (Mike Williams)
This commit is contained in:
@@ -85,8 +85,7 @@ sign_group_ref(char_u *groupname)
|
||||
if (HASHITEM_EMPTY(hi))
|
||||
{
|
||||
// new group
|
||||
group = (signgroup_T *)alloc(
|
||||
(unsigned)(sizeof(signgroup_T) + STRLEN(groupname)));
|
||||
group = (signgroup_T *)alloc(sizeof(signgroup_T) + STRLEN(groupname));
|
||||
if (group == NULL)
|
||||
return NULL;
|
||||
STRCPY(group->sg_name, groupname);
|
||||
@@ -737,8 +736,7 @@ alloc_new_sign(char_u *name)
|
||||
int start = next_sign_typenr;
|
||||
|
||||
// Allocate a new sign.
|
||||
sp = (sign_T *)alloc_clear_id((unsigned)sizeof(sign_T),
|
||||
aid_sign_define_by_name);
|
||||
sp = (sign_T *)alloc_clear_id(sizeof(sign_T), aid_sign_define_by_name);
|
||||
if (sp == NULL)
|
||||
return NULL;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user