aboutsummaryrefslogtreecommitdiff
path: root/gdb/common
diff options
context:
space:
mode:
authorPedro Alves <palves@redhat.com>2015-10-29 12:55:01 +0000
committerPedro Alves <palves@redhat.com>2015-10-29 12:55:01 +0000
commit44a8b4df1d6f5b8096f01787751fd51c42e78fc6 (patch)
treed8a841b0d276d596d4e97ac399d6a54e620dd805 /gdb/common
parente3bdafe2bac1672da335fde734b337c5504e5437 (diff)
downloadgdb-44a8b4df1d6f5b8096f01787751fd51c42e78fc6.zip
gdb-44a8b4df1d6f5b8096f01787751fd51c42e78fc6.tar.gz
gdb-44a8b4df1d6f5b8096f01787751fd51c42e78fc6.tar.bz2
Add cast to exception_none
Fixes, in C++ mode: ../../src/gdb/common/common-exceptions.c:23:69: error: invalid conversion from ‘int’ to ‘return_reason’ [-fpermissive] const struct gdb_exception exception_none = { 0, GDB_NO_ERROR, NULL }; ^ (I considered adding an enum value for '0', but the code and comments around return_reason and its uses explain how 0 is special/internal, so I'm leaving it be.) gdb/ChangeLog: 2015-10-29 Pedro Alves <palves@redhat.com> * common/common-exceptions.c (exception_none): Add cast.
Diffstat (limited to 'gdb/common')
-rw-r--r--gdb/common/common-exceptions.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/common/common-exceptions.c b/gdb/common/common-exceptions.c
index 8ee96ab..ce476a2 100644
--- a/gdb/common/common-exceptions.c
+++ b/gdb/common/common-exceptions.c
@@ -20,7 +20,7 @@
#include "common-defs.h"
#include "common-exceptions.h"
-const struct gdb_exception exception_none = { 0, GDB_NO_ERROR, NULL };
+const struct gdb_exception exception_none = { (enum return_reason) 0, GDB_NO_ERROR, NULL };
#ifndef __cplusplus