Bug 1115906, Part 1: Add workarounds for missing final/override support in GCC before version 4.7, r=keeler

--HG--
rename : security/pkix/include/pkix/nullptr.h => security/pkix/include/pkix/stdkeywords.h
extra : rebase_source : 9cacd9729ac4cfb1e4bf920c8afdffb831b60d36
extra : source : f673d05dfc9a6d830e5e3c01976b41588cc70ead
This commit is contained in:
Brian Smith 2015-01-07 14:53:11 -08:00
parent 235c27f622
commit 825d71887a
8 changed files with 18 additions and 10 deletions

View File

@ -10,7 +10,7 @@
#include "certdb.h"
#include "base64.h"
#include "hasht.h"
#include "pkix/nullptr.h"
#include "pkix/stdkeywords.h"
#include "pkix/pkixtypes.h"
#include "pk11pub.h"
#include "secerr.h"

View File

@ -13,7 +13,7 @@
#include "nsSiteSecurityService.h"
#include "nsString.h"
#include "nsTArray.h"
#include "pkix/nullptr.h"
#include "pkix/stdkeywords.h"
#include "pkix/pkixtypes.h"
#include "prlog.h"
#include "RootCertificateTelemetryUtils.h"

View File

@ -27,7 +27,7 @@
#include <cstring>
#include "pkix/nullptr.h"
#include "pkix/stdkeywords.h"
#include "pkix/Result.h"
#include "stdint.h"

View File

@ -25,7 +25,7 @@
#ifndef mozilla_pkix__ScopedPtr_h
#define mozilla_pkix__ScopedPtr_h
#include "pkix/nullptr.h"
#include "pkix/stdkeywords.h"
namespace mozilla { namespace pkix {

View File

@ -30,6 +30,7 @@
#include <stdint.h>
#include "pkix/Result.h"
#include "pkix/stdkeywords.h"
namespace mozilla { namespace pkix {

View File

@ -22,14 +22,22 @@
* limitations under the License.
*/
#ifndef mozilla_pkix__nullptr_h
#define mozilla_pkix__nullptr_h
#ifndef mozilla_pkix__stdkeywords_h
#define mozilla_pkix__stdkeywords_h
#if defined(__GNUC__) && !defined(__clang__)
// GCC does not understand nullptr until 4.6
#if defined(__GNUC__) && !defined(__clang__)
#if __GNUC__ * 100 + __GNUC_MINOR__ < 406
#define nullptr __null
#endif
// GCC does not understand final/override until 4.7
#if __GNUC__ * 100 + __GNUC_MINOR__ < 407
#define final
#define override
#endif
#endif // mozilla_pkix__nullptr_h
#endif // defined(__GNUC__) && !defined(__clang__)
#endif // mozilla_pkix__stdkeywords_h

View File

@ -24,7 +24,7 @@
#include "pkix/Result.h"
#include "pkix/nullptr.h"
#include "pkix/stdkeywords.h"
namespace mozilla { namespace pkix {

View File

@ -26,7 +26,6 @@
#include <ctime>
#include "pkix/nullptr.h"
#include "pkix/Time.h"
namespace mozilla { namespace pkix { namespace test {