[Dwarf-discuss] Additional values for DW_AT_accessibility
Ben Woodard
woodard@redhat.com
Sat Apr 25 01:17:46 GMT 2026
I guess these have ABI implications as well and so they probably would need to be tracked so they would need to be available for tools like libabigail.
While a tool like gdb probably wouldn’t care about the difference between “Private” and “Strict Private”, libabigail would need know if a member or a method changed from one to another. This would likely be more of an API level ABI change rather than a structural or calling convention change.
If Cary hasn’t picked it up already, I’ll write up a super simple issue and ask him to file it. I haven’t done Pascal since Jr High but I can see how having the full range of access qualifiers defined could be important for some tools like libabigail and so I will also volunteer to champion the issue if necessary.
Do you think we really need “Published”? I can’t see any reason why that one is needed in DWARF.
-ben
> On Apr 24, 2026, at 1:36 PM, Martin Frb via Dwarf-discuss <dwarf-discuss@lists.dwarfstd.org> wrote:
>
> Currently there are the values
> DW_ACCESS_public DW_ACCESS_private DW_ACCESS_protected
>
> FreePascal has more (list at the end of mail)
> Could those please be added?
>
> https://www.freepascal.org/docs-html/ref/refse35.html
>> Private
>> All fields and methods that are in a private block, can only be accessed in the module (i. e. unit) that contains the class definition.
>> They can be accessed from inside the classes’ methods or from outside them (e. g. from other classes’ methods)
>> Strict Private
>> All fields and methods that are in a strict private block, can only be accessed from methods of the class itself. Other classes or descendent classes (even in the same unit) cannot access strict private members.
>> Protected
>> Is the same as Private, except that the members of a Protected section are also accessible to descendent types, even if they are implemented in other modules.
>> Strict Protected
>> Is the same as Protected, except that the members of a Protected section are also accessible to other classes implemented in the same unit. Strict protected members are only visible to descendent classes, not to other classes in the same unit.
>> Public
>> sections are always accessible.
>> Published
>> From a language perspective, this is the same as a Public section, but the compiler generates also type information that is needed for automatic streaming of these classes if the compiler is in the {$M+} state. Fields defined in a published section must be of class type. Array properties cannot be in a published section.
>
>
> --
> Dwarf-discuss mailing list
> Dwarf-discuss@lists.dwarfstd.org
> https://lists.dwarfstd.org/mailman/listinfo/dwarf-discuss
>
More information about the Dwarf-discuss
mailing list