/* Guile interface to program spaces.
- Copyright (C) 2010-2015 Free Software Foundation, Inc.
+ Copyright (C) 2010-2019 Free Software Foundation, Inc.
This file is part of GDB.
static void
psscm_handle_pspace_deleted (struct program_space *pspace, void *datum)
{
- pspace_smob *p_smob = datum;
+ pspace_smob *p_smob = (pspace_smob *) datum;
gdb_assert (p_smob->pspace == pspace);
{
pspace_smob *p_smob;
- p_smob = program_space_data (pspace, psscm_pspace_data_key);
+ p_smob = (pspace_smob *) program_space_data (pspace, psscm_pspace_data_key);
if (p_smob == NULL)
{
SCM p_scm = psscm_make_pspace_smob ();
{
pspace_smob *p_smob
= psscm_get_valid_pspace_smob_arg_unsafe (self, SCM_ARG1, FUNC_NAME);
- struct objfile *objfile;
SCM result;
result = SCM_EOL;
- ALL_PSPACE_OBJFILES (p_smob->pspace, objfile)
- {
- if (objfile->separate_debug_objfile_backlink == NULL)
- {
- SCM item = ofscm_scm_from_objfile (objfile);
+ for (objfile *objfile : p_smob->pspace->objfiles ())
+ {
+ if (objfile->separate_debug_objfile_backlink == NULL)
+ {
+ SCM item = ofscm_scm_from_objfile (objfile);
- result = scm_cons (item, result);
- }
- }
+ result = scm_cons (item, result);
+ }
+ }
/* We don't really have to return the list in the same order as recorded
internally, but for consistency we do. We still advertise that one