[clang] [llvm] Add RunTimeLang to Class and Enumeration DIBuilder functions (PR #72011)
Augusto Noronha via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 14 16:39:24 PST 2023
================
@@ -424,6 +424,7 @@ namespace llvm {
/// \param OffsetInBits Member offset.
/// \param Flags Flags to encode member attribute, e.g. private
/// \param Elements class members.
+ /// \param RunTimeLang Optional parameter, Objective-C runtime version.
----------------
augusto2112 wrote:
> I think your entire patch would be a lot simpler if this were the last parameter of the function, as you wouldn't need to change as many callsites and have inline comments explaining the parameter. Did you have a motivation in mind for placing the argument here?
I'm following the pattern on the ordering from the existing functions, for example:
```
DICompositeType *createStructType(
DIScope *Scope, StringRef Name, DIFile *File, unsigned LineNumber,
uint64_t SizeInBits, uint32_t AlignInBits, DINode::DIFlags Flags,
DIType *DerivedFrom, DINodeArray Elements, unsigned RunTimeLang = 0,
DIType *VTableHolder = nullptr, StringRef UniqueIdentifier = "");
DICompositeType *createUnionType(DIScope *Scope, StringRef Name,
DIFile *File, unsigned LineNumber,
uint64_t SizeInBits, uint32_t AlignInBits,
DINode::DIFlags Flags,
DINodeArray Elements,
unsigned RunTimeLang = 0,
StringRef UniqueIdentifier = "");
```
https://github.com/llvm/llvm-project/pull/72011
More information about the cfe-commits
mailing list