https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86117
Damian Rouson <damian at sourceryinstitute dot org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |damian at sourceryinstitute dot or | |g --- Comment #5 from Damian Rouson <damian at sourceryinstitute dot org> --- Below is an example without the polymorphism employed in the original submission. In gfortran 11, the warnings and notes now total 70 lines stemming from a single executable line. In my opinion, this volume renders -Wall nearly unusable because of the time it can take to sift out the truly useful information from the spurious information. ± cat copious-warnings.f90 module results_interface type results_t real, allocatable :: output(:) end type contains subroutine max_filtered_normalized_distance(rhs) type(results_t) rhs real, allocatable :: rhs_filtered(:) rhs_filtered = rhs%output end subroutine end module ± gfortran -c -Wall copious-warnings.f90 copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.offset’ is used uninitialized [-Wuninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.dim[0].lbound’ is used uninitialized [-Wuninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.dim[0].ubound’ is used uninitialized [-Wuninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.dim[0].lbound’ may be used uninitialized [-Wmaybe-uninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.dim[0].ubound’ may be used uninitialized [-Wmaybe-uninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.dim[0].ubound’ may be used uninitialized [-Wmaybe-uninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here copious-warnings.f90:9:0: 9 | rhs_filtered = rhs%output | Warning: ‘rhs_filtered.dim[0].lbound’ may be used uninitialized [-Wmaybe-uninitialized] copious-warnings.f90:8:40: 8 | real, allocatable :: rhs_filtered(:) | ^ note: ‘rhs_filtered’ declared here ± gfortran --version GNU Fortran (GCC) 11.0.0 20200804 (experimental)