Skip to content

Commit

Permalink
Merge pull request #1995 from yebblies/typeparens
Browse files Browse the repository at this point in the history
[DDMD] Remove (type) where type is a variable
  • Loading branch information
dnadlinger committed May 9, 2013
2 parents ac167e1 + 25a6076 commit 9c0de28
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/func.c
Expand Up @@ -291,7 +291,7 @@ void FuncDeclaration::semantic(Scope *sc)
error("%s must be a function instead of %s", toChars(), type->toChars());
return;
}
f = (TypeFunction *)(type);
f = (TypeFunction *)type;
size_t nparams = Parameter::dim(f->parameters);

if (storage_class & STCscope)
Expand Down Expand Up @@ -902,7 +902,7 @@ void FuncDeclaration::semantic3(Scope *sc)

if (!type || type->ty != Tfunction)
return;
f = (TypeFunction *)(type);
f = (TypeFunction *)type;
if (!inferRetType && f->next->ty == Terror)
return;

Expand Down Expand Up @@ -1977,7 +1977,7 @@ void FuncDeclaration::buildResultVar()

assert(type->nextOf());
assert(type->nextOf()->toBasetype()->ty != Tvoid);
TypeFunction *tf = (TypeFunction *)(type);
TypeFunction *tf = (TypeFunction *)type;

Loc loc = this->loc;

Expand Down
2 changes: 1 addition & 1 deletion src/inline.c
Expand Up @@ -1474,7 +1474,7 @@ int FuncDeclaration::canInline(int hasthis, int hdrscan, int statementsToo)

if (type)
{ assert(type->ty == Tfunction);
TypeFunction *tf = (TypeFunction *)(type);
TypeFunction *tf = (TypeFunction *)type;
if (tf->varargs == 1) // no variadic parameter lists
goto Lno;

Expand Down

0 comments on commit 9c0de28

Please sign in to comment.