Remove redundant IsValid() checks from wxDateTime comparison methods
They're not necessary as GetValue() asserts when passed an invalid object anyhow, there is no need to check for this twice.
This commit is contained in:
parent
e3f1423632
commit
d47efc42ff
1 changed files with 0 additions and 6 deletions
|
|
@ -816,37 +816,31 @@ public:
|
|||
|
||||
inline bool operator<(const wxDateTime& dt) const
|
||||
{
|
||||
wxASSERT_MSG( IsValid() && dt.IsValid(), wxT("invalid wxDateTime") );
|
||||
return GetValue() < dt.GetValue();
|
||||
}
|
||||
|
||||
inline bool operator<=(const wxDateTime& dt) const
|
||||
{
|
||||
wxASSERT_MSG( IsValid() && dt.IsValid(), wxT("invalid wxDateTime") );
|
||||
return GetValue() <= dt.GetValue();
|
||||
}
|
||||
|
||||
inline bool operator>(const wxDateTime& dt) const
|
||||
{
|
||||
wxASSERT_MSG( IsValid() && dt.IsValid(), wxT("invalid wxDateTime") );
|
||||
return GetValue() > dt.GetValue();
|
||||
}
|
||||
|
||||
inline bool operator>=(const wxDateTime& dt) const
|
||||
{
|
||||
wxASSERT_MSG( IsValid() && dt.IsValid(), wxT("invalid wxDateTime") );
|
||||
return GetValue() >= dt.GetValue();
|
||||
}
|
||||
|
||||
inline bool operator==(const wxDateTime& dt) const
|
||||
{
|
||||
wxASSERT_MSG( IsValid() && dt.IsValid(), wxT("invalid wxDateTime") );
|
||||
return GetValue() == dt.GetValue();
|
||||
}
|
||||
|
||||
inline bool operator!=(const wxDateTime& dt) const
|
||||
{
|
||||
wxASSERT_MSG( IsValid() && dt.IsValid(), wxT("invalid wxDateTime") );
|
||||
return GetValue() != dt.GetValue();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue