Fix crash in dwarf2read.c with template parameters
[deliverable/binutils-gdb.git] / gdb / ada-valprint.c
index 3fa7d909817de69546cd0c664752747e816cb625..5d7823d7204186afd43f87b9ec58fa381184d724 100644 (file)
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 #include "defs.h"
-
-/* Standard C includes.  */
 #include <ctype.h>
-
-/* Local non-gdb includes.  */
-#include "ada-lang.h"
+#include "symtab.h"
+#include "gdbtypes.h"
+#include "expression.h"
+#include "value.h"
+#include "demangle.h"
+#include "valprint.h"
+#include "language.h"
 #include "annotate.h"
+#include "ada-lang.h"
 #include "c-lang.h"
-#include "demangle.h"
-#include "expression.h"
-#include "gdbtypes.h"
 #include "infcall.h"
-#include "language.h"
 #include "objfiles.h"
-#include "symtab.h"
 #include "target-float.h"
-#include "valprint.h"
-#include "value.h"
 
 static int print_field_values (struct type *, const gdb_byte *,
                               int,
@@ -1207,18 +1203,17 @@ ada_val_print (struct type *type,
               struct value *val,
               const struct value_print_options *options)
 {
-  TRY
+  try
     {
       ada_val_print_1 (type, embedded_offset, address,
                       stream, recurse, val, options,
                       current_language);
     }
-  CATCH (except, RETURN_MASK_ERROR)
+  catch (const gdb_exception_error &except)
     {
       fprintf_filtered (stream, _("<error reading variable: %s>"),
-                       except.message);
+                       except.what ());
     }
-  END_CATCH
 }
 
 void
This page took 0.024127 seconds and 4 git commands to generate.