You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We probably should be doing so (LLDB will need to rely on this attribute in the future to distinguish static vs. non-static methods..see #120973).
In the DWARFv5 spec chapter "5.7.8 Member Function Entries" we state:
If the member function entry describes a non-static member function, then that
entry has a DW_AT_object_pointer attribute whose value is a reference to the
formal parameter entry that corresponds to the object for which the function is
called. The name attribute of that formal parameter is defined by the current
language (for example, this for C++ or self for Objective C and some other
languages). That parameter also has a DW_AT_artificial attribute whose value is
true.
Conversely, if the member function entry describes a static member function, the
entry does not have a DW_AT_object_pointer attribute.
<non-normative>
In C++, non-static member functions can have const-volatile qualifiers, which affect the
type of the first formal parameter (the “this”-pointer).
</non-normative>
Neither Clang nor GCC attach a `DW_AT_object_pointer` to the `this` parameter DIE:
https://godbolt.org/z/h4jeT54G5
We probably should be doing so (LLDB will need to rely on this attribute in the future to distinguish static vs. non-static methods..see https://github.com/llvm/llvm-project/issues/120973).
In the DWARFv5 spec chapter "5.7.8 Member Function Entries" we state:
If the member function entry describes a non-static member function, then that
entry has a DW_AT_object_pointer attribute whose value is a reference to the
formal parameter entry that corresponds to the object for which the function is
called. The name attribute of that formal parameter is defined by the current
language (for example, this for C++ or self for Objective C and some other
languages). That parameter also has a DW_AT_artificial attribute whose value is
true.
Conversely, if the member function entry describes a static member function, the
entry does not have a DW_AT_object_pointer attribute.
<non-normative>
In C++, non-static member functions can have const-volatile qualifiers, which affect the
type of the first formal parameter (the “this”-pointer).
</non-normative>
Might be worth updating the non-normative text in this section. @<!-- -->dwblaikie @<!-- -->adrian-prantl
</details>
Using C++23's
deducing this
:Neither Clang nor GCC attach a
DW_AT_object_pointer
to thethis
parameter DIE:https://godbolt.org/z/h4jeT54G5
We probably should be doing so (LLDB will need to rely on this attribute in the future to distinguish static vs. non-static methods..see #120973).
In the DWARFv5 spec chapter "5.7.8 Member Function Entries" we state:
Might be worth updating the non-normative text in this section. @dwblaikie @adrian-prantl
The text was updated successfully, but these errors were encountered: