summaryrefslogtreecommitdiff
path: root/src/xmlpatterns
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2012-12-21 23:58:50 -0800
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-01-02 10:57:39 +0100
commit8a95cb56f5ecadb450de545061e8444e9698d21f (patch)
treefc460fbf4809e36abe0c6538a973253fac1db84e /src/xmlpatterns
parent7b1f8df5fa8ea5346315f999097b19836d7eac19 (diff)
downloadqtxmlpatterns-8a95cb56f5ecadb450de545061e8444e9698d21f.tar.gz
Fix warnings found in qtxmlpatterns by Clang
schema/qxsdstatemachine_tpl_p.h:186:71: error: unused parameter 'input' [-Werror,-Wunused-parameter] expr/qexpression.cpp:139:50: error: unused variable 'end' [-Werror,-Wunused-variable] projection/qdocumentprojector_p.h:84:22: error: 'QPatternist::DocumentProjector::attribute' hides overloaded virtual function [-Werror,-Woverloaded-virtual] Change-Id: I84021e4aa6bdca8dfcaa4c375845ceb24c33818b Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/xmlpatterns')
-rw-r--r--src/xmlpatterns/expr/qexpression.cpp2
-rw-r--r--src/xmlpatterns/projection/qdocumentprojector.cpp12
-rw-r--r--src/xmlpatterns/projection/qdocumentprojector_p.h12
-rw-r--r--src/xmlpatterns/schema/qxsdstatemachine_tpl_p.h2
4 files changed, 14 insertions, 14 deletions
diff --git a/src/xmlpatterns/expr/qexpression.cpp b/src/xmlpatterns/expr/qexpression.cpp
index b87f094..f469d89 100644
--- a/src/xmlpatterns/expr/qexpression.cpp
+++ b/src/xmlpatterns/expr/qexpression.cpp
@@ -136,7 +136,6 @@ Expression::Ptr Expression::invokeOptimizers(const Expression::Ptr &expr,
}
const OptimizationPass::List::const_iterator passEnd(opts.constEnd());
- const OptimizationPass::List::const_iterator end(opts.constEnd());
OptimizationPass::List::const_iterator passIt(opts.constBegin());
for(; passIt != passEnd; ++passIt) /* Invoke each optimization pass. */
@@ -151,7 +150,6 @@ Expression::Ptr Expression::invokeOptimizers(const Expression::Ptr &expr,
continue;
}
- const ExpressionIdentifier::List::const_iterator idEnd(pass->operandIdentifiers.constEnd());
ExpressionIdentifier::List::const_iterator idIt(pass->operandIdentifiers.constBegin());
const Expression::List ops(expr->operands());
const Expression::List::const_iterator opEnd(ops.constEnd());
diff --git a/src/xmlpatterns/projection/qdocumentprojector.cpp b/src/xmlpatterns/projection/qdocumentprojector.cpp
index 390329b..fe76838 100644
--- a/src/xmlpatterns/projection/qdocumentprojector.cpp
+++ b/src/xmlpatterns/projection/qdocumentprojector.cpp
@@ -58,7 +58,7 @@ DocumentProjector::DocumentProjector(const ProjectedExpression::Vector &paths,
Q_ASSERT(m_receiver);
}
-void DocumentProjector::startElement(const QXmlName name)
+void DocumentProjector::startElement(const QXmlName &name)
{
Q_UNUSED(name);
@@ -165,14 +165,14 @@ void DocumentProjector::endElement()
}
}
-void DocumentProjector::attribute(const QXmlName name,
- const QString &value)
+void DocumentProjector::attribute(const QXmlName &name,
+ const QStringRef &value)
{
Q_UNUSED(name);
Q_UNUSED(value);
}
-void DocumentProjector::namespaceBinding(const QXmlName nb)
+void DocumentProjector::namespaceBinding(const QXmlName &nb)
{
Q_UNUSED(nb);
}
@@ -184,12 +184,12 @@ void DocumentProjector::comment(const QString &value)
Q_UNUSED(value);
}
-void DocumentProjector::characters(const QString &value)
+void DocumentProjector::characters(const QStringRef &value)
{
Q_UNUSED(value);
}
-void DocumentProjector::processingInstruction(const QXmlName name,
+void DocumentProjector::processingInstruction(const QXmlName &name,
const QString &value)
{
Q_ASSERT_X(!value.contains(QLatin1String("?>")), Q_FUNC_INFO,
diff --git a/src/xmlpatterns/projection/qdocumentprojector_p.h b/src/xmlpatterns/projection/qdocumentprojector_p.h
index b15a699..2a5d411 100644
--- a/src/xmlpatterns/projection/qdocumentprojector_p.h
+++ b/src/xmlpatterns/projection/qdocumentprojector_p.h
@@ -72,19 +72,19 @@ namespace QPatternist
DocumentProjector(const ProjectedExpression::Vector &paths,
QAbstractXmlReceiver *const receiver);
- virtual void namespaceBinding(const QXmlName nb);
+ virtual void namespaceBinding(const QXmlName &nb);
- virtual void characters(const QString &value);
+ virtual void characters(const QStringRef &value);
virtual void comment(const QString &value);
- virtual void startElement(const QXmlName name);
+ virtual void startElement(const QXmlName &name);
virtual void endElement();
- virtual void attribute(const QXmlName name,
- const QString &value);
+ virtual void attribute(const QXmlName &name,
+ const QStringRef &value);
- virtual void processingInstruction(const QXmlName name,
+ virtual void processingInstruction(const QXmlName &name,
const QString &value);
virtual void item(const Item &item);
diff --git a/src/xmlpatterns/schema/qxsdstatemachine_tpl_p.h b/src/xmlpatterns/schema/qxsdstatemachine_tpl_p.h
index aa6f978..548654e 100644
--- a/src/xmlpatterns/schema/qxsdstatemachine_tpl_p.h
+++ b/src/xmlpatterns/schema/qxsdstatemachine_tpl_p.h
@@ -185,6 +185,8 @@ template <typename TransitionType>
template <typename InputType>
bool XsdStateMachine<TransitionType>::inputEqualsTransition(InputType input, TransitionType transition) const
{
+ Q_UNUSED(input);
+ Q_UNUSED(transition);
return false;
}