diff options
author | Thierry Bastian <thierry.bastian@nokia.com> | 2009-05-28 08:27:50 (GMT) |
---|---|---|
committer | Thierry Bastian <thierry.bastian@nokia.com> | 2009-05-28 08:31:07 (GMT) |
commit | f390f9b51cf8686e9ed44f13a33c7349b9e96a09 (patch) | |
tree | 162c768769713a7215bca64daf8f2bdc75c9fbee /src/xmlpatterns | |
parent | 0bb0699d403b7541472a72a4057ecf0ca366a7cd (diff) | |
download | Qt-f390f9b51cf8686e9ed44f13a33c7349b9e96a09.zip Qt-f390f9b51cf8686e9ed44f13a33c7349b9e96a09.tar.gz Qt-f390f9b51cf8686e9ed44f13a33c7349b9e96a09.tar.bz2 |
improved string operations all over the place
used character operations whenever possible
better usage of QLatin1String
Diffstat (limited to 'src/xmlpatterns')
-rw-r--r-- | src/xmlpatterns/acceltree/qacceltree.cpp | 14 | ||||
-rw-r--r-- | src/xmlpatterns/api/qsourcelocation.cpp | 2 | ||||
-rw-r--r-- | src/xmlpatterns/data/qabstractfloat.cpp | 2 | ||||
-rw-r--r-- | src/xmlpatterns/data/qcommonvalues.cpp | 2 | ||||
-rw-r--r-- | src/xmlpatterns/expr/qexpression_p.h | 2 |
5 files changed, 11 insertions, 11 deletions
diff --git a/src/xmlpatterns/acceltree/qacceltree.cpp b/src/xmlpatterns/acceltree/qacceltree.cpp index 60e6e27..6bc1794 100644 --- a/src/xmlpatterns/acceltree/qacceltree.cpp +++ b/src/xmlpatterns/acceltree/qacceltree.cpp @@ -71,7 +71,7 @@ void AccelTree::printStats(const NamePool::Ptr &np) const for(int i = 0; i < len; ++i) { const BasicNodeData &v = basicData.at(i); - pDebug() << "|" << i + pDebug() << '|' << i << "\t\t|" << v.depth() << "\t|" << v.size() << "\t|" << postNumber(i) @@ -81,12 +81,12 @@ void AccelTree::printStats(const NamePool::Ptr &np) const : data.value(i)) << "\t|"; /* - pDebug() << "|" << QString().arg(i, 14) - << "|" << QString().arg(v.depth(), 6) - << "|" << QString().arg(v.size(), 6) - << "|" << QString().arg(postNumber(i), 14) - << "|" << QString().arg(v.kind(), 6) - << "|"; + pDebug() << '|' << QString().arg(i, 14) + << '|' << QString().arg(v.depth(), 6) + << '|' << QString().arg(v.size(), 6) + << '|' << QString().arg(postNumber(i), 14) + << '|' << QString().arg(v.kind(), 6) + << '|'; */ } pDebug() << "+---------------+-------+-------+---------------+-------+--------------+"; diff --git a/src/xmlpatterns/api/qsourcelocation.cpp b/src/xmlpatterns/api/qsourcelocation.cpp index 4eee39c..1dd8ffd 100644 --- a/src/xmlpatterns/api/qsourcelocation.cpp +++ b/src/xmlpatterns/api/qsourcelocation.cpp @@ -206,7 +206,7 @@ QDebug operator<<(QDebug debug, const QSourceLocation &sourceLocation) << sourceLocation.line() << ", column:" << sourceLocation.column() - << ")"; + << ')'; return debug; } #endif diff --git a/src/xmlpatterns/data/qabstractfloat.cpp b/src/xmlpatterns/data/qabstractfloat.cpp index b6226b5..a45b0fd 100644 --- a/src/xmlpatterns/data/qabstractfloat.cpp +++ b/src/xmlpatterns/data/qabstractfloat.cpp @@ -186,7 +186,7 @@ QString AbstractFloat<isDouble>::stringValue() const if(sign) valueAsString += QLatin1Char('-'); - valueAsString += qret.left(1); + valueAsString += qret.at(0); valueAsString += QLatin1Char('.'); if(1 == qret.size()) diff --git a/src/xmlpatterns/data/qcommonvalues.cpp b/src/xmlpatterns/data/qcommonvalues.cpp index 07a273d..99a8086 100644 --- a/src/xmlpatterns/data/qcommonvalues.cpp +++ b/src/xmlpatterns/data/qcommonvalues.cpp @@ -57,7 +57,7 @@ using namespace QPatternist; // STATIC DATA const AtomicString::Ptr CommonValues::EmptyString - (new AtomicString(QString(QLatin1String("")))); + (new AtomicString(QLatin1String(""))); const AtomicString::Ptr CommonValues::TrueString (new AtomicString(QLatin1String("true"))); const AtomicString::Ptr CommonValues::FalseString diff --git a/src/xmlpatterns/expr/qexpression_p.h b/src/xmlpatterns/expr/qexpression_p.h index 5eb63de..65918e6 100644 --- a/src/xmlpatterns/expr/qexpression_p.h +++ b/src/xmlpatterns/expr/qexpression_p.h @@ -884,7 +884,7 @@ namespace QPatternist { pDebug() << "AST REWRITE:" << old.data() << "to" << New.data() << '(' << old->actualReflection() << "to" << New->actualReflection() << ", " - << old->description() << "to" << New->description() << ")"; + << old->description() << "to" << New->description() << ')'; /* The order of these two lines is significant.. */ context->addLocation(New.data(), context->locationFor(old->actualReflection())); |