Commit ec996300 authored by Friedemann Kleint's avatar Friedemann Kleint
Browse files

Merge branch 'master' of git@scm.dev.nokia.troll.no:creator/mainline

parents 024b548e 1219b31e
......@@ -21,7 +21,7 @@ public slots:
//! [private members]
private:
Ui::FindDialog *m_ui;\
Ui::FindDialog *m_ui;
QPushButton *findButton;
QLineEdit *lineEdit;
QString findText;
......
......@@ -739,6 +739,10 @@ void Preprocessor::preprocess(const QString &fileName, const QByteArray &source,
env->currentLine = 0;
while (true) {
if (_dot->joined)
out("\\");
processNewline();
if (_dot->is(T_EOF_SYMBOL)) {
......@@ -766,10 +770,7 @@ void Preprocessor::preprocess(const QString &fileName, const QByteArray &source,
} else {
if (_dot->joined)
out("\\\n");
else if (_dot->whitespace) {
if (_dot->whitespace) {
const unsigned endOfPreviousToken = (_dot - 1)->end();
const unsigned beginOfToken = _dot->begin();
......
......@@ -264,7 +264,7 @@ void CppFileSettingsWidget::slotEdit()
if (path.isEmpty())
return;
QFile file(path);
if (!file.open(QIODevice::ReadWrite|QIODevice::Text|QIODevice::Truncate)) {
if (!file.open(QIODevice::WriteOnly|QIODevice::Text|QIODevice::Truncate)) {
QMessageBox::warning(this, tr("Template write error"),
tr("Cannot write to %1: %2").arg(path, file.errorString()));
return;
......
......@@ -1626,7 +1626,7 @@ bool Parser::parseBaseClause(BaseSpecifierAST *&node)
if (parseBaseSpecifier(*ast)) {
(*ast)->comma_token = comma_token;
ast = &(*ast)->next;\
ast = &(*ast)->next;
}
}
}
......
......@@ -39,10 +39,9 @@ public:
void addInclude(const QString &absoluteFilePath)
{ included.append(absoluteFilePath); }
virtual void sourceNeeded(QString &fileName, IncludeType mode, unsigned line)
virtual void sourceNeeded(QString &fileName, IncludeType mode, unsigned)
{
// ### cache
const QString currentFile = QFile::decodeName(env->currentFile);
const QString currentFile = env->currentFile;
if (mode == IncludeLocal) {
const QFileInfo currentFileInfo(currentFile);
......@@ -115,7 +114,7 @@ int main(int argc, char *argv[])
client.addSystemDir(qgetenv("QTDIR") + "/include");
Preprocessor preproc(&client, &env);
preproc.preprocess(QFile::encodeName(fn), code, /*result = */ 0);
preproc.preprocess(fn, code, /*result = */ 0);
deps = client.includedFiles();
todo += deps;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment