aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarf2
diff options
context:
space:
mode:
authorTom Tromey <tromey@adacore.com>2023-10-27 10:51:50 -0600
committerTom Tromey <tromey@adacore.com>2023-11-21 14:52:05 -0700
commit5028c9e206efd6b92ecefe1afc9dcf5cd4ebb1a6 (patch)
tree7225d0eb8412c091c5fea6804061666a6afcbd05 /gdb/dwarf2
parente17fd6c28e787445d496a71c855784010dfd6ab8 (diff)
downloadgdb-5028c9e206efd6b92ecefe1afc9dcf5cd4ebb1a6.zip
gdb-5028c9e206efd6b92ecefe1afc9dcf5cd4ebb1a6.tar.gz
gdb-5028c9e206efd6b92ecefe1afc9dcf5cd4ebb1a6.tar.bz2
Use enum accessibility in types and member functions
This changes nested types and member functions to use the new 'accessibility' enum, rather than separate private/protected flags. This is done for consistency, but it also lets us simplify some other code in the next patch. Acked-By: Simon Marchi <simon.marchi@efficios.com> Reviewed-by: Keith Seitz <keiths@redhat.com>
Diffstat (limited to 'gdb/dwarf2')
-rw-r--r--gdb/dwarf2/read.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/dwarf2/read.c b/gdb/dwarf2/read.c
index 7b6dc48..9f3297a 100644
--- a/gdb/dwarf2/read.c
+++ b/gdb/dwarf2/read.c
@@ -11716,10 +11716,10 @@ dwarf2_add_type_defn (struct field_info *fip, struct die_info *die,
/* The assumed value if neither private nor protected. */
break;
case DW_ACCESS_private:
- fp.is_private = 1;
+ fp.accessibility = accessibility::PRIVATE;
break;
case DW_ACCESS_protected:
- fp.is_protected = 1;
+ fp.accessibility = accessibility::PROTECTED;
break;
}
@@ -12078,10 +12078,10 @@ dwarf2_add_member_fn (struct field_info *fip, struct die_info *die,
switch (accessibility)
{
case DW_ACCESS_private:
- fnp->is_private = 1;
+ fnp->accessibility = accessibility::PRIVATE;
break;
case DW_ACCESS_protected:
- fnp->is_protected = 1;
+ fnp->accessibility = accessibility::PROTECTED;
break;
}