Build warning: there are no arguments to ‘_’ that depend on a template parameter

Bug #666175 reported by Olorin on 2010-10-25
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Steven Sheehy

Bug Description


Olorin (vivliofika) wrote :
Steven Sheehy (steven-sheehy) wrote :

./dcpp/Streams.h:140: warning: there are no arguments to ‘_’ that depend on a template parameter, so a declaration of ‘_’ must be available

That warning has been there forever and is not that easy to fix. But marking confirmed anyway to track it and in the hope that someone else fixes it. :)

Changed in linuxdcpp:
importance: Undecided → Low
status: New → Confirmed
summary: - got some warnings building the dc
+ Build warning: there are no arguments to ‘_’ that depend on a template
+ parameter
tags: added: build warning
Steven Sheehy (steven-sheehy) wrote :

Committed a fix to dcplusplus.

tags: added: core
Changed in dcplusplus:
assignee: nobody → Steven Sheehy (steven-sheehy)
importance: Undecided → Low
status: New → Fix Committed
poy (poy) wrote :

that '_' is a #define normally replaced at compile time; that the compiler is actually trying to match it as some valid token shows that the file that #defines '_', DCPlusPlus.h, has not been included.
this is most likely a case of including stdinc.h but not DCPlusPlus.h; i suggest you modify your precompiled headers to include both stdinc.h & DCPlusPlus.h (see the top of win32/stdafx.h).

Steven Sheehy (steven-sheehy) wrote :

We do include stdinc.h before DCPlusPlus.h. This error started occurring after we merged .705 or 707 in awhile ago. We had to add -fpermissive in order to ignore the error and just make it a warning. I know '_' is gettext and is already defined by the time Streams.h is processed. I know this since if I add #define _(x) x it warns that I'm redefining '_'. The issue is more nuanced than include order:

Steven Sheehy (steven-sheehy) wrote :

Hmm...nevermind. It is include order. :)

Since we don't (and won't) define BUILDING_DCPP for gui files, we need to include gettext.h before DCPlusPlus.h. Sorry for the mess.

Changed in dcplusplus:
assignee: Steven Sheehy (steven-sheehy) → nobody
importance: Low → Undecided
status: Fix Committed → Invalid
Olorin (vivliofika) wrote :

It still there... :(

Steven Sheehy (steven-sheehy) wrote :

It's only fixed in linuxdcpp-i18n branch for now.

Changed in linuxdcpp:
assignee: nobody → Steven Sheehy (steven-sheehy)
milestone: none → 1.1.0
status: Confirmed → Fix Committed
Changed in linuxdcpp:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments