Bug 101816

Summary: Add nullptr support for VS2008
Product: poppler Reporter: Thomas Freitag <Thomas.Freitag>
Component: generalAssignee: poppler-bugs <poppler-bugs>
Status: RESOLVED INVALID QA Contact:
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: Other   
OS: Windows (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: nullptr patch

Description Thomas Freitag 2017-07-17 10:05:24 UTC
Created attachment 132729 [details] [review]
nullptr patch

Actual poppler can't be compiled anymore with VS2008 on windows. Reason for it is the usage of nullptr, which was introduced not before VS2010.
To make it compilable with VS2008 again, this patch uses an idea from Scott Meyers c++ book where he suggests to use a header with a class that emulates nullptr.

This has the advantage of using the same keyword and makes upgrading to a new compiler visual studio a fair bit easier.
Comment 1 Adrian Johnson 2017-07-17 11:12:24 UTC
Do we really want to support a 10 year old compiler? Poppler is now using C++11 so it is likely other C++11 features will be added in future that will break VS2008 builds.
Comment 2 Albert Astals Cid 2017-07-17 15:22:40 UTC
I'm with Adrian, the compiler is old and new VS versions are free AFAIk, so why not just use a newer compiler?

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.