We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f8653ce commit 6f3b360Copy full SHA for 6f3b360
llvm/include/llvm/ADT/SmallVector.h
@@ -128,8 +128,8 @@ class SmallVectorTemplateCommon
128
/// SmallVectorStorage is properly-aligned even for small-size of 0.
129
void *getFirstEl() const {
130
return const_cast<void *>(reinterpret_cast<const void *>(
131
- reinterpret_cast<const SmallVectorAlignmentAndSize<T> *>(this)
132
- ->FirstEl));
+ reinterpret_cast<const char *>(this) +
+ offsetof(SmallVectorAlignmentAndSize<T>, FirstEl)));
133
}
134
// Space after 'FirstEl' is clobbered, do not add any instance vars after it.
135
0 commit comments