C++: Use more direct approach to recognize special Qt tokens

Change-Id: I45399a196500cbc6aecedfaa94a50890914906f1
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
This commit is contained in:
hjk
2013-04-16 18:10:35 +02:00
parent 080bf4ecb8
commit 357ffaa8bc
3 changed files with 60 additions and 58 deletions

View File

@@ -58,12 +58,7 @@ public:
ByteArrayRef(const QByteArray *ref, int offset, int length)
: m_start(ref->constData() + offset)
, m_length(length)
{
Q_ASSERT(ref);
Q_ASSERT(offset >= 0);
Q_ASSERT(length >= 0);
Q_ASSERT(offset + length <= ref->size());
}
{}
inline const char *start() const
{ return m_start; }