Bug 39346 - telepathy-qt fails to build with clang
Summary: telepathy-qt fails to build with clang
Status: RESOLVED FIXED
Alias: None
Product: Telepathy
Classification: Unclassified
Component: tp-qt (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) FreeBSD
: medium normal
Assignee: Telepathy bugs list
QA Contact: Telepathy bugs list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-18 11:00 UTC by Pawel Worach
Modified: 2012-02-14 07:38 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Patch (against a 0.8 release?) (1.00 KB, patch)
2012-01-17 03:59 UTC, Olli Salli
Details | Splinter Review

Description Pawel Worach 2011-07-18 11:00:30 UTC
Building telepathy-qt4 0.7.1 with llvm/clang trunk r135391 on FreeBSD/amd64 results in:

n file included from /work/a/ports/net-im/telepathy-qt4/work/telepathy-qt4-0.7.1/TelepathyQt4/optional-interface-factory.cpp:23:
In file included from /work/a/ports/net-im/telepathy-qt4/work/telepathy-qt4-0.7.1/TelepathyQt4/OptionalInterfaceFactory:8:
/work/a/ports/net-im/telepathy-qt4/work/telepathy-qt4-0.7.1/TelepathyQt4/optional-interface-factory.h:100:21: warning: parentheses were disambiguated as a function declarator
        QString name(QLatin1String(Interface::staticInterfaceName()));
                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/work/a/ports/net-im/telepathy-qt4/work/telepathy-qt4-0.7.1/TelepathyQt4/optional-interface-factory.h:100:47: error: parameter declarator cannot be qualified
        QString name(QLatin1String(Interface::staticInterfaceName()));
                                   ~~~~~~~~~~~^
/work/a/ports/net-im/telepathy-qt4/work/telepathy-qt4-0.7.1/TelepathyQt4/optional-interface-factory.h:116:21: warning: parentheses were disambiguated as a function declarator
        QString name(QLatin1String(Interface::staticInterfaceName()));
                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/work/a/ports/net-im/telepathy-qt4/work/telepathy-qt4-0.7.1/TelepathyQt4/optional-interface-factory.h:116:47: error: parameter declarator cannot be qualified
        QString name(QLatin1String(Interface::staticInterfaceName()));
                                   ~~~~~~~~~~~^
[ 48%] 2 warnings and 2 errors generated.
*** Error code 1
Comment 1 Thomas Flüeli 2012-01-16 03:53:19 UTC
The same errors occur with Visual Studio on Windows. Bug 31200 contains a (probably outdated) patch (attachment 39860 [details] [review]).
Comment 2 Olli Salli 2012-01-17 03:59:25 UTC
Created attachment 55669 [details] [review]
Patch (against a 0.8 release?)

I got this patch by email, please review, forward port to master as well, and integrate somebody?

--

Hello!

The attached patch fixes two instances of most vexing parse not caught by 
GCC (but caught by Clang).

Regards.
-- Alberto Villa, FreeBSD committer <avilla@FreeBSD.org> http://people.FreeBSD.org/~avilla Whatever occurs from love is always beyond good and evil. -- Friedrich Nietzsche
Comment 3 Andre Moreira Magalhaes 2012-02-14 07:38:02 UTC
Fixed upstream. It will be in tp-qt 0.9.1.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.