[cfe-commits] r53928 - /cfe/trunk/lib/CodeGen/CGExprScalar.cpp
Mike Stump
mrs at apple.com
Tue Jul 22 15:39:45 PDT 2008
On Jul 22, 2008, at 12:44 PM, Daniel Dunbar wrote:
> Author: ddunbar
> Date: Tue Jul 22 14:44:18 2008
> New Revision: 53928
>
> URL: http://llvm.org/viewvc/llvm-project?rev=53928&view=rev
> Log:
> Add note to check what __alignof__ a function type should be.
If this is represented by:
int(*f)(int);
main() {
printf("align is %d\n", __alignof__(*f));
}
then gcc gives 1.
> + // FIXME: what is alignof a function type in gcc?
> if (TypeToSize->isVoidType() || TypeToSize->isFunctionType())
> return llvm::ConstantInt::get(llvm::APInt(ResultWidth, 1));
More information about the cfe-commits
mailing list