Skip to content

Commit

Permalink
2.09.06
Browse files Browse the repository at this point in the history
  • Loading branch information
Roberto Parolin committed Jul 26, 2019
1 parent 6f27a2f commit ea91a59
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 9 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
tags
build
build.bat

41 changes: 41 additions & 0 deletions include/Common/EABase/config/eacompiler.h
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,9 @@
* C++17 functionality
* EA_COMPILER_NO_INLINE_VARIABLES
* EA_COMPILER_NO_ALIGNED_NEW
*
* C++20 functionality
* EA_COMPILER_NO_DESIGNATED_INITIALIZERS
*
*-----------------------------------------------------------------------------
*
Expand Down Expand Up @@ -300,6 +303,26 @@
#endif


// EA_COMPILER_CPP20_ENABLED
//
// Defined as 1 if the compiler has its available C++20 support enabled, else undefined.
// This does not mean that all of C++20 or any particular feature of C++20 is supported
// by the compiler. It means that whatever C++20 support the compiler has is enabled.
//
// We cannot use (__cplusplus >= 202003L) alone because some compiler vendors have
// decided to not define __cplusplus like thus until they have fully completed their
// C++20 support.
#if !defined(EA_COMPILER_CPP20_ENABLED) && defined(__cplusplus)
// TODO(rparoin): enable once a C++20 value for the __cplusplus macro has been published
// #if (__cplusplus >= 202003L)
// #define EA_COMPILER_CPP20_ENABLED 1
// #elif defined(_MSVC_LANG) && (_MSVC_LANG >= 202003L) // C++20+
// #define EA_COMPILER_CPP20_ENABLED 1
// #endif
#endif



#if defined(__ARMCC_VERSION)
// Note that this refers to the ARM RVCT compiler (armcc or armcpp), but there
// are other compilers that target ARM processors, such as GCC and Microsoft VC++.
Expand Down Expand Up @@ -1290,6 +1313,24 @@
#endif


// EA_COMPILER_NO_DESIGNATED_INITIALIZERS
//
// Indicates the target compiler supports the C++20 "designated initializer" language feature.
// https://en.cppreference.com/w/cpp/language/aggregate_initialization
//
// Example:
// struct A { int x; int y; };
// A a = { .y = 42, .x = 1 };
//
#if !defined(EA_COMPILER_NO_DESIGNATED_INITIALIZERS)
#if defined(EA_COMPILER_CPP20_ENABLED)
// supported.
#else
#define EA_COMPILER_NO_DESIGNATED_INITIALIZERS 1
#endif
#endif


// EA_COMPILER_NO_NONSTATIC_MEMBER_INITIALIZERS
//
// Refers to C++11 declaration attribute: carries_dependency.
Expand Down
8 changes: 4 additions & 4 deletions include/Common/EABase/config/eaplatform.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
#endif


#elif defined(EA_PLATFORM_XBOXONE) || defined(_DURANGO) || defined(EA_PLATFORM_CAPILANO) || (defined(WINAPI_FAMILY) && (WINAPI_FAMILY == WINAPI_FAMILY_GAMES || WINAPI_FAMILY == WINAPI_FAMILY_TV_TITLE))
#elif defined(EA_PLATFORM_XBOXONE) || defined(_DURANGO) || defined(_XBOX_ONE) || defined(EA_PLATFORM_CAPILANO) || defined(_GAMING_XBOX)
// XBox One
// Durango was Microsoft's code-name for the platform, which is now obsolete.
// Microsoft uses _DURANGO instead of some variation of _XBOX, though it's not natively defined by the compiler.
Expand Down Expand Up @@ -170,11 +170,11 @@

#if defined(WINAPI_FAMILY)
#include <winapifamily.h>
#if WINAPI_FAMILY == WINAPI_FAMILY_TV_TITLE
#if defined(WINAPI_FAMILY_TV_TITLE) && WINAPI_FAMILY == WINAPI_FAMILY_TV_TITLE
#define EA_WINAPI_FAMILY EA_WINAPI_FAMILY_TV_TITLE
#elif WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP
#elif defined(WINAPI_FAMILY_DESKTOP_APP) && WINAPI_FAMILY == WINAPI_FAMILY_DESKTOP_APP
#define EA_WINAPI_FAMILY EA_WINAPI_FAMILY_DESKTOP_APP
#elif WINAPI_FAMILY == WINAPI_FAMILY_GAMES
#elif defined(WINAPI_FAMILY_GAMES) && WINAPI_FAMILY == WINAPI_FAMILY_GAMES
#define EA_WINAPI_FAMILY EA_WINAPI_FAMILY_GAMES
#else
#error Unsupported WINAPI_FAMILY
Expand Down
2 changes: 1 addition & 1 deletion include/Common/EABase/eahave.h
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,7 @@
#endif

#if !defined(EA_HAVE_nanosleep_DECL) && !defined(EA_NO_HAVE_nanosleep_DECL)
#if (defined(EA_PLATFORM_UNIX) && !defined(EA_PLATFORM_SONY)) || defined(EA_PLATFORM_IPHONE) || defined(EA_PLATFORM_OSX) || defined(EA_PLATFORM_PS4)
#if (defined(EA_PLATFORM_UNIX) && !defined(EA_PLATFORM_SONY)) || defined(EA_PLATFORM_IPHONE) || defined(EA_PLATFORM_OSX) || defined(EA_PLATFORM_PS4) || defined(CS_UNDEFINED_STRING)
#define EA_HAVE_nanosleep_DECL 1
#else
#define EA_NO_HAVE_nanosleep_DECL 1
Expand Down
4 changes: 2 additions & 2 deletions include/Common/EABase/version.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
///////////////////////////////////////////////////////////////////////////////

#ifndef EABASE_VERSION
#define EABASE_VERSION "2.09.05"
#define EABASE_VERSION_N 20905
#define EABASE_VERSION "2.09.06"
#define EABASE_VERSION_N 20906
#endif

#endif

0 comments on commit ea91a59

Please sign in to comment.