compilation with Clang 3.4 fails due to improper definition of bisector_end_set in live_effects/lpe-perp_bisector.h

Bug #1298994 reported by Cluebat
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
New
Undecided
Unassigned

Bug Description

Error:
In file included from live_effects/effect.cpp:62:
./live_effects/lpe-perp_bisector.h:49:21: error: friend declaration specifying a default argument must be the only declaration
    friend void PB::bisector_end_set(SPItem *item, Geom::Point const &p, bool left = true);
                    ^
./live_effects/lpe-perp_bisector.h:30:8: note: previous declaration is here
  void bisector_end_set(SPItem *item, Geom::Point const &p, bool left);
       ^
1 error generated.

Solution:
Set default value on first declaration.
Thus, line 30 should be
    void bisector_end_set(SPItem *item, Geom::Point const &p, bool left = true);
and line 49 should be
    friend void PB::bisector_end_set(SPItem *item, Geom::Point const &p, bool left);

Tags: build
Revision history for this message
Cluebat (cluebattin) wrote :
summary: - compilation with Clang 3.4 fails due to imporeoper definition of
+ compilation with Clang 3.4 fails due to improper definition of
bisector_end_set in live_effects/lpe-perp_bisector.h
Revision history for this message
su_v (suv-lp) wrote :

See
<http://bazaar.launchpad.net/~inkscape.dev/inkscape/RELEASE_0_48_BRANCH/revision/10019#src/live_effects/lpe-perp_bisector.h>

Since lp:inkscape/0.48.x r10019 was part of the changes to fix bug #1293169, proposing to mark this as duplicate.

[ Please always provide information about the affected inkscape version, thx. AFAICT this change is not needed in trunk ]

tags: added: build
Revision history for this message
Cluebat (cluebattin) wrote :

I searched for Clang, lpe-perp_bisector.h and bisector_set_end before filing this bug. None of those keywords got any hits. Bug 1293169 did not match since it mentions Xcode rather than Clang. Looking at that bug, I see the error messages are completely different so there is no obvious indication it is a dupe. I see it says a fix is committed, but I see no patch nor any link to the commit anywhere on that page, so I can't easily verify that commit would have any impact on the bug I reported. Only from the link in the comments on this bug do I see that the same change I proposed was already commited. Thank you for pointing that out. You would not have had to do so if the bug tracker was no so absurdly deficient. Also, I did not indicate the version because there was no mechanism by which to choose a version. I had experienced this on the most current released version, which has been out for quite some time.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.