Skip to content

Commit

Permalink
Make iscomplex return bool
Browse files Browse the repository at this point in the history
  • Loading branch information
yebblies committed Nov 15, 2013
1 parent 93b5869 commit 469c7bd
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions src/mtype.c
Original file line number Diff line number Diff line change
Expand Up @@ -1727,9 +1727,9 @@ bool Type::isimaginary()
return false;
}

int Type::iscomplex()
bool Type::iscomplex()
{
return FALSE;
return false;
}

int Type::isscalar()
Expand Down Expand Up @@ -3317,9 +3317,9 @@ bool TypeBasic::isimaginary()
return (flags & TFLAGSimaginary) != 0;
}

int TypeBasic::iscomplex()
bool TypeBasic::iscomplex()
{
return flags & TFLAGScomplex;
return (flags & TFLAGScomplex) != 0;
}

bool TypeBasic::isunsigned()
Expand Down Expand Up @@ -7505,7 +7505,7 @@ bool TypeEnum::isimaginary()
return sym->memtype->isimaginary();
}

int TypeEnum::iscomplex()
bool TypeEnum::iscomplex()
{
return sym->memtype->iscomplex();
}
Expand Down Expand Up @@ -7728,7 +7728,7 @@ bool TypeTypedef::isimaginary()
return sym->basetype->isimaginary();
}

int TypeTypedef::iscomplex()
bool TypeTypedef::iscomplex()
{
return sym->basetype->iscomplex();
}
Expand Down
8 changes: 4 additions & 4 deletions src/mtype.h
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ class Type : public RootObject
virtual bool isfloating(); // real, imaginary, or complex
virtual bool isreal();
virtual bool isimaginary();
virtual int iscomplex();
virtual bool iscomplex();
virtual int isscalar();
virtual bool isunsigned();
virtual int isscope();
Expand Down Expand Up @@ -409,7 +409,7 @@ class TypeBasic : public Type
bool isfloating();
bool isreal();
bool isimaginary();
int iscomplex();
bool iscomplex();
int isscalar();
bool isunsigned();
MATCH implicitConvTo(Type *to);
Expand Down Expand Up @@ -894,7 +894,7 @@ class TypeEnum : public Type
bool isfloating();
bool isreal();
bool isimaginary();
int iscomplex();
bool iscomplex();
int isscalar();
bool isunsigned();
int checkBoolean();
Expand Down Expand Up @@ -942,7 +942,7 @@ class TypeTypedef : public Type
bool isfloating();
bool isreal();
bool isimaginary();
int iscomplex();
bool iscomplex();
int isscalar();
bool isunsigned();
int checkBoolean();
Expand Down

0 comments on commit 469c7bd

Please sign in to comment.