Watcom supports __FUNCTION__ identifier (and surely not __PRETTY_FUNCTION__)
authorOzkan Sezer <sezeroz@gmail.com>
Thu, 17 Aug 2017 21:35:46 -0400
changeset 11317f57e81db97b5
parent 11316 76abc6e1eb4b
child 11318 06fd8421e8f6
Watcom supports __FUNCTION__ identifier (and surely not __PRETTY_FUNCTION__)

Partially fixes Bugzilla #3758.
include/SDL_assert.h
src/render/opengl/SDL_render_gl.c
src/render/opengles2/SDL_render_gles2.c
     1.1 --- a/include/SDL_assert.h	Thu Aug 17 21:32:42 2017 -0400
     1.2 +++ b/include/SDL_assert.h	Thu Aug 17 21:35:46 2017 -0400
     1.3 @@ -65,7 +65,7 @@
     1.4  
     1.5  #if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) /* C99 supports __func__ as a standard. */
     1.6  #   define SDL_FUNCTION __func__
     1.7 -#elif ((__GNUC__ >= 2) || defined(_MSC_VER))
     1.8 +#elif ((__GNUC__ >= 2) || defined(_MSC_VER) || defined (__WATCOMC__))
     1.9  #   define SDL_FUNCTION __FUNCTION__
    1.10  #else
    1.11  #   define SDL_FUNCTION "???"
     2.1 --- a/src/render/opengl/SDL_render_gl.c	Thu Aug 17 21:32:42 2017 -0400
     2.2 +++ b/src/render/opengl/SDL_render_gl.c	Thu Aug 17 21:35:46 2017 -0400
     2.3 @@ -260,7 +260,7 @@
     2.4  
     2.5  #if 0
     2.6  #define GL_CheckError(prefix, renderer)
     2.7 -#elif defined(_MSC_VER)
     2.8 +#elif defined(_MSC_VER) || defined(__WATCOMC__)
     2.9  #define GL_CheckError(prefix, renderer) GL_CheckAllErrors(prefix, renderer, __FILE__, __LINE__, __FUNCTION__)
    2.10  #else
    2.11  #define GL_CheckError(prefix, renderer) GL_CheckAllErrors(prefix, renderer, __FILE__, __LINE__, __PRETTY_FUNCTION__)
     3.1 --- a/src/render/opengles2/SDL_render_gles2.c	Thu Aug 17 21:32:42 2017 -0400
     3.2 +++ b/src/render/opengles2/SDL_render_gles2.c	Thu Aug 17 21:35:46 2017 -0400
     3.3 @@ -258,7 +258,7 @@
     3.4  
     3.5  #if 0
     3.6  #define GL_CheckError(prefix, renderer)
     3.7 -#elif defined(_MSC_VER)
     3.8 +#elif defined(_MSC_VER) || defined(__WATCOMC__)
     3.9  #define GL_CheckError(prefix, renderer) GL_CheckAllErrors(prefix, renderer, __FILE__, __LINE__, __FUNCTION__)
    3.10  #else
    3.11  #define GL_CheckError(prefix, renderer) GL_CheckAllErrors(prefix, renderer, __FILE__, __LINE__, __PRETTY_FUNCTION__)