================ @@ -194,17 +196,19 @@ static unsigned calculateLegacyCbufferSize(const ASTContext &Context, calculateLegacyCbufferSize(Context, VT->getElementType()); Size = ElementSize * ElementCount; } else { - Size = Context.getTypeSize(T); + Size = Context.getTypeSize(T) / 8; } return Size; } -void SemaHLSL::ActOnFinishBuffer(Decl *Dcl, SourceLocation RBrace) { - auto *BufDecl = cast<HLSLBufferDecl>(Dcl); - BufDecl->setRBraceLoc(RBrace); - - // Validate packoffset. +// Validate packoffset: +// - make sure if packoffset it used on all decls or none ---------------- bob80905 wrote:
"Make sure if packoffset is used, it's used on all decls or none?"? https://github.com/llvm/llvm-project/pull/121989 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits