From 574851f092358f5834afb0b529676924fcbd59c6 Mon Sep 17 00:00:00 2001 From: Aaron Gyes Date: Fri, 8 Apr 2016 19:09:01 -0700 Subject: [PATCH] Fix #2919 by removing the entire block. This code represents only risk and does nothing useful for anything that can compile fish. In C++ situations where __STDC_VERSION__ is unset (as it should be), fish was assuming we are on < C99 and setting it to __FUNCTION__. Basically always, __PRETTY_FUNCTION__ ends up reaplaced by __FUNCTION__, this hurt error message usefulness and richness. __PRETTY_FUNCTION__: const thing::sub(int) __FUNCTION__: sub --- src/fallback.h | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/fallback.h b/src/fallback.h index f3252c149..0623ec54a 100644 --- a/src/fallback.h +++ b/src/fallback.h @@ -23,19 +23,6 @@ int fish_wcswidth(const wchar_t *str, size_t n); #define WCHAR_MAX INT_MAX #endif -/** - Make sure __func__ is defined to some string. In C99, this should - be the currently compiled function. If we aren't using C99 or - later, older versions of GCC had __FUNCTION__. -*/ -#if __STDC_VERSION__ < 199901L -# if __GNUC__ >= 2 -# define __func__ __FUNCTION__ -# else -# define __func__ "" -# endif -#endif - /** Under curses, tputs expects an int (*func)(char) as its last parameter, but in ncurses, tputs expects a int (*func)(int) as its