You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
-Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef DEFS_H
#define DEFS_H
#ifndef NORETURN
# if defined(__GNUC__) \
- && (__GNUC__ == 1 || (__GNUC__ == 2 && __GNUC_MINOR__ < 5))
+ && (__GNUC__ == 1 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7))
# define NORETURN volatile
# else
# define NORETURN /* nothing */
#endif
/* GCC 2.5 and later versions define a function attribute "noreturn",
- which is the preferred way to declare that a function never returns. */
+ which is the preferred way to declare that a function never returns.
+ However GCC 2.7 appears to be the first version in which this fully
+ works everywhere we use it. */
#ifndef ATTR_NORETURN
-# if defined(__GNUC__) && __GNUC__ >= 2 && __GNUC_MINOR__ >= 5
+# if defined(__GNUC__) && __GNUC__ >= 2 && __GNUC_MINOR__ >= 7
# define ATTR_NORETURN __attribute__ ((noreturn))
# else
# define ATTR_NORETURN /* nothing */
#endif
#ifndef ATTR_FORMAT
-# if defined(__GNUC__) && __GNUC__ >= 2 && __GNUC_MINOR__ >= 4
+# if defined(__GNUC__) && __GNUC__ >= 2 && __GNUC_MINOR__ >= 4 && defined (__ANSI_PROTOTYPES)
# define ATTR_FORMAT(type, x, y) __attribute__ ((format(type, x, y)))
# else
# define ATTR_FORMAT(type, x, y) /* nothing */
extern void (*create_breakpoint_hook) PARAMS ((struct breakpoint *b));
extern void (*delete_breakpoint_hook) PARAMS ((struct breakpoint *bpt));
extern void (*modify_breakpoint_hook) PARAMS ((struct breakpoint *bpt));
+extern void (*target_output_hook) PARAMS ((char *));
extern void (*interactive_hook) PARAMS ((void));
extern void (*registers_changed_hook) PARAMS ((void));
extern void (*call_command_hook) PARAMS ((struct cmd_list_element *c,
char *cmd, int from_tty));
-extern NORETURN void (*error_hook) PARAMS (());
+extern NORETURN void (*error_hook) PARAMS (()) ATTR_NORETURN;
#endif
#ifndef SLASH_P
+#if defined(__GO32__)||defined(WIN32)
+#define SLASH_P(X) ((X)=='\\')
+#else
#define SLASH_P(X) ((X)=='/')
#endif
+#endif
#ifndef SLASH_CHAR
+#if defined(__GO32__)||defined(WIN32)
+#define SLASH_CHAR '\\'
+#else
#define SLASH_CHAR '/'
#endif
+#endif
#ifndef SLASH_STRING
+#if defined(__GO32__)||defined(WIN32)
+#define SLASH_STRING "\\"
+#else
#define SLASH_STRING "/"
#endif
+#endif
#ifndef ROOTED_P
#define ROOTED_P(X) (SLASH_P((X)[0]))