aboutsummaryrefslogtreecommitdiff
path: root/gcc/go
diff options
context:
space:
mode:
authorBob Duff <duff@adacore.com>2022-07-20 17:37:51 -0400
committerMarc Poulhiès <poulhies@adacore.com>2022-09-05 09:21:03 +0200
commitfc32180d704e59553584ae2a814089c2af1bce09 (patch)
treed3ef834afc1a3407debaef5c747d9477dfda0560 /gcc/go
parent7449db0bf4a2c920538a7f947ccec2831802ded4 (diff)
downloadgcc-fc32180d704e59553584ae2a814089c2af1bce09.zip
gcc-fc32180d704e59553584ae2a814089c2af1bce09.tar.gz
gcc-fc32180d704e59553584ae2a814089c2af1bce09.tar.bz2
[Ada] Suppress warnings in trivial subprograms with finalization
There are heuristics for suppressing warnings about unused objects in trivial cases. In particular, we try to suppress warnings here: function F (A : Integer) return Some_Type; X : Some_Type; begin raise Not_Yet_Implemented; return X; end F; But it doesn't work if Some_Type is controlled. This patch fixes that bug. gcc/ada/ * sem_ch6.adb (Analyze_Subprogram_Body_Helper): Use First_Real_Statement to deal with this case. Note that First_Real_Statement is likely to be removed as part of this ticket, so this is a temporary fix.
Diffstat (limited to 'gcc/go')
0 files changed, 0 insertions, 0 deletions