c++11 build fixes

Bug #858814 reported by Pippijn van Steenhoven
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
Medium
Pippijn van Steenhoven

Bug Description

Some semantics changed in the new C++ standard. In one case, a GCC extension is now in the standard, but using a different syntax. In the attached patch, I fixed them in a quick (and in some cases dirty) fashion. You may choose to fix them in a different way. In at least one case, I would suggest another way, but it would have taken another half rebuild. This patch should apply to trunk, cleanly.

To get a failing build, I used GCC 4.6 (it probably fails with 4.5 and 4.4 and maybe 4.3) in C++0x mode (-std=c++0x).

Tags: build
Revision history for this message
Pippijn van Steenhoven (pippijn) wrote :
su_v (suv-lp)
tags: added: build
description: updated
su_v (suv-lp)
Changed in inkscape:
importance: Undecided → Wishlist
Revision history for this message
Alex Valavanis (valavanisalex) wrote :

Thanks for your patch, and sorry it has taken so long to review!

I've made a couple of updates so that it applies cleanly to trunk and uses the __cplusplus macro to test C++ standard (the macro is part of the C++ standard rather than a GCC thing).

Committed in lp:inkscape r12166.

Changed in inkscape:
assignee: nobody → Pippijn van Steenhoven (pippijn)
importance: Wishlist → Medium
milestone: none → 0.49
status: New → Fix Committed
Revision history for this message
Samuel Chase (samebchase) wrote :

Approximately from when onwards will it be alright for C++11 features to be used in Inkscape (trunk)?

Revision history for this message
Alex Valavanis (valavanisalex) wrote :

Well, I guess the short answer is whenever there are C++11-compliant compilers readily available on supported platforms. It should be fine already for linux, but I don't know about OS X or Win. When clang support is ready, that'll be a big step in the right direction for OS X.

Bryce Harrington (bryce)
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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