Skip to content

Commit

Permalink
Declarative: Fix compiler warnings.
Browse files Browse the repository at this point in the history
- Unused parameters, variables
- Usage of deprecated QAtomic::operator=(int)

Change-Id: I2861968dac8ef8a3126783e3447c593808116871
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
  • Loading branch information
Friedemann Kleint authored and Qt by Nokia committed Nov 7, 2011
1 parent 29e0b65 commit b68d596
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/declarative/debugger/qdeclarativedebugtrace.cpp
Expand Up @@ -91,13 +91,13 @@ QDeclarativeDebugTrace::~QDeclarativeDebugTrace()
{
}

void QDeclarativeDebugTrace::addEngine(QDeclarativeEngine * /*engine*/)
void QDeclarativeDebugTrace::addEngine(QDeclarativeEngine *)
{
// just make sure that the service is properly registered
traceInstance();
}

void QDeclarativeDebugTrace::removeEngine(QDeclarativeEngine */*engine*/)
void QDeclarativeDebugTrace::removeEngine(QDeclarativeEngine *)
{

}
Expand Down
4 changes: 2 additions & 2 deletions src/declarative/qml/v4/qv4irbuilder.cpp
Expand Up @@ -51,7 +51,7 @@ QT_BEGIN_NAMESPACE

using namespace QDeclarativeJS;

static IR::Type irTypeFromVariantType(int t, QDeclarativeEnginePrivate *engine, const QMetaObject *meta)
static IR::Type irTypeFromVariantType(int t, QDeclarativeEnginePrivate *engine, const QMetaObject * /* meta */)
{
switch (t) {
case QMetaType::Bool:
Expand All @@ -74,7 +74,7 @@ static IR::Type irTypeFromVariantType(int t, QDeclarativeEnginePrivate *engine,
return IR::AnchorLineType;
else if (t == qMetaTypeId<QQuickAnchorLine>())
return IR::SGAnchorLineType;
else if (const QMetaObject *m = engine->metaObjectForType(t)) {
else if (engine->metaObjectForType(t)) {
return IR::ObjectType;
}

Expand Down
4 changes: 2 additions & 2 deletions src/imports/testlib/main.cpp
Expand Up @@ -165,7 +165,7 @@ class QTestQmlModule : public QDeclarativeExtensionPlugin
qmlRegisterType<QuickTestUtil>(uri,1,0,"TestUtil");
}

void initializeEngine(QDeclarativeEngine *engine, const char *)
void initializeEngine(QDeclarativeEngine *, const char *)
{
}
};
Expand All @@ -174,4 +174,4 @@ QT_END_NAMESPACE

#include "main.moc"

Q_EXPORT_PLUGIN2(qmltestplugin, QT_PREPEND_NAMESPACE(QTestQmlModule));
Q_EXPORT_PLUGIN2(qmltestplugin, QT_PREPEND_NAMESPACE(QTestQmlModule))
2 changes: 1 addition & 1 deletion tools/qmlviewer/main.cpp
Expand Up @@ -84,7 +84,7 @@ void myMessageOutput(QtMsgType type, const char *msg)
if (!logger.isNull()) {
if (recursiveLock.testAndSetOrdered(0, 1)) {
QMetaObject::invokeMethod(logger.data(), "append", Q_ARG(QString, strMsg));
recursiveLock = 0;
recursiveLock.store(0);
}
} else {
warnings += strMsg;
Expand Down

0 comments on commit b68d596

Please sign in to comment.