https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85302
--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> --- Author: jakub Date: Wed Apr 11 10:22:36 2018 New Revision: 259311 URL: https://gcc.gnu.org/viewcvs?rev=259311&root=gcc&view=rev Log: PR debug/85302 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if SIZEP is NULL. (output_loc_list): Pass address of a dummy size variable even in the locview handling loop. (index_location_lists): Add comment on why skip_loc_list_entry can't call size_of_locs. * g++.dg/debug/dwarf2/pr85302.C: New test. Added: trunk/gcc/testsuite/g++.dg/debug/dwarf2/pr85302.C Modified: trunk/gcc/ChangeLog trunk/gcc/dwarf2out.c trunk/gcc/testsuite/ChangeLog