diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-10-15 13:53:48 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-10-15 13:53:48 +0000 |
commit | 96da32848363deea28bde71dc3d42c34e7067f7a (patch) | |
tree | a52f2a80bd9bc0b3d34328c89d877fdc3113b84f /gcc/ada/a-ngrear.adb | |
parent | 0d5864d449195511725a88a264cf43006c3a342e (diff) | |
download | gcc-96da32848363deea28bde71dc3d42c34e7067f7a.tar.gz |
2007-10-15 Robert Dewar <dewar@adacore.com>
* s-taprop-solaris.adb, s-taprop-vms.adb, s-taprop-mingw.adb,
s-taprop-vxworks.adb, s-taprop-posix.adb, a-calend-vms.adb,
a-calend.adb, a-nuflra.adb, a-tigeau.adb, a-wtgeau.adb,
checks.adb, bindgen.adb, eval_fat.adb, exp_fixd.adb, fmap.adb,
freeze.adb, g-awk.adb, g-calend.adb, g-diopit.adb, g-expect.adb,
gnatchop.adb, gnatlink.adb, g-spipat.adb, g-thread.adb, make.adb,
mdll.adb, mlib.adb, mlib-prj.adb, osint.adb, par-ch3.adb, prj.adb,
prj-makr.adb, sem_prag.adb, sem_type.adb, s-fatgen.adb, s-fileio.adb,
sinfo.ads, sinput-d.adb, s-taasde.adb, s-tasdeb.ads, s-tasren.adb,
s-tassta.adb, s-tpobop.adb, s-tposen.adb, stylesw.adb, types.ads,
uintp.adb, validsw.adb, makegpr.adb, a-rbtgso.adb, a-crbtgo.adb,
a-coorse.adb, a-convec.adb, a-coinve.adb, a-cohama.adb, a-ciorse.adb,
a-cihama.adb, a-cidlli.adb, a-chtgop.adb, a-cdlili.adb, a-cdlili.adb,
a-coormu.adb, a-ciormu.adb, a-cihase.adb, a-cohase.adb, a-ciorma.adb,
a-coorma.adb, a-ztgeau.adb, symbols-vms.adb, a-crdlli.adb,
a-calari.adb, a-calfor.adb, s-os_lib.adb, s-regpat.adb, a-ngrear.adb:
Minor reformatting.
Add Unreferenced and Warnings (Off) pragmas for cases of
variables modified calls where they are IN OUT or OUT parameters and
the resulting values are not subsequently referenced. In a few cases,
we also remove redundant code found by the new warnings.
* ug_words, vms_data.ads, usage.adb, sem_util.adb, sem_util.ads,
sem_warn.adb, sem_warn.ads, sem_res.adb, sem_ch7.adb, sem_ch8.adb,
sem_ch5.adb, opt.ads, lib-xref.adb, lib-xref.ads, exp_smem.adb,
sem_ch11.adb, exp_ch6.adb, einfo.ads, einfo.adb: implement a new
warning controlled by -gnatw.o that warns on cases of out parameter
values being ignored.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@129318 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/a-ngrear.adb')
-rw-r--r-- | gcc/ada/a-ngrear.adb | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/gcc/ada/a-ngrear.adb b/gcc/ada/a-ngrear.adb index 2ff5d01c0aa..098d5a9a2c5 100644 --- a/gcc/ada/a-ngrear.adb +++ b/gcc/ada/a-ngrear.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 2006, Free Software Foundation, Inc. -- +-- Copyright (C) 2006-2007, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -455,11 +455,13 @@ package body Ada.Numerics.Generic_Real_Arrays is Vectors : out Real_Matrix) is N : constant Natural := Length (A); - E : Real_Vector (1 .. N); Tau : Real_Vector (1 .. N); L_Work : Real_Vector (1 .. 1); Info : aliased Integer; + E : Real_Vector (1 .. N); + pragma Warnings (Off, E); + begin if Values'Length /= N then raise Constraint_Error with "wrong length for output vector"; @@ -491,7 +493,9 @@ package body Ada.Numerics.Generic_Real_Arrays is Info => Info'Access); declare - Work : Real_Vector (1 .. Integer'Max (Integer (L_Work (1)), 2 * N)); + Work : Real_Vector (1 .. Integer'Max (Integer (L_Work (1)), 2 * N)); + pragma Warnings (Off, Work); + Comp_Z : aliased constant Character := 'V'; begin @@ -554,12 +558,16 @@ package body Ada.Numerics.Generic_Real_Arrays is Values : out Real_Vector) is N : constant Natural := Length (A); - B : Real_Matrix (1 .. N, 1 .. N); - E : Real_Vector (1 .. N); - Tau : Real_Vector (1 .. N); L_Work : Real_Vector (1 .. 1); Info : aliased Integer; + B : Real_Matrix (1 .. N, 1 .. N); + Tau : Real_Vector (1 .. N); + E : Real_Vector (1 .. N); + pragma Warnings (Off, B); + pragma Warnings (Off, Tau); + pragma Warnings (Off, E); + begin if Values'Length /= N then raise Constraint_Error with "wrong length for output vector"; @@ -592,6 +600,7 @@ package body Ada.Numerics.Generic_Real_Arrays is declare Work : Real_Vector (1 .. Integer'Min (Integer (L_Work (1)), 4 * N)); + pragma Warnings (Off, Work); begin -- Reduce matrix to tridiagonal form @@ -677,6 +686,8 @@ package body Ada.Numerics.Generic_Real_Arrays is declare Work : Real_Vector (1 .. Integer (L_Work (1))); + pragma Warnings (Off, Work); + begin -- Compute inverse from LU decomposition |